Overview
Use the Attribute Options By Code API to get all attribute options for the attribute code you pass.
Endpoint
| Method | Path |
|---|---|
POST | /api/v1/search/attributeOptionsByAttributeCode |
POST | /api/v2/search/attributeOptionsByAttributeCode |
Request body
{
"token": "{{ token }}", //required
"attribute_code": "color" //required
}
Successful response
{
"data": {
"id": 38518077,
"attribute_id": 93,
"attribute_code": "color",
"default_attribute_code": "color",
"options": [
{
"id": 38518078,
"option_id": "49",
"option_label": "Black",
"option_value": "black"
},
{
"id": 38518079,
"option_id": "50",
"option_label": "Blue",
"option_value": "blue"
}
]
}
}