Skip to content

AHDS Store API (1.0)

Animal Health Data Store - V1 API Documentation

Overview
Languages
Servers
Mock server

https://docs.heydonto.com/_mock/apis/animal-health/openapi/

Local Development

http://localhost:8083/

Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations

Request

Creates a new Stock Adjustment Item record. Stock Adjustment Item resource in the Animal Health Data Store

Security
bearer
Path
siteIdnumberrequired

Site identifier

Bodyapplication/jsonrequired
batchesArray of objects(BatcheDto)

Batch-level breakdown of the stock adjustment.

currencystring

ISO 4217 currency code for the unitPrice.

extensionsobject

Vendor- or practice-specific extensions.

ledgerAccountIdstring

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: "123e4567-e89b-12d3-a456-426614174000"
locationIdstring

Identifier of the inventory location where the adjustment is applied.

Example: "123e4567-e89b-12d3-a456-426614174000"
productIdstringrequired

Identifier of the product being adjusted.

Example: "123e4567-e89b-12d3-a456-426614174000"
quantitynumberrequired

Quantity of product adjusted. Positive for increase, negative for decrease.

stockAdjustmentIdstringrequired

Identifier of the parent stock adjustment.

Example: "123e4567-e89b-12d3-a456-426614174000"
stockAdjustmentItemIdstringrequired

Canonical identifier for this stock adjustment line item.

Example: "123e4567-e89b-12d3-a456-426614174000"
unitPricestring

Unit price of the product at the time of adjustment, represented as a decimal string.

Example: "100.00"
curl -i -X POST \
  'https://docs.heydonto.com/_mock/apis/animal-health/openapi/site/{siteId}/ahds/v1/stock-adjustment-item' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "batches": [
      {
        "batchId": "123e4567-e89b-12d3-a456-426614174000",
        "createdAt": "2025-01-01T00:00:00.000Z",
        "expiryDate": "2025-01-01",
        "isActive": true,
        "name": "string",
        "quantity": 0,
        "type": "string",
        "updatedAt": "2025-01-01T00:00:00.000Z"
      }
    ],
    "currency": "string",
    "extensions": {},
    "ledgerAccountId": "123e4567-e89b-12d3-a456-426614174000",
    "locationId": "123e4567-e89b-12d3-a456-426614174000",
    "productId": "123e4567-e89b-12d3-a456-426614174000",
    "quantity": 0,
    "stockAdjustmentId": "123e4567-e89b-12d3-a456-426614174000",
    "stockAdjustmentItemId": "123e4567-e89b-12d3-a456-426614174000",
    "unitPrice": "100.00"
  }'

Responses

Stock Adjustment Item created successfully

Bodyapplication/json
batchesArray of objects(BatcheDto)required

Batch-level breakdown of the stock adjustment.

batches[].​batchIdstring or null

Identifier of the batch record.

Example: "123e4567-e89b-12d3-a456-426614174000"
batches[].​createdAtstring or null

Timestamp when this batch record was created.

Example: "2025-01-01T00:00:00.000Z"
batches[].​expiryDatestring or null

Expiry date of the batch, if applicable.

Example: "2025-01-01"
batches[].​isActiveboolean or null

If true, the batch is active.

batches[].​namestring or null

Batch or lot name/number.

batches[].​quantitynumber or null

Quantity from this batch associated with the receive invoice item.

batches[].​typestring or null

Batch type classification.

batches[].​updatedAtstring or null

Timestamp when this batch record was last modified.

Example: "2025-01-01T00:00:00.000Z"
createdAtstring(date-time)required

Timestamp when this stock adjustment item was created.

Example: "2025-01-01T00:00:00.000Z"
currencystringrequired

ISO 4217 currency code for the unitPrice.

extensionsobjectrequired

Vendor- or practice-specific extensions.

ledgerAccountIdstringrequired

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: "123e4567-e89b-12d3-a456-426614174000"
locationIdstringrequired

Identifier of the inventory location where the adjustment is applied.

Example: "123e4567-e89b-12d3-a456-426614174000"
productIdstringrequired

Identifier of the product being adjusted.

Example: "123e4567-e89b-12d3-a456-426614174000"
quantitynumberrequired

Quantity of product adjusted. Positive for increase, negative for decrease.

stockAdjustmentIdstringrequired

Identifier of the parent stock adjustment.

Example: "123e4567-e89b-12d3-a456-426614174000"
stockAdjustmentItemIdstringrequired

Canonical identifier for this stock adjustment line item.

Example: "123e4567-e89b-12d3-a456-426614174000"
unitPricestringrequired

Unit price of the product at the time of adjustment, represented as a decimal string.

Example: "100.00"
updatedAtstring(date-time)required

Timestamp when this stock adjustment item was last updated.

Example: "2025-01-01T00:00:00.000Z"
Response
application/json
{ "batches": [ { … } ], "createdAt": "2025-01-01T00:00:00.000Z", "currency": "string", "extensions": {}, "ledgerAccountId": "123e4567-e89b-12d3-a456-426614174000", "locationId": "123e4567-e89b-12d3-a456-426614174000", "productId": "123e4567-e89b-12d3-a456-426614174000", "quantity": 0, "stockAdjustmentId": "123e4567-e89b-12d3-a456-426614174000", "stockAdjustmentItemId": "123e4567-e89b-12d3-a456-426614174000", "unitPrice": "100.00", "updatedAt": "2025-01-01T00:00:00.000Z" }

Request

Returns a paginated list of Stock Adjustment Items for the specified site. Supports filtering and sorting.

Security
bearer
Path
siteIdnumberrequired

Site identifier

Query
pagenumber>= 0

Page number (0-indexed)

Default 0
pageSizenumber[ 1 .. 100 ]

Number of items per page

Default 10
sortBystring

Field to sort by

Enum"createdAt""updatedAt""currency""quantity""unitPrice"
sortOrderstring

Sort order

Default "asc"
Enum"asc""desc"
currencystring

ISO 4217 currency code for the unitPrice.

ledgerAccountIdstring

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: ledgerAccountId=123e4567-e89b-12d3-a456-426614174000
locationIdstring

Identifier of the inventory location where the adjustment is applied.

Example: locationId=123e4567-e89b-12d3-a456-426614174000
productIdstring

Identifier of the product being adjusted.

Example: productId=123e4567-e89b-12d3-a456-426614174000
stockAdjustmentIdstring

Identifier of the parent stock adjustment.

Example: stockAdjustmentId=123e4567-e89b-12d3-a456-426614174000
curl -i -X GET \
  'https://docs.heydonto.com/_mock/apis/animal-health/openapi/site/{siteId}/ahds/v1/stock-adjustment-item?page=0&pageSize=10&sortBy=createdAt&sortOrder=asc&currency=string&ledgerAccountId=123e4567-e89b-12d3-a456-426614174000&locationId=123e4567-e89b-12d3-a456-426614174000&productId=123e4567-e89b-12d3-a456-426614174000&stockAdjustmentId=123e4567-e89b-12d3-a456-426614174000' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Paginated list of Stock Adjustment Items

Request

Returns a single Stock Adjustment Item by its unique identifier.

Security
bearer
Path
siteIdnumberrequired

Site identifier

stockAdjustmentItemIdstringrequired

Stock Adjustment Item unique identifier (UUID)

curl -i -X GET \
  'https://docs.heydonto.com/_mock/apis/animal-health/openapi/site/{siteId}/ahds/v1/stock-adjustment-item/{stockAdjustmentItemId}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Stock Adjustment Item found

Bodyapplication/json
batchesArray of objects(BatcheDto)required

Batch-level breakdown of the stock adjustment.

batches[].​batchIdstring or null

Identifier of the batch record.

Example: "123e4567-e89b-12d3-a456-426614174000"
batches[].​createdAtstring or null

Timestamp when this batch record was created.

Example: "2025-01-01T00:00:00.000Z"
batches[].​expiryDatestring or null

Expiry date of the batch, if applicable.

Example: "2025-01-01"
batches[].​isActiveboolean or null

If true, the batch is active.

batches[].​namestring or null

Batch or lot name/number.

batches[].​quantitynumber or null

Quantity from this batch associated with the receive invoice item.

batches[].​typestring or null

Batch type classification.

batches[].​updatedAtstring or null

Timestamp when this batch record was last modified.

Example: "2025-01-01T00:00:00.000Z"
createdAtstring(date-time)required

Timestamp when this stock adjustment item was created.

Example: "2025-01-01T00:00:00.000Z"
currencystringrequired

ISO 4217 currency code for the unitPrice.

extensionsobjectrequired

Vendor- or practice-specific extensions.

ledgerAccountIdstringrequired

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: "123e4567-e89b-12d3-a456-426614174000"
locationIdstringrequired

Identifier of the inventory location where the adjustment is applied.

Example: "123e4567-e89b-12d3-a456-426614174000"
productIdstringrequired

Identifier of the product being adjusted.

Example: "123e4567-e89b-12d3-a456-426614174000"
quantitynumberrequired

Quantity of product adjusted. Positive for increase, negative for decrease.

stockAdjustmentIdstringrequired

Identifier of the parent stock adjustment.

Example: "123e4567-e89b-12d3-a456-426614174000"
stockAdjustmentItemIdstringrequired

Canonical identifier for this stock adjustment line item.

Example: "123e4567-e89b-12d3-a456-426614174000"
unitPricestringrequired

Unit price of the product at the time of adjustment, represented as a decimal string.

Example: "100.00"
updatedAtstring(date-time)required

Timestamp when this stock adjustment item was last updated.

Example: "2025-01-01T00:00:00.000Z"
Response
application/json
{ "batches": [ { … } ], "createdAt": "2025-01-01T00:00:00.000Z", "currency": "string", "extensions": {}, "ledgerAccountId": "123e4567-e89b-12d3-a456-426614174000", "locationId": "123e4567-e89b-12d3-a456-426614174000", "productId": "123e4567-e89b-12d3-a456-426614174000", "quantity": 0, "stockAdjustmentId": "123e4567-e89b-12d3-a456-426614174000", "stockAdjustmentItemId": "123e4567-e89b-12d3-a456-426614174000", "unitPrice": "100.00", "updatedAt": "2025-01-01T00:00:00.000Z" }

Request

Partially updates an existing Stock Adjustment Item. Only provided fields will be updated.

Security
bearer
Path
siteIdnumberrequired

Site identifier

stockAdjustmentItemIdstringrequired

Stock Adjustment Item unique identifier (UUID)

Bodyapplication/jsonrequired
batchesArray of objects(BatcheDto)

Batch-level breakdown of the stock adjustment.

currencystring

ISO 4217 currency code for the unitPrice.

extensionsobject

Vendor- or practice-specific extensions.

ledgerAccountIdstring

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: "123e4567-e89b-12d3-a456-426614174000"
locationIdstring

Identifier of the inventory location where the adjustment is applied.

Example: "123e4567-e89b-12d3-a456-426614174000"
productIdstring

Identifier of the product being adjusted.

Example: "123e4567-e89b-12d3-a456-426614174000"
quantitynumber

Quantity of product adjusted. Positive for increase, negative for decrease.

stockAdjustmentIdstring

Identifier of the parent stock adjustment.

Example: "123e4567-e89b-12d3-a456-426614174000"
unitPricestring

Unit price of the product at the time of adjustment, represented as a decimal string.

Example: "100.00"
curl -i -X PATCH \
  'https://docs.heydonto.com/_mock/apis/animal-health/openapi/site/{siteId}/ahds/v1/stock-adjustment-item/{stockAdjustmentItemId}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "batches": [
      {
        "batchId": "123e4567-e89b-12d3-a456-426614174000",
        "createdAt": "2025-01-01T00:00:00.000Z",
        "expiryDate": "2025-01-01",
        "isActive": true,
        "name": "string",
        "quantity": 0,
        "type": "string",
        "updatedAt": "2025-01-01T00:00:00.000Z"
      }
    ],
    "currency": "string",
    "extensions": {},
    "ledgerAccountId": "123e4567-e89b-12d3-a456-426614174000",
    "locationId": "123e4567-e89b-12d3-a456-426614174000",
    "productId": "123e4567-e89b-12d3-a456-426614174000",
    "quantity": 0,
    "stockAdjustmentId": "123e4567-e89b-12d3-a456-426614174000",
    "unitPrice": "100.00"
  }'

Responses

Stock Adjustment Item updated successfully

Bodyapplication/json
batchesArray of objects(BatcheDto)required

Batch-level breakdown of the stock adjustment.

batches[].​batchIdstring or null

Identifier of the batch record.

Example: "123e4567-e89b-12d3-a456-426614174000"
batches[].​createdAtstring or null

Timestamp when this batch record was created.

Example: "2025-01-01T00:00:00.000Z"
batches[].​expiryDatestring or null

Expiry date of the batch, if applicable.

Example: "2025-01-01"
batches[].​isActiveboolean or null

If true, the batch is active.

batches[].​namestring or null

Batch or lot name/number.

batches[].​quantitynumber or null

Quantity from this batch associated with the receive invoice item.

batches[].​typestring or null

Batch type classification.

batches[].​updatedAtstring or null

Timestamp when this batch record was last modified.

Example: "2025-01-01T00:00:00.000Z"
createdAtstring(date-time)required

Timestamp when this stock adjustment item was created.

Example: "2025-01-01T00:00:00.000Z"
currencystringrequired

ISO 4217 currency code for the unitPrice.

extensionsobjectrequired

Vendor- or practice-specific extensions.

ledgerAccountIdstringrequired

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: "123e4567-e89b-12d3-a456-426614174000"
locationIdstringrequired

Identifier of the inventory location where the adjustment is applied.

Example: "123e4567-e89b-12d3-a456-426614174000"
productIdstringrequired

Identifier of the product being adjusted.

Example: "123e4567-e89b-12d3-a456-426614174000"
quantitynumberrequired

Quantity of product adjusted. Positive for increase, negative for decrease.

stockAdjustmentIdstringrequired

Identifier of the parent stock adjustment.

Example: "123e4567-e89b-12d3-a456-426614174000"
stockAdjustmentItemIdstringrequired

Canonical identifier for this stock adjustment line item.

Example: "123e4567-e89b-12d3-a456-426614174000"
unitPricestringrequired

Unit price of the product at the time of adjustment, represented as a decimal string.

Example: "100.00"
updatedAtstring(date-time)required

Timestamp when this stock adjustment item was last updated.

Example: "2025-01-01T00:00:00.000Z"
Response
application/json
{ "batches": [ { … } ], "createdAt": "2025-01-01T00:00:00.000Z", "currency": "string", "extensions": {}, "ledgerAccountId": "123e4567-e89b-12d3-a456-426614174000", "locationId": "123e4567-e89b-12d3-a456-426614174000", "productId": "123e4567-e89b-12d3-a456-426614174000", "quantity": 0, "stockAdjustmentId": "123e4567-e89b-12d3-a456-426614174000", "stockAdjustmentItemId": "123e4567-e89b-12d3-a456-426614174000", "unitPrice": "100.00", "updatedAt": "2025-01-01T00:00:00.000Z" }

Request

Fully replaces an existing Stock Adjustment Item. All fields must be provided.

Security
bearer
Path
siteIdnumberrequired

Site identifier

stockAdjustmentItemIdstringrequired

Stock Adjustment Item unique identifier (UUID)

Bodyapplication/jsonrequired
batchesArray of objects(BatcheDto)required

Batch-level breakdown of the stock adjustment.

batches[].​batchIdstring or null

Identifier of the batch record.

Example: "123e4567-e89b-12d3-a456-426614174000"
batches[].​createdAtstring or null

Timestamp when this batch record was created.

Example: "2025-01-01T00:00:00.000Z"
batches[].​expiryDatestring or null

Expiry date of the batch, if applicable.

Example: "2025-01-01"
batches[].​isActiveboolean or null

If true, the batch is active.

batches[].​namestring or null

Batch or lot name/number.

batches[].​quantitynumber or null

Quantity from this batch associated with the receive invoice item.

batches[].​typestring or null

Batch type classification.

batches[].​updatedAtstring or null

Timestamp when this batch record was last modified.

Example: "2025-01-01T00:00:00.000Z"
currencystringrequired

ISO 4217 currency code for the unitPrice.

extensionsobjectrequired

Vendor- or practice-specific extensions.

ledgerAccountIdstringrequired

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: "123e4567-e89b-12d3-a456-426614174000"
locationIdstringrequired

Identifier of the inventory location where the adjustment is applied.

Example: "123e4567-e89b-12d3-a456-426614174000"
productIdstringrequired

Identifier of the product being adjusted.

Example: "123e4567-e89b-12d3-a456-426614174000"
quantitynumberrequired

Quantity of product adjusted. Positive for increase, negative for decrease.

stockAdjustmentIdstringrequired

Identifier of the parent stock adjustment.

Example: "123e4567-e89b-12d3-a456-426614174000"
unitPricestringrequired

Unit price of the product at the time of adjustment, represented as a decimal string.

Example: "100.00"
curl -i -X PUT \
  'https://docs.heydonto.com/_mock/apis/animal-health/openapi/site/{siteId}/ahds/v1/stock-adjustment-item/{stockAdjustmentItemId}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "batches": [
      {
        "batchId": "123e4567-e89b-12d3-a456-426614174000",
        "createdAt": "2025-01-01T00:00:00.000Z",
        "expiryDate": "2025-01-01",
        "isActive": true,
        "name": "string",
        "quantity": 0,
        "type": "string",
        "updatedAt": "2025-01-01T00:00:00.000Z"
      }
    ],
    "currency": "string",
    "extensions": {},
    "ledgerAccountId": "123e4567-e89b-12d3-a456-426614174000",
    "locationId": "123e4567-e89b-12d3-a456-426614174000",
    "productId": "123e4567-e89b-12d3-a456-426614174000",
    "quantity": 0,
    "stockAdjustmentId": "123e4567-e89b-12d3-a456-426614174000",
    "unitPrice": "100.00"
  }'

Responses

Stock Adjustment Item replaced successfully

Bodyapplication/json
batchesArray of objects(BatcheDto)required

Batch-level breakdown of the stock adjustment.

batches[].​batchIdstring or null

Identifier of the batch record.

Example: "123e4567-e89b-12d3-a456-426614174000"
batches[].​createdAtstring or null

Timestamp when this batch record was created.

Example: "2025-01-01T00:00:00.000Z"
batches[].​expiryDatestring or null

Expiry date of the batch, if applicable.

Example: "2025-01-01"
batches[].​isActiveboolean or null

If true, the batch is active.

batches[].​namestring or null

Batch or lot name/number.

batches[].​quantitynumber or null

Quantity from this batch associated with the receive invoice item.

batches[].​typestring or null

Batch type classification.

batches[].​updatedAtstring or null

Timestamp when this batch record was last modified.

Example: "2025-01-01T00:00:00.000Z"
createdAtstring(date-time)required

Timestamp when this stock adjustment item was created.

Example: "2025-01-01T00:00:00.000Z"
currencystringrequired

ISO 4217 currency code for the unitPrice.

extensionsobjectrequired

Vendor- or practice-specific extensions.

ledgerAccountIdstringrequired

Identifier of the ledger account associated with this adjustment line, if applicable.

Example: "123e4567-e89b-12d3-a456-426614174000"
locationIdstringrequired

Identifier of the inventory location where the adjustment is applied.

Example: "123e4567-e89b-12d3-a456-426614174000"
productIdstringrequired

Identifier of the product being adjusted.

Example: "123e4567-e89b-12d3-a456-426614174000"
quantitynumberrequired

Quantity of product adjusted. Positive for increase, negative for decrease.

stockAdjustmentIdstringrequired

Identifier of the parent stock adjustment.

Example: "123e4567-e89b-12d3-a456-426614174000"
stockAdjustmentItemIdstringrequired

Canonical identifier for this stock adjustment line item.

Example: "123e4567-e89b-12d3-a456-426614174000"
unitPricestringrequired

Unit price of the product at the time of adjustment, represented as a decimal string.

Example: "100.00"
updatedAtstring(date-time)required

Timestamp when this stock adjustment item was last updated.

Example: "2025-01-01T00:00:00.000Z"
Response
application/json
{ "batches": [ { … } ], "createdAt": "2025-01-01T00:00:00.000Z", "currency": "string", "extensions": {}, "ledgerAccountId": "123e4567-e89b-12d3-a456-426614174000", "locationId": "123e4567-e89b-12d3-a456-426614174000", "productId": "123e4567-e89b-12d3-a456-426614174000", "quantity": 0, "stockAdjustmentId": "123e4567-e89b-12d3-a456-426614174000", "stockAdjustmentItemId": "123e4567-e89b-12d3-a456-426614174000", "unitPrice": "100.00", "updatedAt": "2025-01-01T00:00:00.000Z" }

Request

Permanently deletes a Stock Adjustment Item record.

Security
bearer
Path
siteIdnumberrequired

Site identifier

stockAdjustmentItemIdstringrequired

Stock Adjustment Item unique identifier (UUID)

curl -i -X DELETE \
  'https://docs.heydonto.com/_mock/apis/animal-health/openapi/site/{siteId}/ahds/v1/stock-adjustment-item/{stockAdjustmentItemId}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Stock Adjustment Item deleted successfully

Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations
Operations