Inventory
Private Inventory API endpoints
Query parameters
pageoptionalintegerPage number
Defaults to 1.
per_pageoptionalintegerItems per page
Defaults to 15.
group_idoptionalintegerFilter by inventory group ID
statusoptionalbooleanFilter by active status
queryoptionalstringSearch by name or SKU
Returnsobject
Inventory items list response
Error responses
422objectA query parameter fails validation: page is not an integer of at least 1, per_page is not an integer between 1 and 100, group_id is not an integer, status is not 0 or 1, or query is longer than 255 characters.
Request body
nameRequiredstringskuRequiredstringUnique SKU within the shop
stock_countRequiredintegerstatusRequiredintegerPossible values: 0, 1.
priorityoptionalinteger | nullinventory_group_idoptionalinteger | nullbuy_priceoptionalinteger | nullBuy price in cents
msrp_priceoptionalinteger | nullMSRP price in cents
descriptionoptionalstring | nullphoto_urloptionalstring | nullFormat: url.
weightoptionalnumber | nullwidthoptionalnumber | nullheightoptionalnumber | nulldepthoptionalnumber | nullhs_codeoptionalstring | nullHarmonized System code
country_origin_idoptionalinteger | nullCountry of origin ID
tagsoptionalobjectReturnsInventoryItem
Inventory item created successfully
Error responses
422objectThe body fails validation. name, sku, stock_count and status are required. sku must be at most 100 characters and unique among the non-archived items of the shop ("The sku has already been taken."). status must be 0 or 1. inventory_group_id must be a group of this shop that is not deleted, and country_origin_id must be an existing shipping country. priority must be at least 1, buy_price and msrp_price at least 0, and weight, width, height and depth at least 0.01. name, description and hs_code allow up to 255 characters, photo_url must be a valid URL, and each tags.create.*.value must be a distinct string of up to 255 characters.
Path parameters
inventory_item_idRequiredintegerInventory item ID
ReturnsInventoryItem
Inventory item object response
Error responses
400objectThe inventory item exists but belongs to another shop.
404objectNo inventory item exists with this ID.
Path parameters
inventory_item_idRequiredintegerInventory item ID
Request body
nameoptionalstringskuoptionalstringstock_countoptionalintegerstatusoptionalintegerPossible values: 0, 1.
priorityoptionalinteger | nullinventory_group_idoptionalintegerbuy_priceoptionalinteger | nullBuy price in cents
msrp_priceoptionalinteger | nullMSRP price in cents
descriptionoptionalstring | nullphoto_urloptionalstring | nullFormat: url.
weightoptionalnumber | nullwidthoptionalnumber | nullheightoptionalnumber | nulldepthoptionalnumber | nullhs_codeoptionalstring | nullcountry_origin_idoptionalinteger | nulltagsoptionalobjectReturnsInventoryItem
Inventory item updated successfully
Error responses
400objectThe inventory item is archived (entity_archived), or it belongs to another shop (bad_request).
404objectNo inventory item exists with this ID.
422objectA field you send fails validation. Every field is optional, but each one follows the create rules. sku must be unique among the other non-archived items of the shop ("The sku has already been taken."). inventory_group_id cannot be null and must be a group of this shop that is not deleted. country_origin_id must be an existing shipping country. Each tags.delete.*.id must be an integer.
Path parameters
inventory_item_idRequiredintegerInventory item ID
ReturnsInventoryItem
Inventory item archived
Error responses
400objectThe inventory item is already archived (entity_archived), or it belongs to another shop (bad_request).
404objectNo inventory item exists with this ID.
Query parameters
pageoptionalintegerPage number
Defaults to 1.
per_pageoptionalintegerItems per page
Defaults to 15.
queryoptionalstringSearch by name or brand name
Returnsobject
Inventory groups list response
Error responses
422objectA query parameter fails validation: page is not an integer of at least 1, per_page is not an integer between 1 and 100, or query is longer than 255 characters.
Request body
nameRequiredstringbrand_nameoptionalstring | nullReturnsInventoryGroup
Inventory group created successfully
Error responses
422objectname is missing, is not a string, or is longer than 255 characters, or brand_name is not a string or is longer than 255 characters.
Path parameters
inventory_group_idRequiredintegerInventory group ID
ReturnsInventoryGroup
Inventory group object response
Error responses
400objectThe inventory group exists but belongs to another shop.
404objectNo inventory group exists with this ID, or the group is deleted.
Path parameters
inventory_group_idRequiredintegerInventory group ID
Request body
nameoptionalstringbrand_nameoptionalstring | nulldescriptionoptionalstring | nullReturnsInventoryGroup
Inventory group updated successfully
Error responses
400objectThe inventory group exists but belongs to another shop.
404objectNo inventory group exists with this ID, or the group is deleted.
422objectname is not a string or is longer than 255 characters, brand_name is not a string or is longer than 255 characters, or description is not a string.