[{"data":1,"prerenderedAt":7},["ShallowReactive",2],{"docs-userfields\u002Fusers\u002Fupdate":3,"docs-tabs-userfields\u002Fusers\u002Fupdate":6},{"content":4,"lastmod":5},"## Update employee field\n\n`PATCH \u002Fv1\u002Fuserfields\u002Fusers\u002F:id`\n\nUpdates the properties of an existing employee user field. The field type `userTypeId` and the `multiple` flag cannot be changed — to change the type, delete the field and create a new one. Pass only the properties you want to change.\n\n## Parameters\n\n| Parameter | Type | Required | Description |\n|----------|-----|:-----:|---------|\n| `:id` (path) | number | yes | Numeric identifier of the field (from the response of [`GET \u002Fv1\u002Fuserfields\u002Fusers`](\u002Fdocs\u002Fuserfields\u002Fusers\u002Flist) or [`POST \u002Fv1\u002Fuserfields\u002Fusers`](\u002Fdocs\u002Fuserfields\u002Fusers\u002Fcreate)) |\n\n## Request fields (body)\n\n| Field | Type | Description |\n|------|-----|---------|\n| `label` | string | Field label. Substituted into `editFormLabel`, `listColumnLabel` and `listFilterLabel` when they are not passed explicitly. Responses in this section do not return labels — [Field labels](\u002Fdocs\u002Fuserfields\u002Fusers#field-labels) |\n| `editFormLabel` | object | Label in the edit form, keyed by Bitrix24 account language. Example: `{ \"ru\": \"Badge number\", \"en\": \"Badge number\" }`. This is the label returned in the employee schema as `label` |\n| `sort` | string | Sort order in the Bitrix24 interface |\n| `showFilter` | boolean | Show in the filter: `true` or `\"Y\"` — yes, `false` or `\"N\"` — no. The `\"E\"` you read can be sent back as is — the platform treats it as \"on\" |\n| `xmlId` | string | External identifier for integrations |\n| `settings` | object | Type-specific field settings. The structure depends on `userTypeId` — [Get employee field](\u002Fdocs\u002Fuserfields\u002Fusers\u002Fget) |\n| `list` | array | Options of an `enumeration` field. An item without `ID` is added as a new option; an item with `ID` and a new `VALUE` renames an existing one; an item `{ \"ID\": 3967, \"DEL\": \"Y\" }` deletes the option. Options not mentioned in the array remain unchanged |\n| `mandatory`, `isSearchable`, `showInList`, `editInList`, `multiple` | boolean | Accepted, but not applied to an employee field on update — [Which properties are applied](\u002Fdocs\u002Fuserfields\u002Fusers#which-properties-are-applied) |\n\nRead-only properties — `id`, `entityId`, `fieldName`, `userTypeId` — are ignored when passed: the field identifier is taken only from the path.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X PATCH \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fuserfields\u002Fusers\u002F6007923\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n    \"sort\": \"300\",\n    \"list\": [\n      { \"VALUE\": \"24-hour\", \"SORT\": 40 }\n    ]\n  }'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X PATCH \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fuserfields\u002Fusers\u002F6007923\" \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n    \"sort\": \"300\",\n    \"list\": [\n      { \"VALUE\": \"24-hour\", \"SORT\": 40 }\n    ]\n  }'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fuserfields\u002Fusers\u002F6007923', {\n  method: 'PATCH',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    sort: '300',\n    list: [\n      { VALUE: '24-hour', SORT: 40 },\n    ],\n  }),\n})\n\nconst { success, data } = await res.json()\nconsole.log('Updated:', data.updated)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fuserfields\u002Fusers\u002F6007923', {\n  method: 'PATCH',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    sort: '300',\n    list: [\n      { VALUE: '24-hour', SORT: 40 },\n    ],\n  }),\n})\n\nconst { success, data } = await res.json()\n```\n\n## Response fields\n\n| Field | Type | Description |\n|------|-----|---------|\n| `success` | boolean | Always `true` on success |\n| `data` | object | Update result |\n| `data.updated` | boolean | `true` on successful update |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"updated\": true\n  }\n}\n```\n\n## Error response example\n\n404 — there is no field with this `id`:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"ENTITY_NOT_FOUND\",\n    \"message\": \"User field 999999999 not found\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|---------|\n| 400 | `INVALID_ID` | `:id` is not a positive integer — the request is rejected before the portal is contacted |\n| 400 | `INVALID_REQUEST` | The request body is not an object |\n| 404 | `ENTITY_NOT_FOUND` | There is no field with this `id`. Existence is checked before the update, so no change reaches the portal |\n| 422 | `BITRIX_ERROR` | The key owner is not a Bitrix24 account administrator — Bitrix24 responds with the message `Access denied.` |\n| 422 | `BITRIX_ERROR` | Other Bitrix24 rejections — including a field removed between the existence check and the update itself. The text is returned verbatim in `error.message` |\n| 403 | `SCOPE_DENIED` | The API key does not have the `user.userfield` scope |\n| 401 | `TOKEN_MISSING` | The API key has no configured tokens |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n**The response does not confirm that properties were applied.** `updated: true` means that Bitrix24 accepted the request, not that every passed property changed: the properties the [Which properties are applied](\u002Fdocs\u002Fuserfields\u002Fusers#which-properties-are-applied) table marks as not applied keep their previous values even when the response is successful. After an update, re-read the field — [`GET \u002Fv1\u002Fuserfields\u002Fusers\u002F:id`](\u002Fdocs\u002Fuserfields\u002Fusers\u002Fget).\n\n**`enumeration` options are edited individually.** The `list` array does not replace the option set as a whole: options not mentioned in it are kept. The `ID`s of existing options are taken from the response of [`GET \u002Fv1\u002Fuserfields\u002Fusers\u002F:id`](\u002Fdocs\u002Fuserfields\u002Fusers\u002Fget). In the example above a fourth option — \"24-hour\" — is added to the field's three options.\n\n## See also\n\n- [Get employee field](\u002Fdocs\u002Fuserfields\u002Fusers\u002Fget)\n- [Create employee field](\u002Fdocs\u002Fuserfields\u002Fusers\u002Fcreate)\n- [Delete employee field](\u002Fdocs\u002Fuserfields\u002Fusers\u002Fdelete)\n- [Employee fields](\u002Fdocs\u002Fuserfields\u002Fusers)\n- [User fields](\u002Fdocs\u002Fuserfields)\n","2026-10-16",{},1794739618293]