Query attribute definitions ids

/pim/attribute-definitions/query Gets attribute definition ids by allowed criteria.

Allows to get attribute definitions ids by:

  1. By type

Table 1. Details

Resource path

/api/core/v1/pim/attribute-definitions/query

HTTP method

POST

Request content type

application/json;

Response content type

application/json;

Body parameters
Return Type

Filled with attribute definitions ids AttributeDefinitionsRequest

Responses
Table 2. Http response codes
Code Message Datatype

200

Found attribute definitions ids

AttributeDefinitionsRequest

400

Invalid input error ResponseType

ResponseType

401

Not authorized

ResponseType

500

Error in ResponseType

ResponseType

Samples
To get a list of attribute definitions ids by types
curl
curl --location 'http://<OMN_SERVER>/api/core/v1/pim/attribute-definitions/query' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data '{
    "types": ["text", "date", "number", "boolean", "ref", "table"]
} '
Request body
{
    "types": ["text", "date", "number", "boolean", "ref", "table"]
}
Response body
{
    "ids": [
        15210,
        15211,
        15212,
        15213,
        15214,
        15215,
        15216,
        15217,
        15218,
        15219,
        15310,
        15311,
        15313,
        15314,
        15315,
        15316,
        15317,
        15318,
        30160,
        30161
    ],
    "all": false
}
List of types is empty
curl
curl --location 'http://<OMN_SERVER>/api/core/v1/pim/attribute-definitions/query' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data '{
    "types": []
} '
Request body
{
    "types": []
}
Response body
{
    "all": false
}

Welcome to the AI Chat!

Write a prompt to get started...