> For the complete documentation index, see [llms.txt](https://docs.hos.accessacloud.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hos.accessacloud.com/evo-stock-api/models.md).

# Models

## The Pagination object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"Pagination":{"type":"object","required":["page_size","has_next_page","next_cursor"],"properties":{"page_size":{"type":"integer","description":"The page size used for this request."},"has_next_page":{"type":"boolean","description":"Whether more results exist beyond this page."},"next_cursor":{"type":"string","nullable":true,"description":"Cursor to pass as the cursor query parameter for the next page. Null when there are no more results."}}}}}}
```

## The PaginatedResponse object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"PaginatedResponse":{"type":"object","required":["data","pagination"],"properties":{"data":{"type":"array","items":{}},"pagination":{"$ref":"#/components/schemas/Pagination"}}},"Pagination":{"type":"object","required":["page_size","has_next_page","next_cursor"],"properties":{"page_size":{"type":"integer","description":"The page size used for this request."},"has_next_page":{"type":"boolean","description":"Whether more results exist beyond this page."},"next_cursor":{"type":"string","nullable":true,"description":"Cursor to pass as the cursor query parameter for the next page. Null when there are no more results."}}}}}}
```

## The Error object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"string","description":"Human-readable error message."}}}}}}
```

## The SiteParentRef object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"SiteParentRef":{"type":"object","description":"Lightweight reference to a parent site.","required":["id","name"],"properties":{"id":{"type":"string"},"name":{"type":"string"}}}}}}
```

## The Site object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"Site":{"type":"object","required":["id","tenantId","name","active","sortOrder","availableForRequisition","deleted","type","path","depth","createdAt","updatedAt"],"properties":{"id":{"type":"string","description":"Unique site identifier (CUID)."},"tenantId":{"type":"string"},"name":{"type":"string","maxLength":200},"active":{"type":"boolean"},"externalId":{"type":"string","format":"uuid","nullable":true},"pwExternalId":{"type":"integer","nullable":true},"sortOrder":{"type":"integer"},"preferredCurrencyLocale":{"type":"string","nullable":true},"defaultLanguage":{"type":"string","nullable":true},"currencyCode":{"type":"string","nullable":true,"maxLength":10},"timezone":{"type":"string","nullable":true,"maxLength":50},"code":{"type":"string","nullable":true,"maxLength":100},"availableForRequisition":{"type":"boolean"},"address":{"type":"string","nullable":true},"deleted":{"type":"boolean"},"type":{"type":"string","enum":["MANAGEMENT","STANDARD"]},"parentSiteId":{"type":"string","nullable":true},"path":{"type":"string"},"depth":{"type":"integer"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"},"parentSite":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/SiteParentRef"}]}}},"SiteParentRef":{"type":"object","description":"Lightweight reference to a parent site.","required":["id","name"],"properties":{"id":{"type":"string"},"name":{"type":"string"}}}}}}
```

## The ProductCategoryRef object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"ProductCategoryRef":{"type":"object","description":"Lightweight reference to a product category.","required":["id","categoryName","categoryCode"],"properties":{"id":{"type":"string"},"categoryName":{"type":"string"},"categoryCode":{"type":"string"}}}}}}
```

## The Product object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"Product":{"type":"object","required":["id","tenantId","productCode","productName","categoryId","unitOfMeasure","isPerishable","storageTemperature","active","autoConsumed","createdAt","updatedAt"],"properties":{"id":{"type":"string","description":"Unique product identifier (CUID)."},"tenantId":{"type":"string"},"productCode":{"type":"string","maxLength":100},"barcode":{"type":"string","nullable":true,"maxLength":100},"productName":{"type":"string","maxLength":255},"description":{"type":"string","nullable":true},"categoryId":{"type":"string"},"unitOfMeasure":{"type":"string","maxLength":50},"isPerishable":{"type":"boolean"},"shelfLifeDays":{"type":"integer","nullable":true},"storageTemperature":{"type":"string","enum":["frozen","refrigerated","room_temp","ambient"]},"allergenInfo":{"nullable":true,"description":"Free-form allergen data (JSON)."},"supplierPartNumber":{"type":"string","nullable":true,"maxLength":100},"lastCost":{"type":"string","format":"decimal","nullable":true},"averageCost":{"type":"string","format":"decimal","nullable":true},"preferredCurrencyCode":{"type":"string","nullable":true,"maxLength":3},"parLevel":{"type":"string","format":"decimal","nullable":true},"active":{"type":"boolean"},"varianceThresholdAbsolute":{"type":"string","format":"decimal","nullable":true},"varianceThresholdPercentage":{"type":"string","format":"decimal","nullable":true},"autoConsumed":{"type":"boolean"},"externalId":{"type":"string","nullable":true},"pwPacksInCase":{"type":"integer","nullable":true},"pwUnitsInPack":{"type":"integer","nullable":true},"pwUnitCount":{"type":"integer","nullable":true},"pwUnitSize":{"type":"string","format":"decimal","nullable":true},"pwUnitMeasure":{"type":"string","nullable":true},"sourceSystem":{"type":"string","nullable":true},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"},"category":{"$ref":"#/components/schemas/ProductCategoryRef"}}},"ProductCategoryRef":{"type":"object","description":"Lightweight reference to a product category.","required":["id","categoryName","categoryCode"],"properties":{"id":{"type":"string"},"categoryName":{"type":"string"},"categoryCode":{"type":"string"}}}}}}
```

## The Supplier object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"Supplier":{"type":"object","required":["id","tenantId","supplierCode","supplierName","active","createdAt","updatedAt"],"properties":{"id":{"type":"string","description":"Unique supplier identifier (CUID)."},"tenantId":{"type":"string"},"supplierCode":{"type":"string","maxLength":50},"supplierName":{"type":"string","maxLength":255},"contactName":{"type":"string","nullable":true,"maxLength":255},"email":{"type":"string","nullable":true,"maxLength":255},"phone":{"type":"string","nullable":true,"maxLength":50},"address":{"type":"string","nullable":true},"paymentTerms":{"type":"string","nullable":true,"maxLength":100},"logoS3Key":{"type":"string","nullable":true},"active":{"type":"boolean"},"externalSupplierId":{"type":"integer","nullable":true},"sourceSystem":{"type":"string","nullable":true},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}}}}}}
```

## The DeliverySource object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"DeliverySource":{"type":"string","enum":["DELIVERYHUB","MANUAL","SCAN","INTEGRATION"]}}}}
```

## The DeliveryStatus object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"DeliveryStatus":{"type":"string","enum":["PENDING","PARTIALLY_RECEIVED","OVERDUE","COMPLETE","CONFIRMED","CANCELLED"]}}}}
```

## The SupplierRef object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"SupplierRef":{"type":"object","description":"Lightweight reference to a supplier.","required":["id","supplierName","supplierCode"],"properties":{"id":{"type":"string"},"supplierName":{"type":"string"},"supplierCode":{"type":"string"}}}}}}
```

## The SiteRef object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"SiteRef":{"type":"object","description":"Lightweight reference to a site.","required":["id","name"],"properties":{"id":{"type":"string"},"name":{"type":"string"}}}}}}
```

## The DeliveryLineSummary object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"DeliveryLineSummary":{"type":"object","description":"Summary of a delivery line item as returned in list/detail responses.","required":["id","productId","quantityReceived","unitCost","totalCost"],"properties":{"id":{"type":"string"},"productId":{"type":"string"},"quantityReceived":{"type":"string","format":"decimal"},"unitCost":{"type":"string","format":"decimal"},"totalCost":{"type":"string","format":"decimal"}}}}}}
```

## The Delivery object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"Delivery":{"type":"object","required":["id","tenantId","deliveryNoteNumber","supplierId","siteId","deliveryDate","deliveryTime","receivedBy","source","status","totalItems","totalValue","imageUrls","createdBy","createdAt","updatedAt"],"properties":{"id":{"type":"string","description":"Unique delivery identifier (CUID)."},"tenantId":{"type":"string"},"deliveryNoteNumber":{"type":"string","maxLength":100},"supplierId":{"type":"string"},"siteId":{"type":"string"},"purchaseOrderId":{"type":"string","nullable":true},"integrationId":{"type":"string","nullable":true},"externalOrderId":{"type":"integer","nullable":true,"description":"External order ID from third-party systems."},"locationId":{"type":"string","nullable":true,"description":"Deprecated — use siteId instead. Retained for backward compatibility.","deprecated":true},"deliveryDate":{"type":"string","format":"date-time"},"deliveryTime":{"type":"string","maxLength":10},"receivedBy":{"type":"string","maxLength":255},"source":{"$ref":"#/components/schemas/DeliverySource"},"status":{"$ref":"#/components/schemas/DeliveryStatus"},"expectedDate":{"type":"string","format":"date-time","nullable":true},"confirmedDate":{"type":"string","format":"date-time","nullable":true},"confirmedBy":{"type":"string","nullable":true,"maxLength":255},"totalItems":{"type":"integer"},"totalValue":{"type":"string","format":"decimal"},"notes":{"type":"string","nullable":true},"imageUrls":{"type":"array","items":{"type":"string"}},"createdBy":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"},"supplier":{"$ref":"#/components/schemas/SupplierRef"},"site":{"$ref":"#/components/schemas/SiteRef"},"lines":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryLineSummary"}}}},"DeliverySource":{"type":"string","enum":["DELIVERYHUB","MANUAL","SCAN","INTEGRATION"]},"DeliveryStatus":{"type":"string","enum":["PENDING","PARTIALLY_RECEIVED","OVERDUE","COMPLETE","CONFIRMED","CANCELLED"]},"SupplierRef":{"type":"object","description":"Lightweight reference to a supplier.","required":["id","supplierName","supplierCode"],"properties":{"id":{"type":"string"},"supplierName":{"type":"string"},"supplierCode":{"type":"string"}}},"SiteRef":{"type":"object","description":"Lightweight reference to a site.","required":["id","name"],"properties":{"id":{"type":"string"},"name":{"type":"string"}}},"DeliveryLineSummary":{"type":"object","description":"Summary of a delivery line item as returned in list/detail responses.","required":["id","productId","quantityReceived","unitCost","totalCost"],"properties":{"id":{"type":"string"},"productId":{"type":"string"},"quantityReceived":{"type":"string","format":"decimal"},"unitCost":{"type":"string","format":"decimal"},"totalCost":{"type":"string","format":"decimal"}}}}}}
```

## The LotCodeType object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"LotCodeType":{"type":"string","enum":["NONE","GTIN"]}}}}
```

## The DeliveryLineInput object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"DeliveryLineInput":{"type":"object","required":["productId","quantityReceived","unitCost","totalCost"],"properties":{"productId":{"type":"string"},"quantityReceived":{"type":"number","format":"decimal"},"unitCost":{"type":"number","format":"decimal"},"totalCost":{"type":"number","format":"decimal"},"currencyCode":{"type":"string","maxLength":3},"expiryDate":{"type":"string","format":"date","description":"ISO 8601 date (e.g. `2026-12-31`)."},"batchNumber":{"type":"string","maxLength":100},"storageLocation":{"type":"string","maxLength":255},"lotCode":{"type":"string","maxLength":100},"lotCodeType":{"$ref":"#/components/schemas/LotCodeType"}}},"LotCodeType":{"type":"string","enum":["NONE","GTIN"]}}}}
```

## The CreateDeliveryInput object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"CreateDeliveryInput":{"type":"object","required":["deliveryNoteNumber","supplierId","siteId","deliveryDate","deliveryTime","receivedBy","createdBy"],"properties":{"deliveryNoteNumber":{"type":"string","maxLength":100},"supplierId":{"type":"string"},"siteId":{"type":"string"},"deliveryDate":{"type":"string","format":"date","description":"ISO 8601 date (e.g. `2026-04-15`)."},"deliveryTime":{"type":"string","maxLength":10},"receivedBy":{"type":"string","maxLength":255},"createdBy":{"type":"string"},"source":{"type":"string","description":"Delivery source. Defaults to INTEGRATION.","default":"INTEGRATION","enum":["DELIVERYHUB","MANUAL","SCAN","INTEGRATION"]},"status":{"type":"string","description":"Delivery status. Defaults to PENDING.","default":"PENDING","enum":["PENDING","PARTIALLY_RECEIVED","OVERDUE","COMPLETE","CONFIRMED","CANCELLED"]},"expectedDate":{"type":"string","format":"date"},"purchaseOrderId":{"type":"string"},"integrationId":{"type":"string"},"notes":{"type":"string"},"imageUrls":{"type":"array","items":{"type":"string"}},"lines":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryLineInput"}}}},"DeliveryLineInput":{"type":"object","required":["productId","quantityReceived","unitCost","totalCost"],"properties":{"productId":{"type":"string"},"quantityReceived":{"type":"number","format":"decimal"},"unitCost":{"type":"number","format":"decimal"},"totalCost":{"type":"number","format":"decimal"},"currencyCode":{"type":"string","maxLength":3},"expiryDate":{"type":"string","format":"date","description":"ISO 8601 date (e.g. `2026-12-31`)."},"batchNumber":{"type":"string","maxLength":100},"storageLocation":{"type":"string","maxLength":255},"lotCode":{"type":"string","maxLength":100},"lotCodeType":{"$ref":"#/components/schemas/LotCodeType"}}},"LotCodeType":{"type":"string","enum":["NONE","GTIN"]}}}}
```

## The UpdateDeliveryInput object

```json
{"openapi":"3.0.1","info":{"title":"EvoStock APIM Operations API","version":"0.1"},"components":{"schemas":{"UpdateDeliveryInput":{"type":"object","description":"All fields are optional. Only provided fields are updated. If lines is provided, existing lines are deleted and replaced wholesale.","properties":{"deliveryNoteNumber":{"type":"string","maxLength":100},"supplierId":{"type":"string"},"siteId":{"type":"string"},"deliveryDate":{"type":"string","format":"date"},"deliveryTime":{"type":"string","maxLength":10},"receivedBy":{"type":"string","maxLength":255},"source":{"$ref":"#/components/schemas/DeliverySource"},"status":{"$ref":"#/components/schemas/DeliveryStatus"},"expectedDate":{"type":"string","format":"date"},"confirmedDate":{"type":"string","format":"date-time"},"confirmedBy":{"type":"string","maxLength":255},"purchaseOrderId":{"type":"string"},"integrationId":{"type":"string"},"notes":{"type":"string"},"imageUrls":{"type":"array","items":{"type":"string"}},"lines":{"type":"array","description":"If provided, all existing delivery lines are removed and replaced with this array. Omit to leave lines unchanged.","items":{"$ref":"#/components/schemas/DeliveryLineInput"}}}},"DeliverySource":{"type":"string","enum":["DELIVERYHUB","MANUAL","SCAN","INTEGRATION"]},"DeliveryStatus":{"type":"string","enum":["PENDING","PARTIALLY_RECEIVED","OVERDUE","COMPLETE","CONFIRMED","CANCELLED"]},"DeliveryLineInput":{"type":"object","required":["productId","quantityReceived","unitCost","totalCost"],"properties":{"productId":{"type":"string"},"quantityReceived":{"type":"number","format":"decimal"},"unitCost":{"type":"number","format":"decimal"},"totalCost":{"type":"number","format":"decimal"},"currencyCode":{"type":"string","maxLength":3},"expiryDate":{"type":"string","format":"date","description":"ISO 8601 date (e.g. `2026-12-31`)."},"batchNumber":{"type":"string","maxLength":100},"storageLocation":{"type":"string","maxLength":255},"lotCode":{"type":"string","maxLength":100},"lotCodeType":{"$ref":"#/components/schemas/LotCodeType"}}},"LotCodeType":{"type":"string","enum":["NONE","GTIN"]}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.hos.accessacloud.com/evo-stock-api/models.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
