For AI agents: markdown of this page — /docs-content-en/humanresources/nodes/get.md documentation index — /llms.txt
Get node
GET /v1/humanresources/nodes/:id
Returns a single org structure node by identifier together with its member roster. A members array with the node's employees, their positions and roles is added to the response.
Parameters
| Parameter | Type | Req. | Description |
|---|---|---|---|
id (path) |
number | yes | Node identifier. List of identifiers: GET /v1/humanresources/nodes?type=DEPARTMENT |
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/humanresources/nodes/23" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth app
curl "https://vibecode.bitrix24.com/v1/humanresources/nodes/23" \
-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/humanresources/nodes/23', {
headers: {
'X-Api-Key': 'YOUR_API_KEY',
},
})
const { success, data } = await res.json()
console.log(data.name, '—', data.members.length, 'members')
JavaScript — OAuth app
const res = await fetch('https://vibecode.bitrix24.com/v1/humanresources/nodes/23', {
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
},
})
const { success, data } = await res.json()
Response fields
| Field | Type | Description |
|---|---|---|
success |
boolean | Always true on success |
data.id |
number | Node identifier |
data.name |
string | Node name |
data.type |
string | Node type: DEPARTMENT or TEAM |
data.structureId |
number | Identifier of the structure the node belongs to |
data.parentId |
number | Parent node identifier. For the root node it equals 0 |
data.description |
string | null | Node description. null if no description is set |
data.accessCode |
string | Node access code (for example, D185 for a department, SN23 for a team) |
data.userCount |
number | Number of employees in the node |
data.colorName |
string | null | Node color name. null if no color is set |
data.xmlId |
string | null | External identifier of the node. null if not set |
data.createdAt |
string | null | Creation date (ISO 8601). null for nodes created without a timestamp |
data.updatedAt |
string | null | Last update date (ISO 8601). null if there were no changes |
data.members |
array | Node member roster |
data.members[].userId |
number | Employee identifier. Card: GET /v1/humanresources/employees |
data.members[].name |
string | Employee name |
data.members[].workPosition |
string | Employee position. Empty string if no position is set |
data.members[].role |
string | Employee role in the node. For a department: MEMBER_HEAD (head), MEMBER_DEPUTY_HEAD (deputy), MEMBER_EMPLOYEE (employee). For a team, roles with the MEMBER_TEAM_ prefix |
data.members[].avatar |
string | Employee profile image URL |
data.members[].url |
string | Relative path to the employee card on the Bitrix24 account |
Response example
{
"success": true,
"data": {
"id": 23,
"name": "Sales department",
"type": "DEPARTMENT",
"structureId": 1,
"parentId": 17,
"description": "Direct sales",
"accessCode": "SN23",
"userCount": 2,
"colorName": null,
"xmlId": null,
"createdAt": null,
"updatedAt": null,
"members": [
{
"userId": 1,
"name": "John Brown",
"workPosition": "",
"role": "MEMBER_HEAD",
"avatar": "https://cdn.bitrix24.com/.../avatar.jpg",
"url": "/company/personal/user/1/"
},
{
"userId": 29,
"name": "Maria Wilson",
"workPosition": "Manager",
"role": "MEMBER_EMPLOYEE",
"avatar": "https://cdn.bitrix24.com/.../avatar.jpg",
"url": "/company/personal/user/29/"
}
]
}
}
Error response example
404 — node not found:
{
"success": false,
"error": {
"code": "ENTITY_NOT_FOUND",
"message": "Record with ID = `0` not found"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| 404 | ENTITY_NOT_FOUND |
No node with the given id. The same code is returned for a non-numeric id |
| 403 | SCOPE_DENIED |
The key lacks the humanresources scope |
| 401 | TOKEN_MISSING |
The API key has no Bitrix24 tokens configured |
The full list of common API errors — Errors.