Перейти к основному содержимому

Получить пользователя по ID

GET /users/:user_id/​


URL​

https://домен_системы/api/v2/users/123/


Параметры​

PATH-параметры​

ПараметрТипОбязательныйОписание
user_idчислоДаID пользователя

Ответы​

Пример ответа
{
"data": [
{
"id": 123,
"date_created": "2025-01-04 23:54:43",
"date_updated": "2025-01-09 16:00:36",
"name": " user test",
"lastname": "",
"alias": "",
"email": "user@test.com",
"phone": "1234567",
"skype": "",
"website": "",
"organization": {
"id": "1",
"name": "ООО Радуга",
"domains": "",
"address": "",
"phone": "",
"email": "test@mail.ru",
"web": "test.com"
},
"status": "active",
"language": "ru",
"notifications": "1",
"group": {
"id": 45,
"type": "user",
"name": {
"ru": "Клиент",
"en": "Client"
},
"disable": 0
},
"ldap_username": null,
"user_status": "offline",
"department": [
1
],
"custom_fields": [
{
"id": 37,
"field_type": "text",
"field_value": "Значение текстового поля"
}
]
}
]
}
Примеры ошибок
{
"errors": [
{
"code": "e-401",
"title": "Authorization error",
"details": "Username or api key is incorrect"
}
]
}

{
"errors": [
{
"code": "e-404",
"title": "Not found",
"details": "User with id {99999999} does not exist"
}
]
}