For AI agents: markdown of this page — /docs-content-en/entities/crm-field-enum/list.md documentation index — /llms.txt
List enumeration field values
GET /v1/userfields/:entity/enum-values
Lists the options of one CRM enumeration field so you can use their IDs when setting record values.
This feature is rolling out. It requires a CRM update after
26.2200.0and activation by an administrator. The release version has not been published. Until available, requests return422 METHOD_NOT_YET_AVAILABLEwitherror.release.
For Smart Process Automation (SPA) fields, use the same contract at GET /v1/items/:entityTypeId/userfields/enum-values. Invoices are also available through entityTypeId=31.
Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
Parameterentity (path) |
Typestring | Requiredyes | Default— | Descriptiondeals — deals, leads — leads, contacts — contacts, companies — companies, quotes — estimates, invoices — invoices |
ParameterentityTypeId (path) |
Typeinteger | Requiredfor the alternate path | Default— | DescriptionSPA type ID, or 31 for invoices |
ParameterfieldId (query) |
Typeinteger / string | Requiredyes | Default— | DescriptionID or UF_* code of an enumeration field. Sources: CRM fields, SPA fields |
Parameterlimit (query) |
Typeinteger | Requiredno | Default50 |
DescriptionPositive page size, up to 1000 |
Parameteroffset (query) |
Typeinteger | Requiredno | Default0 |
DescriptionNonnegative offset from the start of the list |
Pagination: increase offset by limit until a partial or empty page is returned. No total count is calculated. Other query parameters are not accepted.
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/userfields/deals/enum-values?fieldId=6008145" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth application
curl "https://vibecode.bitrix24.com/v1/userfields/deals/enum-values?fieldId=6008145" \
-H "X-Api-Key: YOUR_APP_KEY" \
-H "Authorization: Bearer USER_SESSION_TOKEN"
JavaScript — personal key
const response = await fetch(
'https://vibecode.bitrix24.com/v1/userfields/deals/enum-values?fieldId=6008145',
{
"method": "GET",
"headers": {
"X-Api-Key": "YOUR_API_KEY"
}
}
)
const { success, data, meta } = await response.json()
JavaScript — OAuth application
const response = await fetch(
'https://vibecode.bitrix24.com/v1/userfields/deals/enum-values?fieldId=6008145',
{
"method": "GET",
"headers": {
"X-Api-Key": "YOUR_APP_KEY",
"Authorization": "Bearer USER_SESSION_TOKEN"
}
}
)
const { success, data, meta } = await response.json()
Response fields
HTTP 200 OK.
| Field | Type | Description |
|---|---|---|
Fieldsuccess |
Typeboolean | Descriptiontrue on success |
Fielddata |
Typearray | DescriptionField options |
Fielddata[].id |
Typeinteger | DescriptionOption ID for retrieval |
Fielddata[].fieldId |
Typeinteger | DescriptionField ID. See CRM fields and SPA fields |
Fielddata[].value |
Typestring | DescriptionOption label |
Fielddata[].isDefault |
Typeboolean | DescriptionUsed as a default option |
Fielddata[].sort |
Typeinteger | DescriptionSort order |
Fielddata[].xmlId |
Typestring / null | DescriptionExternal integration ID |
Fieldmeta.limit |
Typeinteger | DescriptionRequested page size |
Fieldmeta.offset |
Typeinteger | DescriptionPage offset |
Response example
{
"success": true,
"data": [
{
"id": 4119,
"fieldId": 6008145,
"value": "VIBE-PROBE option",
"isDefault": false,
"sort": 500,
"xmlId": "VIBE-PROBE-X"
}
],
"meta": {
"limit": 50,
"offset": 0
}
}
Error response example
400 — invalid request:
{
"success": false,
"error": {
"code": "MISSING_REQUIRED_PARAMS",
"message": "fieldId must name a field by positive ID or UF code"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| HTTP400 | CodeINVALID_PARAMS |
DescriptionInvalid request shape or parameter type |
| HTTP400 | CodeUNKNOWN_FILTER_FIELD |
DescriptionUnknown or repeated query parameter |
| HTTP400 | CodeMISSING_REQUIRED_PARAMS |
DescriptionA valid fieldId is missing |
| HTTP422 | CodeMETHOD_NOT_YET_AVAILABLE |
DescriptionThe feature is not yet available. Update information is provided in error.release |
| HTTP502 | CodeBITRIX_UNAVAILABLE |
DescriptionInvalid response from Bitrix24 |
| HTTP401 | CodeMISSING_API_KEY |
DescriptionMissing X-Api-Key |
| HTTP401 | CodeTOKEN_MISSING |
DescriptionNo Bitrix24 tokens are configured |
| HTTP403 | CodeSCOPE_DENIED |
DescriptionThe key requires the crm scope |
For shared API errors, see Errors.