custom-items Endpoint

ReturnsUse the custom-items endpoint with set item-names parameters to retrieve bulk data for custom items in the location. To see all custom items for a location, use the custom-item-names endpoint.

GET https://integrations.prod.vas.com/api/locations/com.vas.dairies.id/{location-id}/custom-items?item-names={item-name}

IMPORTANT: This endpoint does not retrieve any calculated items. If you do not see an item in this endpoint, it is possible that the data already exists in a standard endpoint or the item is for internal use only by VAS.

Path Parameters (required)

The following parameters must be included in the request path for this endpoint: 

{location-id}integerREQUIRED

VAS-specificClosed A data value that originates from the VAS product line. [dairy] location identifier. For routes with “com.vas.dairies.id”, {location-id} is a VAS-specific dairy id.

Query Parameters (required)

This following query parameters must be included in the request path for this endpoint:

{item-names}stringREQUIRED

Specifies the custom item(s) to include in the results. To include multiple custom items, separate each custom item name with a comma. The query can contain up to 5 custom items.

Sample Request (cURL)
curl -X GET \
https://integrations.prod.vas.com/api/locations/com.vas.dairies.id/{location-id}/custom-items?item-names={item-name} \
-H 'Authorization: bearer {authorization token}' \
-H 'X-API-Key: {API key}' 
Sample Request (cURL) - with multiple query parameters
curl -X GET \
https://integrations.prod.vas.com/api/locations/com.vas.dairies.id/{location-id}/custom-items?item-names={item-name},{item-name} \
-H 'Authorization: bearer {authorization token}' \
-H 'X-API-Key: {API key}' 

Response Schema

NOTE: See API Errors and HTTP Status Code Details for a list of API errors and HTTP status codes.
Sample Response (JSON)
{
    "view": {
        "pageSize": 1,
        "currentPage": 1,
        "totalPages": 1,
        "totalItems": 2
    },
    "member": [
        {
            "itemDefinitions": [
                {
                    "itemNumber": 67,
                    "name": "CALF1Closed Recent identified offspring",
                    "description": "Recent Identified Offspring",
                    "standardItemNumber": 67
                },
                {
                    "itemNumber": 68,
                    "name": "CALF2Closed Previous identified offspring",
                    "description": "Previous Identified Offspring",
                    "standardItemNumber": 68
                }
            ],
            "animals": [
                {
                    "identifier": {
                        "id": "100264744",
                        "scheme": "com.vas.animals.id"
                    },
                    "pen": {
                        "alternativeIdentifiers": [
                            {
                                "id": "0",
                                "scheme": "com.vas.pens.number"
                            }
                        ]
                    },
                    "items": [
                        {
                            "itemNumber": 67,
                            "value": null,
                            "valueType": null
                        },
                        {
                            "itemNumber": 68,
                            "value": null,
                            "valueType": null
                        }
                    ]
                },
                {
                    "identifier": {
                        "id": "100151608",
                        "scheme": "com.vas.animals.id"
                    },
                    "pen": {
                        "alternativeIdentifiers": [
                            {
                                "id": "45",
                                "scheme": "com.vas.pens.number"
                            }
                        ]
                    },
                    "items": [
                        {
                            "itemNumber": 67,
                            "value": null,
                            "valueType": null
                        },
                        {
                            "itemNumber": 68,
                            "value": null,
                            "valueType": null
                        }
                    ]
                }
            ]
        }
    ]
}