Retrieve catalog object
Returns a single CatalogItem as a CatalogObject based on the provided ID.
The returned object includes all of the relevant CatalogItem information including: CatalogItemVariation children, references to its CatalogModifierList objects, and the ids of any CatalogTax objects that apply to it.
Name | Description |
---|---|
object_
Required
|
The object ID of any type of catalog objects to be retrieved. |
Name | Description |
---|---|
include_
|
If if the Default value: |
catalog_
Beta
|
Requests objects as of a specific version of the catalog. This allows you to retrieve historical versions of objects. The value to retrieve a specific version of an object can be found in the version field of CatalogObjects. If not included, results will be from the current version of the catalog. |
Response Fields
Name | Description |
---|---|
errors
|
Any errors that occurred during the request. |
object
|
The |
related_
|
A list of |
Examples
Example:- cURL
- Ruby
- Python
- C#
- Java
- PHP
- Node.js
curl https://connect.squareup.com/v2/catalog/object/W62UWFY35CWMYGVWK6TWJDNI \
-H 'Square-Version: 2022-07-20' \
-H 'Authorization: Bearer ACCESS_TOKEN' \
-H 'Content-Type: application/json'
{
"object": {
"type": "ITEM",
"id": "W62UWFY35CWMYGVWK6TWJDNI",
"updated_at": "2016-11-16T22:25:24.878Z",
"version": 1479335124878,
"is_deleted": false,
"present_at_all_locations": true,
"item_data": {
"name": "Tea",
"description": "Hot Leaf Juice",
"category_id": "BJNQCF2FJ6S6UIDT65ABHLRX",
"tax_ids": [
"HURXQOOAIC4IZSI2BEXQRYFY"
],
"variations": [
{
"type": "ITEM_VARIATION",
"id": "2TZFAOHWGG7PAK2QEXWYPZSP",
"updated_at": "2016-11-16T22:25:24.878Z",
"version": 1479335124878,
"is_deleted": false,
"present_at_all_locations": true,
"item_variation_data": {
"item_id": "W62UWFY35CWMYGVWK6TWJDNI",
"name": "Mug",
"ordinal": 0,
"pricing_type": "FIXED_PRICING",
"price_money": {
"amount": 150,
"currency": "USD"
}
}
}
]
}
}
}