For AI agents: markdown of this page — /docs-content-en/userfields/tasks/get.md documentation index — /llms.txt
Get field
GET /v1/userfields/tasks/:id
Returns one task user field by ID: its type, settings, labels in all languages and list options.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
Parameter:id (path) |
Typenumber | Requiredyes | DescriptionNumeric field ID from the GET /v1/userfields/tasks or POST /v1/userfields/tasks response. A positive integer |
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/userfields/tasks/6007967" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth application
curl "https://vibecode.bitrix24.com/v1/userfields/tasks/6007967" \
-H "X-Api-Key: YOUR_APP_KEY" \
-H "Authorization: Bearer USER_SESSION_TOKEN"
JavaScript — personal key
const res = await fetch('https://vibecode.bitrix24.com/v1/userfields/tasks/6007967', {
headers: { 'X-Api-Key': 'YOUR_API_KEY' },
})
const { success, data } = await res.json()
console.log(data.fieldName, data.items?.map((item) => item.value))
JavaScript — OAuth application
const res = await fetch('https://vibecode.bitrix24.com/v1/userfields/tasks/6007967', {
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
},
})
const { success, data } = await res.json()
Response fields
| Field | Type | Description |
|---|---|---|
Fieldsuccess |
Typeboolean | DescriptionAlways true on success |
Fielddata |
Typeobject | DescriptionField object |
Fielddata.id |
Typenumber | DescriptionNumeric field ID |
Fielddata.entityId |
Typestring | DescriptionEntity the field belongs to — always TASKS_TASK |
Fielddata.fieldName |
Typestring | DescriptionSystem field name in the UF_* format |
Fielddata.userTypeId |
Typestring | DescriptionField type. Values — Field types |
Fielddata.xmlId |
Typestring|null | DescriptionExternal field ID. Cannot be set through the API |
Fielddata.sort |
Typestring | DescriptionField order — a number as a string |
Fielddata.multiple |
Typestring | DescriptionMultiple values in one task: "Y" or "N" |
Fielddata.mandatory |
Typestring | DescriptionRequired field: "Y" or "N" |
Fielddata.showFilter |
Typestring | DescriptionShow in the filter. For fields created through the API — "N" |
Fielddata.showInList |
Typestring | DescriptionShow in the list. For fields created through the API — "Y" |
Fielddata.editInList |
Typestring | DescriptionAllow editing from the list. For fields created through the API — "Y" |
Fielddata.isSearchable |
Typestring | DescriptionIncluded in search. For fields created through the API — "N" |
Fielddata.settings |
Typeobject | DescriptionField settings; the set of keys depends on userTypeId. For enumeration — DISPLAY, LIST_HEIGHT, CAPTION_NO_VALUE, SHOW_NO_VALUE. For string — SIZE, ROWS, REGEXP, MIN_LENGTH, MAX_LENGTH, DEFAULT_VALUE |
Fielddata.editFormLabel |
Typeobject | DescriptionLabel in the task form per language: the key is a language code, the value is a string |
Fielddata.listColumnLabel |
Typeobject | DescriptionColumn label in the task list per language |
Fielddata.listFilterLabel |
Typeobject | DescriptionLabel in the filter per language |
Fielddata.errorMessage |
Typeobject | DescriptionValidation error message per language. For a field created through the API — the field name; for system fields the values are null |
Fielddata.helpMessage |
Typeobject | DescriptionHint per language. For a field created through the API — the field name; for system fields the values are null |
Fielddata.system |
Typeboolean | Descriptiontrue for the system fields UF_CRM_TASK, UF_TASK_WEBDAV_FILES, UF_MAIL_MESSAGE |
Fielddata.items |
Typearray | DescriptionOptions of an enumeration field. Absent for other types |
Fielddata.items[].id |
Typenumber | DescriptionOption ID. Pass it in items[].id when updating the field and as the field value in a task |
Fielddata.items[].value |
Typestring | DescriptionOption name |
Fielddata.items[].sort |
Typestring | DescriptionOption order — a number as a string |
Fielddata.items[].def |
Typestring | DescriptionDefault option: "Y" or "N" |
Fielddata.items[].xmlId |
Typestring | DescriptionExternal option ID. Generated automatically if it was not passed at creation |
Response example
The labels in the example are trimmed to two languages — en and ru. The response has more keys: one per language.
{
"success": true,
"data": {
"id": 6007967,
"entityId": "TASKS_TASK",
"fieldName": "UF_REVIEW_STAGE",
"userTypeId": "enumeration",
"xmlId": null,
"sort": "500",
"multiple": "N",
"mandatory": "Y",
"showFilter": "N",
"showInList": "Y",
"editInList": "Y",
"isSearchable": "N",
"settings": {
"DISPLAY": "LIST",
"LIST_HEIGHT": 1,
"CAPTION_NO_VALUE": "",
"SHOW_NO_VALUE": "Y"
},
"editFormLabel": {
"en": "Review stage",
"ru": "Review stage"
},
"listColumnLabel": {
"en": "Review stage",
"ru": "Review stage"
},
"listFilterLabel": {
"en": "Review stage",
"ru": "Review stage"
},
"errorMessage": {
"en": "UF_REVIEW_STAGE",
"ru": "UF_REVIEW_STAGE"
},
"helpMessage": {
"en": "UF_REVIEW_STAGE",
"ru": "UF_REVIEW_STAGE"
},
"system": false,
"items": [
{
"id": 4045,
"value": "New",
"sort": "10",
"def": "Y",
"xmlId": "new"
},
{
"id": 4047,
"value": "Under review",
"sort": "20",
"def": "N",
"xmlId": "review"
},
{
"id": 4049,
"value": "Accepted",
"sort": "30",
"def": "N",
"xmlId": "accepted"
}
]
}
}
Error response example
404 — no field with this id:
{
"success": false,
"error": {
"code": "ENTITY_NOT_FOUND",
"message": "Task custom field not found"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| HTTP400 | CodeINVALID_ID |
Description:id is not a positive integer — the request is rejected before it reaches Bitrix24 |
| HTTP404 | CodeENTITY_NOT_FOUND |
DescriptionNo field with this id exists, or it belongs to another entity, such as an employee |
| HTTP403 | CodeTASK_CUSTOM_FIELDS_UNAVAILABLE |
DescriptionThe portal plan does not include task user fields |
| HTTP403 | CodeSCOPE_DENIED |
DescriptionThe API key does not have the task scope |
| HTTP401 | CodeTOKEN_MISSING |
DescriptionThe key has no Bitrix24 tokens. For an application key, the Authorization: Bearer USER_SESSION_TOKEN header was not passed |
| HTTP401 | CodeMISSING_API_KEY |
DescriptionThe X-Api-Key header is missing |
Full list of common API errors — Errors.
Known specifics
Labels come as an object keyed by language. Reading a single field returns labels in all languages at once, while the field list returns each label as a string in the one language set by the lang parameter.
The field value is stored in the task. In GET /v1/tasks/:id the field arrives under its camelCase name: UF_REVIEW_STAGE as ufReviewStage. The value is passed under the same name in the body of POST /v1/tasks. For an enumeration field the value is the id of an option from items.