Просмотреть список контактов
Возвращает список внешних контактов с постраничной навигацией.
Request
GET
https://api360.yandex.net/directory/v1/org/{orgId}/external_contacts
Path parameters
|
Name |
Description |
|
orgId |
Type: integer Идентификатор организации. |
Query parameters
|
Name |
Description |
|
page |
Type: integer Номер страницы ответа. Значение по умолчанию — |
|
perPage |
Type: integer Количество контактов на одной странице ответа. Значение по умолчанию — |
Responses
200 OK
Запрос успешно выполнен.
Body
application/json
{
"contacts": [
{
"id": "example",
"firstName": "example",
"lastName": "example",
"middleName": "example",
"title": "example",
"company": "example",
"department": "example",
"address": "example",
"externalId": "example",
"emails": [
{
"email": "example",
"type": "example",
"main": true
}
],
"phones": [
{
"phone": "example",
"type": "example",
"main": true
}
],
"createdAt": "2025-01-01T00:00:00Z",
"updatedAt": "2025-01-01T00:00:00Z"
}
],
"page": 0,
"pages": 0,
"perPage": 0,
"total": 0
}
|
Name |
Description |
|
contacts |
Type: v1ExternalContact[] Список внешних контактов. Example
|
|
page |
Type: integer Номер страницы ответа. |
|
pages |
Type: integer Количество страниц ответа. |
|
perPage |
Type: integer Количество результатов на одной странице ответа. |
|
total |
Type: integer Общее количество результатов. |
v1ExternalContactEmail
|
Name |
Description |
|
|
Type: string Электронный адрес. Example: |
|
main |
Type: boolean Признак основного электронного адреса:
|
|
type |
Type: string Тип электронного адреса. Возможные значения:
Example: |
Example
{
"email": "example",
"type": "example",
"main": true
}
v1ExternalContactPhone
|
Name |
Description |
|
main |
Type: boolean Признак основного телефона:
|
|
phone |
Type: string Телефон. Example: |
|
type |
Type: string Тип телефона. Возможные значения:
Example: |
Example
{
"phone": "example",
"type": "example",
"main": true
}
v1ExternalContact
|
Name |
Description |
|
emails |
Type: v1ExternalContactEmail[] Электронные адреса. Example
|
|
firstName |
Type: string Имя. Example: |
|
id |
Type: string Идентификатор внешнего контакта. Example: |
|
lastName |
Type: string Фамилия. Example: |
|
address |
Type: string Почтовый адрес. Example: |
|
company |
Type: string Компания. Example: |
|
createdAt |
Type: string<date-time> Дата и время создания. Example: |
|
department |
Type: string Подразделение. Example: |
|
externalId |
Type: string Произвольный внешний идентификатор. Example: |
|
middleName |
Type: string Отчество. Example: |
|
phones |
Type: v1ExternalContactPhone[] Телефоны. Example
|
|
title |
Type: string Должность. Example: |
|
updatedAt |
Type: string<date-time> Дата и время изменения. Example: |
Example
{
"id": "example",
"firstName": "example",
"lastName": "example",
"middleName": "example",
"title": "example",
"company": "example",
"department": "example",
"address": "example",
"externalId": "example",
"emails": [
{
"email": "example",
"type": "example",
"main": true
}
],
"phones": [
{
"phone": "example",
"type": "example",
"main": true
}
],
"createdAt": "2025-01-01T00:00:00Z",
"updatedAt": "2025-01-01T00:00:00Z"
}
400 Bad Request
Некорректный запрос.
Body
application/json
{
"code": 0,
"message": "example",
"details": [
{
"@type": "example"
}
]
}
|
Name |
Description |
|
code |
Type: integer Код ошибки. |
|
details |
Type: protobufAny[] Дополнительные сведения об ошибке. Example
|
|
message |
Type: string Описание ошибки. Example: |
protobufAny
|
Name |
Description |
|
@type |
Type: string Example: |
|
[additional] |
Type: unknown Example: |
Example
{
"@type": "example"
}
401 Unauthorized
Пользователь не авторизован.
Body
application/json
{
"code": 0,
"message": "example",
"details": [
{
"@type": "example"
}
]
}
|
Name |
Description |
|
code |
Type: integer Код ошибки. |
|
details |
Type: protobufAny[] Дополнительные сведения об ошибке. Example
|
|
message |
Type: string Описание ошибки. Example: |
403 Forbidden
У пользователя или приложения нет прав на доступ к ресурсу, запрос отклонен.
Body
application/json
{
"code": 0,
"message": "example",
"details": [
{
"@type": "example"
}
]
}
|
Name |
Description |
|
code |
Type: integer Код ошибки. |
|
details |
Type: protobufAny[] Дополнительные сведения об ошибке. Example
|
|
message |
Type: string Описание ошибки. Example: |
404 Not Found
Запрашиваемый ресурс не найден.
Body
application/json
{
"code": 0,
"message": "example",
"details": [
{
"@type": "example"
}
]
}
|
Name |
Description |
|
code |
Type: integer Код ошибки. |
|
details |
Type: protobufAny[] Дополнительные сведения об ошибке. Example
|
|
message |
Type: string Описание ошибки. Example: |
500 Internal Server Error
Внутренняя ошибка сервиса. Попробуйте повторно отправить запрос через некоторое время.
Body
application/json
{
"code": 0,
"message": "example",
"details": [
{
"@type": "example"
}
]
}
|
Name |
Description |
|
code |
Type: integer Код ошибки. |
|
details |
Type: protobufAny[] Дополнительные сведения об ошибке. Example
|
|
message |
Type: string Описание ошибки. Example: |
No longer supported, please use an alternative and newer version.