younifyd
Menu

Get Reference Entity Attribute By Code

Get an attribute of a given reference entity

GET/api/rest/v1/reference-entities/{reference_entity_code}/attributes/{code}

Use it in a workflow

  1. Add a step and choose the Akeneo connector.
  2. Pick the Get Reference Entity Attribute By Code action (under Reference entity attribute).
  3. Fill in the fields below, then reference the result from later steps as {{getReferenceEntityAttributeByCode.response.data}}.

Request

Path parameters

reference_entity_codestringrequired

This path parameter is used to specify the unique identifier of the reference entity you want to retrieve or manipulate. It is essential for identifying the specific reference entity in the API requests. Ensure that the reference entity code is correctly formatted and corresponds to an existing reference entity in the system.

codestringrequired

This path parameter is used to specify the unique identifier of the entity you want to retrieve or manipulate. It is essential for identifying the specific entity in the API requests. Ensure that the code is correctly formatted and corresponds to an existing entity in the system.

Response

Returns 200 with an object. Read it in later steps with {{getReferenceEntityAttributeByCode.response.data.<field>}}.

codestring

Attribute code

labelsobject

Attribute labels per locale

Default {}

typestring

Attribute type. See [type](https://api.akeneo.com/concepts/reference-entities.html#reference-entity-attribute) section for more details.

One oftextimagenumbersingle_optionmultiple_optionsreference_entity_single_linkreference_entity_multiple_linksasset_collection

value_per_localeboolean

Whether the attribute is localizable, i.e. can have one value by locale

Default false

value_per_channelboolean

Whether the attribute is scopable, i.e. can have one value by channel

Default false

is_required_for_completenessboolean

Whether the attribute should be part of the record's completeness calculation

Default false

max_charactersinteger | null

Maximum number of characters allowed for the value of the attribute when the attribute type is `text`

is_textareaboolean

Whether the UI should display a text area instead of a simple field when the attribute type is `text`

Default false

is_rich_text_editorboolean

Whether the UI should display a rich text editor instead of a simple text area when the attribute type is `text`

Default false

validation_rulestring | null

Validation rule type used to validate the attribute value when the attribute type is `text`

One ofemailurlregular_expressionnonenullDefault "none"

validation_regexpstring | null

Regexp expression used to validate the attribute value when the attribute type is `text`

allowed_extensionsarray<string>

Extensions allowed when the attribute type is `image`

Default []

max_file_sizestring | null

Max file size in MB when the attribute type is `image`

reference_entity_codestring | null

Code of the linked reference entity when the attribute type is `reference_entity_single_link` or `reference_entity_multiple_links`

asset_family_identifierstring | null

Code of the linked asset family when the attribute type is `asset_collection`

decimals_allowedboolean

Whether decimals are allowed when the attribute type is `number`

Default false

min_valuestring | null

Minimum value allowed when the attribute type is `number`

max_valuestring | null

Maximum value allowed when the attribute type is `number`

json
{
  "code": "description",
  "type": "text",
  "labels": {
    "en_US": "The description",
    "fr_FR": "La description"
  },
  "value_per_locale": true,
  "value_per_channel": false,
  "is_required_for_completeness": true,
  "max_characters": 255,
  "is_textarea": true,
  "is_rich_text_editor": true,
  "validation_rule": "none",
  "validation_regexp": null,
  "allowed_extensions": [
    "png",
    "jpg"
  ]
}

Need more? See the Akeneo guide for connection setup and behaviour shared by every action.