curl --request POST \
--url 'https://prod-api.stateset.cloud.stateset.app/api/v1/inventory' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"description": "Premium Widget - Blue Edition",
"item_number": "SKU-WIDGET-001",
"location_id": 1,
"organization_id": 1,
"primary_uom_code": "EA",
"quantity_on_hand": 500,
"reason": "Initial stock receipt from supplier PO-2024-001"
}'
{
"data": {
"description": "Premium Widget - Blue Edition",
"inventory_item_id": 12345,
"item_number": "SKU-WIDGET-001",
"locations": [
{
"location_id": 1,
"location_name": "Main Warehouse",
"quantities": {
"allocated": "30",
"available": "270",
"on_hand": "300"
},
"updated_at": "2024-12-09T10:30:00Z",
"version": 5
},
{
"location_id": 2,
"location_name": "Distribution Center East",
"quantities": {
"allocated": "20",
"available": "180",
"on_hand": "200"
},
"updated_at": "2024-12-09T09:15:00Z",
"version": 3
}
],
"organization_id": 1,
"primary_uom_code": "EA",
"quantities": {
"allocated": "50",
"available": "450",
"on_hand": "500"
}
},
"errors": [
"string"
],
"message": "Two-person tent, green — replacement for damaged pole set.",
"meta": {
"request_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"timestamp": "2026-08-31T14:22:05Z"
},
"success": true
}
Create an inventory
Create an inventory
POST
/
api
/
v1
/
inventory
curl --request POST \
--url 'https://prod-api.stateset.cloud.stateset.app/api/v1/inventory' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"description": "Premium Widget - Blue Edition",
"item_number": "SKU-WIDGET-001",
"location_id": 1,
"organization_id": 1,
"primary_uom_code": "EA",
"quantity_on_hand": 500,
"reason": "Initial stock receipt from supplier PO-2024-001"
}'
{
"data": {
"description": "Premium Widget - Blue Edition",
"inventory_item_id": 12345,
"item_number": "SKU-WIDGET-001",
"locations": [
{
"location_id": 1,
"location_name": "Main Warehouse",
"quantities": {
"allocated": "30",
"available": "270",
"on_hand": "300"
},
"updated_at": "2024-12-09T10:30:00Z",
"version": 5
},
{
"location_id": 2,
"location_name": "Distribution Center East",
"quantities": {
"allocated": "20",
"available": "180",
"on_hand": "200"
},
"updated_at": "2024-12-09T09:15:00Z",
"version": 3
}
],
"organization_id": 1,
"primary_uom_code": "EA",
"quantities": {
"allocated": "50",
"available": "450",
"on_hand": "500"
}
},
"errors": [
"string"
],
"message": "Two-person tent, green — replacement for damaged pole set.",
"meta": {
"request_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"timestamp": "2026-08-31T14:22:05Z"
},
"success": true
}
Request body
CreateInventoryRequest
string,null
Item description (max 500 characters)
string
required
SKU or item number (1-100 characters)
integer (int32)
required
Location ID (must be positive)
integer,null (int64)
Organization ID (must be positive if provided)
string,null
Unit of measure code (e.g., ‘EA’, ‘KG’, ‘LB’)
integer (int64)
required
Initial quantity on hand (cannot be negative)
string,null
Reason for inventory adjustment (max 200 characters)
Response
ApiResponse_InventoryItem
object
API representation of aggregated inventory for an item.
Show data
Show data
string,null
Item description
integer (int64)
required
Internal inventory item ID
string
required
SKU or item number
InventoryLocation[]
required
Inventory breakdown by location
Show InventoryLocation
Show InventoryLocation
integer (int32)
required
Location identifier
string,null
Human-readable location name
InventoryQuantities
required
Quantities at this location
string
required
Last update timestamp (RFC3339)
integer (int32)
required
Version number for optimistic locking. Include this in update requests to prevent lost updates.
integer (int64)
required
Organization ID
string,null
Unit of measure code
array,null
string,null
boolean
required
Status codes
| Code | Meaning |
|---|---|
201 | Inventory created |
400 | Bad request |
401 | Unauthorized |
429 | Rate limit exceeded |
curl --request POST \
--url 'https://prod-api.stateset.cloud.stateset.app/api/v1/inventory' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"description": "Premium Widget - Blue Edition",
"item_number": "SKU-WIDGET-001",
"location_id": 1,
"organization_id": 1,
"primary_uom_code": "EA",
"quantity_on_hand": 500,
"reason": "Initial stock receipt from supplier PO-2024-001"
}'
{
"data": {
"description": "Premium Widget - Blue Edition",
"inventory_item_id": 12345,
"item_number": "SKU-WIDGET-001",
"locations": [
{
"location_id": 1,
"location_name": "Main Warehouse",
"quantities": {
"allocated": "30",
"available": "270",
"on_hand": "300"
},
"updated_at": "2024-12-09T10:30:00Z",
"version": 5
},
{
"location_id": 2,
"location_name": "Distribution Center East",
"quantities": {
"allocated": "20",
"available": "180",
"on_hand": "200"
},
"updated_at": "2024-12-09T09:15:00Z",
"version": 3
}
],
"organization_id": 1,
"primary_uom_code": "EA",
"quantities": {
"allocated": "50",
"available": "450",
"on_hand": "500"
}
},
"errors": [
"string"
],
"message": "Two-person tent, green — replacement for damaged pole set.",
"meta": {
"request_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"timestamp": "2026-08-31T14:22:05Z"
},
"success": true
}
Last modified on August 31, 2026