Skip to main content

v2.product.get_attribute_tree

GET /api/v2/product/get_attribute_tree

Get the attribute tree for categories

Endpoint URL

URL: https://partner.shopeemobile.com/api/v2/product/get_attribute_tree

Common Request Parameters

NameTypeSampleDescription
partner_idint1Partner ID is assigned upon registration is successful. Required for all requests.
timestamptimestamp1610000000This is to indicate the timestamp of the request. Required for all requests. Expires in 5 minutes.
access_tokenstringc09222e3fc40ffb25fc947f738b1abf1The token for API access, using to identify your permission to the api. Valid for multiple use and expires in 4 hours.
shop_idint600000Shopee's unique identifier for a shop. Required param for most APIs.
signstringe318d3e932719916a9f9ebb57e2011961bd47abfa54a36e040d050d8931596e2Signature generated by partner_id, api path, timestamp, access_token, shop_id and partner_key via HMAC-SHA256 hashing algorithm. More details: https://open.shopee.com/documents?module=87&type=2&id=58&version=2

Request Parameters

NameTypeRequiredSampleDescription
category_id_listint[]Truemax count is 20
languagestringFalse"en"Language Support Lanuage: "SG": [ "en", "zh-Hans", "ms" ], "MY": [ "en", "zh-Hans", "ms" ], "PH": [ "en", "zh-Hans" ], "VN": [ "vn", "en" ], "ID": [ "id", "en" ], "TH": [ "th", "en" ], "BR": [ "pt-BR", "en" ], "MX": [ "es-MX", "en" ], "CO": [ "es-CO", "en" ], "CL": [ "es-CL", "en" ], "TW": [ "zh-Hant", "zh-Hans", "en" ], "IN": [ "en", "hi" ]

Response Parameters

NameTypeSampleDescription
errorstringError
messagestringMessage
warningstringWarning
request_idstringRequest ID
responseobjectResopnse
listobject[]Each result corresponds to one category in category_ids
attribute_treeobject[]One category's attribute trees
attribute_idintAttribute ID
mandatorybooleantrueIs mandatory or not
namestringAttribute Name
attribute_value_listobject[]All available values for this attribute
value_idintValue ID
namestringValue name
value_unitstringValue unit
child_attribute_listobject[]Child attributes for the value of parent attribute The structure content is the same as attribute_tree
multi_langobject[]Translate results for display
languagestringLanguage
valuestringTranslate result
attribute_infoobjectAttribute extra info
input_typeintSINGLE_DROP_DOWN = 1 SINGLE_COMBO_BOX = 2 FREE_TEXT_FILED        = 3 MULTI_DROP_DOWN   = 4 MULTI_COMBO_BOX   = 5
input_validation_typeintVALIDATOR_NO_VALIDATE_TYPE =  0 VALIDATOR_INT_TYPE = 1 VALIDATOR_STRING_TYPE = 2 VALIDATOR_FLOAT_TYPE = 3 VALIDATOR_DATE_TYPE = 4
format_typeintFORMAT_NORMAL = 1 FORMAT_QUANTITATIVE_WITH_UNIT = 2
date_format_typeintYEAR_MONTH_DATE = 0 (DD/MM/YYYY) YEAR_MONTH = 1 (MM/YYYY)
attribute_unit_liststring[]Attribute's available units list
max_value_countintMax selected value count
introductionstringIntroduction for special Attribute
is_oemboolean
support_search_valuebooleanIndicates whether this attribute has searchable values. If yes, please call v2.product.search_attribute_value_list to get the default values
multi_langobject[]Attribute translate info
languagestringLanguage
valuestringTranslate result
category_idintCategory ID
warningstringWarning msg