getInventory
get
/ccadmin/v1/inventories/{id}
Get Inventory. Get variant or product inventory information based on ID. Optionally takes the x-ccasset-language header to get translated content in another language.
Request
Supported Media Types
- application/json
Path Parameters
- id
-
Type:
string
Required:true
ID of the variant or product.
Query Parameters
- includeDefaultLocationInventory
-
Type:
boolean
flag indicating whether to include the non-geographic default location inventory- locationIds
Type:string
a comma-separated list of location ids- type
Type:string
inventory type, either variant or product. defaults to variantHeader Parameters- X-CCAsset-Language
-
Type:
string
The asset language of the request
Response
Supported Media Types- application/json
200 ResponseFollowing model is returned when operation succeeds.BodyRoot Schema : getInventory_response- example with locationIds
-
Type:
object
example with locationIdsAdditional Properties Allowed:Result object with locationIds. - example without locationIds
-
Type:
object
example without locationIdsAdditional Properties Allowed:Result object without locationIds.
Nested Schema : example with locationIdsType:object
Result object with locationIds.- If the selected case was a product.
-
Type:
object
If the selected case was a product.Additional Properties Allowed:Result object if type is product. - If the selected case was a variant.
-
Type:
object
If the selected case was a variant.Additional Properties Allowed:Result object if type is variant.
Nested Schema : example without locationIdsType:object
Result object without locationIds.- If the selected case was a product.
-
Type:
object
If the selected case was a product.Additional Properties Allowed:Result object if type is product. - If the selected case was a variant.
-
Type:
object
If the selected case was a variant.Additional Properties Allowed:Result object if type is variant.
Nested Schema : If the selected case was a product.Type:object
Result object if type is product.- childSKUs
-
Type:
array
childSKUsAdditional Properties Allowed:List of SKU's for the product. - id
-
Type:
string
The ID of the product. - stockStatus
-
Type:
string
The current stock status of the product (inStock or outOfStock). - totalStockLevel
-
Type:
integer
The total stock level of the product.
Nested Schema : If the selected case was a variant.Type:object
Result object if type is variant.- displayName
-
Type:
string
The display name of the SKU. - locationInventoryInfo
-
Type:
array
locationInventoryInfoAdditional Properties Allowed:Location specific inventory information - skuId
-
Type:
string
The SKU ID of the SKU. - skuNumber
-
Type:
string
The SKU number of the SKU.
Nested Schema : childSKUsNested Schema : itemsType:object
- displayName
-
Type:
string
The display name of the SKU. - locationInventoryInfo
-
Type:
array
locationInventoryInfoAdditional Properties Allowed:Location specific inventory information - skuId
-
Type:
string
The SKU ID of the SKU. - skuNumber
-
Type:
string
The SKU number of the SKU.
Nested Schema : locationInventoryInfoNested Schema : itemsType:object
- availabilityDate
-
Type:
string
The date when the SKU will be available. - availabilityStatus
-
Type:
integer
The availability status of the child SKU. - availabilityStatusMsg
-
Type:
string
The current availability status of the child SKU. - availableToPromise
-
Type:
string
The available to promise of the child SKU. - backorderLevel
-
Type:
integer
The back-order level of the child SKU. - backorderThreshold
-
Type:
integer
The back-order threshold of the child SKU. - inventoryId
-
Type:
string
The inventory ID of the SKU. - locationId
-
Type:
string
The location ID of the child SKU. - preorderLevel
-
Type:
integer
The pre-order level of the child SKU. - preorderThreshold
-
Type:
integer
The pre-order threshold of the child SKU. - stockLevel
-
Type:
integer
The stock level of the SKU. - stockThreshold
-
Type:
integer
The stock threshold of the child SKU.
Nested Schema : locationInventoryInfoNested Schema : itemsType:object
- availabilityDate
-
Type:
string
The date when the SKU will be available. - availabilityStatus
-
Type:
integer
The availability status of the child SKU. - availabilityStatusMsg
-
Type:
string
The current availability status of the child SKU. - availableToPromise
-
Type:
string
The available to promise of the child SKU. - backorderLevel
-
Type:
integer
The back-order level of the child SKU. - backorderThreshold
-
Type:
integer
The back-order threshold of the child SKU. - inventoryId
-
Type:
string
The inventory ID of the SKU. - locationId
-
Type:
string
The location ID of the child SKU. - preorderLevel
-
Type:
integer
The pre-order level of the child SKU. - preorderThreshold
-
Type:
integer
The pre-order threshold of the child SKU. - stockLevel
-
Type:
integer
The stock level of the SKU. - stockThreshold
-
Type:
integer
The stock threshold of the child SKU.
Nested Schema : If the selected case was a product.Type:object
Result object if type is product.- childSKUs
-
Type:
array
childSKUsAdditional Properties Allowed:List of SKU's for the product. - id
-
Type:
string
The ID of the product. - stockStatus
-
Type:
string
The current stock status of the product (inStock or outOfStock). - totalStockLevel
-
Type:
integer
The total stock level of the product.
Nested Schema : If the selected case was a variant.Type:object
Result object if type is variant.- availabilityDate
-
Type:
string
The date when the SKU will be available. - availabilityStatus
-
Type:
integer
The availability status of the child SKU. - availabilityStatusMsg
-
Type:
string
The current availability status of the child SKU. - availableToPromise
-
Type:
string
The available to promise of the child SKU. - backorderLevel
-
Type:
integer
The back-order level of the child SKU. - backorderThreshold
-
Type:
integer
The back-order threshold of the child SKU. - displayName
-
Type:
string
The display name of the SKU. - inventoryId
-
Type:
string
The inventory ID of the SKU. - locationId
-
Type:
string
The location ID of the child SKU. - preorderLevel
-
Type:
integer
The pre-order level of the child SKU. - preorderThreshold
-
Type:
integer
The pre-order threshold of the child SKU. - skuId
-
Type:
string
The SKU ID of the SKU. - skuNumber
-
Type:
string
The SKU number of the SKU. - stockLevel
-
Type:
integer
The stock level of the SKU. - stockThreshold
-
Type:
integer
The stock threshold of the child SKU.
Nested Schema : childSKUsNested Schema : itemsType:object
- availabilityDate
-
Type:
string
The date when the SKU will be available. - availabilityStatus
-
Type:
integer
The availability status of the child SKU. - availabilityStatusMsg
-
Type:
string
The current availability status of the child SKU. - availableToPromise
-
Type:
string
The available to promise of the child SKU. - backorderLevel
-
Type:
integer
The back-order level of the child SKU. - backorderThreshold
-
Type:
integer
The back-order threshold of the child SKU. - displayName
-
Type:
string
The display name of the SKU. - inventoryId
-
Type:
string
The inventory ID of the SKU. - locationId
-
Type:
string
The location ID of the child SKU. - preorderLevel
-
Type:
integer
The pre-order level of the child SKU. - preorderThreshold
-
Type:
integer
The pre-order threshold of the child SKU. - skuId
-
Type:
string
The SKU ID of the SKU. - skuNumber
-
Type:
string
The SKU number of the SKU. - stockLevel
-
Type:
integer
The stock level of the SKU. - stockThreshold
-
Type:
integer
The stock threshold of the child SKU.
Example application/json
{ "preorderThreshold":0, "backorderLevel":0, "displayName":"Cargo Pants", "availabilityDate":null, "stockThreshold":5, "availabilityStatusMsg":"inStock", "stockLevel":12, "availableToPromise":null, "skuNumber":"sku40015", "preorderLevel":0, "locationId":null, "inventoryId":null, "backorderThreshold":0, "links":[ { "rel":"self", "href":"http://www.example.com/v1/inventories/sku40015?locationId=wa-seattle" } ], "availabilityStatus":1000, "locationInventoryInfo":null, "skuId":"sku40015" }
Default ResponseThe error responseBodyRoot Schema : errorModelType:object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - errors
-
Type:
array
errorsAdditional Properties Allowed:An optional list of errors if multiple errors were encountered - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code - type
-
Type:
string
The URI to the HTTP state code definition
Nested Schema : errorsNested Schema : itemsType:object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code
Examples
Sample Response Payload returned by endpoint:
{ "preorderThreshold": 0, "backorderLevel": 0, "displayName": "Cargo Pants", "availabilityDate": null, "stockThreshold": 5, "availabilityStatusMsg": "inStock", "stockLevel": 12, "availableToPromise": null, "skuNumber": "sku40015", "preorderLevel": 0, "locationId": null, "inventoryId": null, "backorderThreshold": 0, "links": [{ "rel": "self", "href": "http://www.example.com/v1/inventories/sku40015?locationId=wa-seattle" }], "availabilityStatus": 1000, "locationInventoryInfo": null, "skuId": "sku40015" }