Skip to content

Get Attribute Options

Retrieve all available options for a specific product attribute.

Endpoint

GET /api/shop/attributes/{attributeId}/options

Request Headers

HeaderRequiredDescription
Content-TypeYesapplication/json
X-STOREFRONT-KEYYesYour storefront API key

Path Parameters

ParameterTypeRequiredDescription
attributeIdintegerYesAttribute ID

Response Fields (200 OK)

FieldTypeDescription
idintegerOption ID
labelstringOption display label
valuestringOption value
swatchTypestringSwatch type (color, image, text)
swatchValuestringSwatch value (color code, image URL, or text)
sortOrderintegerDisplay order

Use Cases

  • Populate dropdown/select fields in product configuration
  • Display color swatches for color attributes
  • Show size options for clothing
  • Build variant selection interfaces
  • Create attribute-based product filters

Released under the MIT License.