For the complete documentation index, see llms.txt. This page is also available as Markdown.

Attributes

Administrative endpoints for product attributes — the definitions that describe what data a product can carry (its name, size, color, material, and so on) and how that data behaves in the catalog, on the storefront, and in variant grouping.

The attribute system has four related resources, each with its own endpoints:

Resource
Path
What it is

Attribute

/attributes/

A single attribute definition (e.g. color), including its data type and default behavior flags.

Attribute Value

/attribute_value/

A predefined value that an attribute can take (e.g. Red for color).

Attribute Set

/attribute_set/

A named group of attribute configurations assigned to products.

Attribute Configuration

/attribute_config/

The membership of one attribute in one attribute set, overriding the attribute's behavior for that set.

Core Capabilities

1. Attribute Definitions

  • Define attributes with a unique key, a human-readable name, and a data_type that controls how the attribute is edited and stored.

  • Control default behavior with the boolean flags described under Behavior Flags (visibility, searchability, filterability, variant handling, and form requirements).

  • List and filter attributes; only attributes that apply to products are returned.

2. Attribute Values

  • Maintain the predefined values of an attribute (for dropdown, multiple-select, and value/label attributes).

  • Order values explicitly, or let the server order numeric values automatically.

3. Attribute Sets & Configurations

  • Group attributes into named sets that are assigned to products.

  • Override an attribute's behavior for a specific set through an attribute configuration, or leave a flag unset to inherit the attribute's own value.

Data Types

The data_type of an attribute controls how its value is entered and interpreted.

Value
Description

text

Single-line text.

email

An email address.

area

Multi-line text.

date

A calendar date.

datetime

A date and time.

bool

A true/false flag.

valuelabel

A value paired with a display label.

dropdown

A single choice from the attribute's predefined values.

multiple

Multiple choices from the attribute's predefined values.

price

A monetary amount.

nested

A nested object of sub-values.

image

An image reference.

file

A file reference.

model

A reference to another model instance.

bundle

A bundle composition value.

Attribute Set Types

Value
Description

simple

A standard attribute set assigned to ordinary products. This is the default.

grouped

An attribute set used for grouped products.

Behavior Flags

Both attributes and attribute configurations carry the same set of behavior flags. On an attribute they set the default behavior; on an attribute configuration they override that behavior for one attribute set.

Flag
Meaning

is_required

The attribute must have a value on the product.

is_visible

The attribute is shown in management and storefront contexts.

is_searchable

The attribute is indexed for search.

is_filterable

The attribute can be used as a storefront filter (facet).

is_variant

The attribute distinguishes variants of the same product.

is_variant_listable

The attribute participates in choosing which variant is the listable one.

is_form_required

The attribute is required in the product form.

is_form_field_required

The attribute's form field is required.

Inheritance in Attribute Configurations

On an attribute configuration every behavior flag is nullable. A null value means inherit the value from the parent attribute; a non-null value overrides it for that attribute set. The read-only default_fields array reports exactly which flags are currently inherited (left null) rather than overridden.

Dynamic Settings & Environment Variables

The behavior of these endpoints is influenced by the following dynamic setting, configured in the management panel. It is referenced again in the description of the operations it affects.

Key
Type
Default
Effect

LANDING_PAGE_ATTRIBUTES

array of strings (attribute keys)

the server configuration value LANDING_PAGE_ATTRIBUTES, or [] when unset

The list of attribute keys for which attribute values should back a landing page. Affects create (POST /attribute_value/) and update (PUT/PATCH /attribute_value/{id}/): when the value's attribute key is in this list, a landing page is automatically created (and kept in sync on update) for the attribute value. Values of attributes not in this list are unaffected.

Environment variables: No environment variables are read directly by these endpoints. The only related server configuration value is LANDING_PAGE_ATTRIBUTES, which serves as the fallback default of the dynamic setting of the same name described above.

Last updated

Was this helpful?