Просмотреть список участников группы
Возвращает список участников группы, таких как сотрудники, подразделения или другие группы.
Требуется разрешение на чтение данных групп.
Request
GET
https://cloud-api.yandex.net/v1/api360/directory/org/{org_id}/groups/{group_id}/members
Path parameters
|
Name |
Description |
|
group_id |
Type: string Идентификатор группы. Example: `` |
|
org_id |
Type: string Идентификатор организации. Example: `` |
Responses
200 OK
Успешный ответ.
Body
application/json
{
"departments": [
{
"id": 0,
"name": "example",
"defaultEmail": "example"
}
],
"groups": [
{
"id": 0,
"name": "example",
"defaultEmail": "example",
"membersCount": 0
}
],
"users": [
{
"avatarId": "example",
"departmentId": 0,
"email": "example",
"defaultEmail": "example",
"gender": "example",
"id": "example",
"name": {
"first": "example",
"middle": "example",
"last": "example"
},
"nickname": "example",
"position": "example"
}
]
}
|
Name |
Description |
|
departments |
Type: Departments Подразделения. Example
|
|
groups |
Type: Groups Группы. Example
|
|
users |
Type: Users Сотрудники. Example
|
DepartmentItem
Краткая информация о подразделении.
|
Name |
Description |
|
defaultEmail |
Type: string Адрес, используемый по умолчанию. Example: |
|
id |
Type: integer Идентификатор подразделения. |
|
name |
Type: string Название подразделения. Example: |
Example
{
"id": 0,
"name": "example",
"defaultEmail": "example"
}
Departments
Подразделения.
Type: DepartmentItem[]
Example
[
{
"id": 0,
"name": "example",
"defaultEmail": "example"
}
]
GroupItem
Краткая информация о группе.
|
Name |
Description |
|
defaultEmail |
Type: string Адрес, используемый по умолчанию. Example: |
|
id |
Type: integer Идентификатор группы. |
|
membersCount |
Type: integer Количество участников группы. |
|
name |
Type: string Название группы. Example: |
Example
{
"id": 0,
"name": "example",
"defaultEmail": "example",
"membersCount": 0
}
Groups
Группы.
Type: GroupItem[]
Example
[
{
"id": 0,
"name": "example",
"defaultEmail": "example",
"membersCount": 0
}
]
Name
ФИО сотрудника.
|
Name |
Description |
|
first |
Type: string Имя сотрудника. Example: |
|
last |
Type: string Фамилия сотрудника. Example: |
|
middle |
Type: string Отчество сотрудника. Example: |
Example
{
"first": "example",
"middle": "example",
"last": "example"
}
UserItem
Краткая информация о пользователе.
|
Name |
Description |
|
avatarId |
Type: string Идентификатор аватара сотрудника. Example: |
|
defaultEmail |
Type: string Адрес, используемый по умолчанию для отправки писем и отображения в контактах. Example: |
|
departmentId |
Type: integer Идентификатор подразделения, в котором состоит сотрудник. |
|
|
Type: string Адрес электронной почты пользователя. Example: |
|
gender |
Type: string Пол сотрудника. Example: |
|
id |
Type: string Идентификатор пользователя. Example: |
|
name |
Type: Name ФИО сотрудника. Example
|
|
nickname |
Type: string Логин пользователя. Example: |
|
position |
Type: string Должность сотрудника. Example: |
Example
{
"avatarId": "example",
"departmentId": 0,
"email": "example",
"defaultEmail": "example",
"gender": "example",
"id": "example",
"name": {
"first": "example",
"middle": "example",
"last": "example"
},
"nickname": "example",
"position": "example"
}
Users
Сотрудники.
Type: UserItem[]
Example
[
{
"avatarId": "example",
"departmentId": 0,
"email": "example",
"defaultEmail": "example",
"gender": "example",
"id": "example",
"name": {
"first": "example",
"middle": "example",
"last": "example"
},
"nickname": "example",
"position": "example"
}
]
400 Bad Request
Неверные параметры запроса
Body
application/json
{
"error": "invalid_argument",
"description": "Неверные параметры запроса",
"message": "Неверные параметры запроса",
"details": {}
}
|
Name |
Description |
|
description |
Type: string Техническое описание ошибки. Example: |
|
error |
Type: string Код ошибки Example: |
|
message |
Type: string Сообщение об ошибке. Example: |
|
details |
Type: objectДополнительные детали ошибки Example
|
403 Forbidden
Доступ запрещен
Body
application/json
{
"error": "permission_denied",
"description": "Доступ запрещен",
"message": "Доступ запрещен",
"details": {}
}
|
Name |
Description |
|
description |
Type: string Техническое описание ошибки. Example: |
|
error |
Type: string Код ошибки Example: |
|
message |
Type: string Сообщение об ошибке. Example: |
|
details |
Type: objectДополнительные детали ошибки Example
|
404 Not Found
Ресурс не найден
Body
application/json
{
"error": "not_found",
"description": "Ресурс не найден",
"message": "Ресурс не найден",
"details": {}
}
|
Name |
Description |
|
description |
Type: string Техническое описание ошибки. Example: |
|
error |
Type: string Код ошибки Example: |
|
message |
Type: string Сообщение об ошибке. Example: |
|
details |
Type: objectДополнительные детали ошибки Example
|
409 Conflict
Конфликт - ресурс уже существует
Body
application/json
{
"error": "already_exists",
"description": "Конфликт - ресурс уже существует",
"message": "Конфликт - ресурс уже существует",
"details": {}
}
|
Name |
Description |
|
description |
Type: string Техническое описание ошибки. Example: |
|
error |
Type: string Код ошибки Example: |
|
message |
Type: string Сообщение об ошибке. Example: |
|
details |
Type: objectДополнительные детали ошибки Example
|
412 Precondition Failed
Функция недоступна или не оплачена
Body
application/json
{
"error": "failed_precondition",
"description": "Функция недоступна или не оплачена",
"message": "Функция недоступна или не оплачена",
"details": {}
}
|
Name |
Description |
|
description |
Type: string Техническое описание ошибки. Example: |
|
error |
Type: string Код ошибки Example: |
|
message |
Type: string Сообщение об ошибке. Example: |
|
details |
Type: objectДополнительные детали ошибки Example
|
429 Too Many Requests
Превышен лимит запросов
Body
application/json
{
"error": "resource_exhausted",
"description": "Превышен лимит запросов",
"message": "Превышен лимит запросов",
"details": {}
}
|
Name |
Description |
|
description |
Type: string Техническое описание ошибки. Example: |
|
error |
Type: string Код ошибки Example: |
|
message |
Type: string Сообщение об ошибке. Example: |
|
details |
Type: objectДополнительные детали ошибки Example
|