v1

latestOpenAPI 3.0.0Apache 2.02026-07-142008071.1 MB
Inventory

DeprecatedBatchRetrieveInventoryCounts

Deprecated version of BatchRetrieveInventoryCounts after the endpoint URL is updated to conform to the standard convention.

post/v2/inventory/batch-retrieve-counts

Request body

catalog_object_idsstring[]

The filter to return results by CatalogObject ID. The filter is applicable only when set. The default is null.

cursorstring

A pagination cursor returned by a previous call to this endpoint. Provide this to retrieve the next set of results for the original query.

See the Pagination guide for more information.

location_idsstring[]

The filter to return results by Location ID. This filter is applicable only when set. The default is null.

statesstring[]

The filter to return results by InventoryState. The filter is only applicable when set. Ignored are untracked states of NONE, SOLD, and UNLINKED_RETURN. The default is null.

updated_afterstring

The filter to return results with their calculated_at value after the given time as specified in an RFC 3339 timestamp. The default value is the UNIX epoch of (1970-01-01T00:00:00Z).

Example request

{
  "request_body": {
    "catalog_object_ids": [
      "W62UWFY35CWMYGVWK6TWJDNI"
    ],
    "location_ids": [
      "59TNP9SA8VGDA"
    ],
    "updated_after": "2016-11-16T00:00:00.000Z"
  }
}

Response

Success

cursorstring

The pagination cursor to be used in a subsequent request. If unset, this is the final response.

See the Pagination guide for more information.

Example response

{
  "counts": [
    {
      "calculated_at": "2016-11-16T22:28:01.223Z",
      "catalog_object_id": "W62UWFY35CWMYGVWK6TWJDNI",
      "catalog_object_type": "ITEM_VARIATION",
      "location_id": "59TNP9SA8VGDA",
      "quantity": "79",
      "state": "IN_STOCK"
    }
  ],
  "errors": []
}