POST /v4/product/attributes/query
(Last updated: 02/12/2024)
Request
Method
POST
URL
https://api.medipim.be/v4/product/attributes/query
Headers
Body
filter
: one of the filters below; filters can be combined usingand
,or
¬
. (optional)sorting
: one of the sortings below. (optional; default is{"id": "ASC"}
)-
page
(optional; if none is provided all results are returned)no
: page number (zero-based)size
: one of 10, 50, 100 or 250 (defaults to 100)
Filter | Description | Parameters | Examples |
---|---|---|---|
{"id": ...} |
Matches attributes by Medipim ID. | One or more Medipim IDs | {"id": 1} or {"id": [1, 2]} |
{"code": ...} |
Matches attributes by code. | One or more attribute codes | {"code": "color"} or {"code": ["color", "galenic_shape"]} |
{"and": [...]} |
Matches attributes that match all of the given filters. | A list of filters. | {"and": [{"id": 1}, {"code": "color"}]} |
{"or": [...]} |
Matches attributes that match any of the given filters. | A list of filters. | {"or": [{"id": 1}, {"code": "color"}]} |
{"not": ...} |
Matches attributes that do not match the given filter. | A filter. | {"not": {"id": 1}} |
Sorting | Description | Parameters | Examples |
---|---|---|---|
{"id": ...} |
Sort by Medipim ID | "ASC" or "DESC" |
{"id": "ASC"} or {"id": "DESC"} |
{"name": ...} |
Sort by Name | "ASC" or "DESC" |
{"name": "ASC"} or {"name": "DESC"} |
Response
Body
-
meta
:total
: total number of attributes (integer)-
page
:no
: page number (zero-based) (integer)offset
: offset of the first item in the entire resultset (integer)size
: size of the page (integer)
-
results[]
:id
: Medipim ID of the attribute (integer, unique)code
: (unique) code of attribute (string)name.{...}
: Name of the attribute (string, localized)-
meta
:createdAt
: When the attribute was created on Medipim (unix timestamp)updatedAt
: when the attribute information was last updated (unix timestamp)
Notice
The meta page section will only be returned if you added a page in the request body.