For AI agents: markdown of this page — /docs-content-en/entities/catalog-product-property-enums/search.md documentation index — /llms.txt

Search values

POST /v1/catalog-product-property-enums/search

Searches the options of a list property by conditions passed in the request body.

Unlike GET /v1/catalog-product-property-enums, the filter, select, sort, limit, and offset parameters are passed in the JSON body rather than in the query string — which is more convenient for conditions across several fields. The filter requirement is the same: the propertyId key is required. The response format matches the list.

Request fields (body)

Parameter Type Required Default Description
Parameterfilter.propertyId Typenumber Requiredyes Default— DescriptionIdentifier of the owning property from GET /v1/catalog-product-properties. Without it the request is rejected with 400 MISSING_REQUIRED_FILTER before Bitrix24 is called
Parameterfilter Typeobject Requiredno Default— DescriptionOther filtering conditions.
Filtering syntax. Example: { "propertyId": 166, "def": true }
Parameterselect Typestring[] Requiredno Default— DescriptionField selection: ["id", "value"]. Without select, all element fields are returned
Parametersort Typestring Requiredno Default— DescriptionSort field. The - prefix means descending: "-sort"
Parameterlimit Typenumber Requiredno Default50 DescriptionNumber of records (up to 5000)
Parameteroffset Typenumber Requiredno Default0 DescriptionOffset from the start of the selection

As in the list, the end of the selection is signalled by meta.hasMore — Bitrix24 reports the total, so meta.total and meta.hasMore are trustworthy.

Examples

curl — personal key

Terminal
curl -X POST "https://vibecode.bitrix24.com/v1/catalog-product-property-enums/search" \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "filter": { "propertyId": 166 },
    "sort": "sort",
    "limit": 1000
  }'

curl — OAuth application

Terminal
curl -X POST "https://vibecode.bitrix24.com/v1/catalog-product-property-enums/search" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "filter": { "propertyId": 166 },
    "sort": "sort",
    "limit": 1000
  }'

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/catalog-product-property-enums/search', {
  method: 'POST',
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    filter: { propertyId: 166 },
    sort: 'sort',
    limit: 1000,
  }),
})

const { success, data, meta } = await res.json()
console.log(`Options: ${meta.total}`)

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/catalog-product-property-enums/search', {
  method: 'POST',
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    filter: { propertyId: 166 },
    sort: 'sort',
    limit: 1000,
  }),
})

const { success, data, meta } = await res.json()

Response fields

Field Type Description
Fieldsuccess Typeboolean DescriptionAlways true on success
Fielddata Typearray DescriptionArray of options. The element field set — see Value fields
Fieldmeta.total Typenumber DescriptionHow many records matched the filter. When Bitrix24 does not report it, the window length is returned
Fieldmeta.hasMore Typeboolean DescriptionWhether more records exist beyond limit. Unreliable at the window edge — see the warning above
Fieldmeta.durationMs Typenumber DescriptionRequest duration in milliseconds

The meta fields sit next to data, not inside it.

A property that is not of the list type (propertyType other than L) has no enumeration: the request returns 200 with an empty data, not an error. Access is restricted by the employee's permissions in Bitrix24.

Response example

JSON
{
  "success": true,
  "data": [
    { "id": 110, "propertyId": 166, "value": "XS", "def": false, "sort": 100, "xmlId": null },
    { "id": 112, "propertyId": 166, "value": "S",  "def": false, "sort": 200, "xmlId": null },
    { "id": 114, "propertyId": 166, "value": "M",  "def": false, "sort": 300, "xmlId": null },
    { "id": 116, "propertyId": 166, "value": "L",  "def": false, "sort": 400, "xmlId": null },
    { "id": 118, "propertyId": 166, "value": "XL", "def": false, "sort": 500, "xmlId": null }
  ],
  "meta": {
    "total": 5,
    "hasMore": false,
    "durationMs": 148
  }
}

Error response example

400 — the required filter is missing:

JSON
{
  "success": false,
  "error": {
    "code": "MISSING_REQUIRED_FILTER",
    "message": "POST /v1/catalog-product-property-enums/search requires filter fields: propertyId. Example body: { \"filter\": {\"propertyId\":\"...\"} }"
  }
}

Errors

HTTP Code Description
HTTP400 CodeMISSING_REQUIRED_FILTER DescriptionThe body carries no filter.propertyId key. Bitrix24 is not called
HTTP400 CodeUNKNOWN_FILTER_FIELD DescriptionFiltering by a field the enumeration element does not have. The message lists the available fields
HTTP400 CodeUNKNOWN_SORT_FIELD DescriptionSorting by a field the enumeration element does not have. The message lists the available fields
HTTP403 CodeSCOPE_DENIED DescriptionThe API key does not carry the catalog scope
HTTP401 CodeMISSING_API_KEY DescriptionThe X-Api-Key header was not sent
HTTP429 CodeRATE_LIMITED DescriptionRate limit exceeded: 300 requests per minute per portal, all API keys of the portal share one limit. The exact value arrives in the x-ratelimit-limit header (the cap is divided across replicas). Retry after the delay in the Retry-After header

Full list of common API errors — Errors.

See also