Get Product Inventory Details

Retrieves the inventory details of a product by its unique identifier (product_id).

🔒

Requires read_inventory access scope. More access scope

The Get Product Inventory Details API Retrieves the inventory details of a product by its unique identifier (product_id).

This API is especially useful for:

  1. Checking real-time product inventory levels.
  2. Managing stock across multiple locations.
  3. Synchronizing inventory data with external systems.

Request Parameters

Public Request Parameters

📘

Path Parameters

ParameterTypeRequiredDescriptionExample
product_idstringYesUnique identifier of the product.prod_123456
location_idstringNoUnique identifier of the location to filter inventory details (optional).loc_789

Response Explanation

Public Response Parameters

📘

Successful Response

ParameterTypeExampleDescription
codestring"success"Error code indicating request status.
messagestringDescriptive message about the response.
data.product_idstring"prod_123456"Unique identifier of the product.
data.stockint32150Product's total inventory quantity.
data.variantsarray[object]-List of variant objects.
data.variants.variant_idstring"var_789"Unique identifier of the variant.
data.variants.location_itemsarray[object]-Inventory details per location.
data.variants.location_items.location_idstring"loc_789"Unique location identifier.
data.variants.location_items.stockint3250Current stock at this location.

Error Response

FieldTypeExampleDescription
codestringInvalidParameterError http message
messagestring``Error message
Language
Credentials
Header
URL
Click Try It! to start a request and see the response here!