Chat

Получить вложения доступного чата

Changed on

Указатель вложений беседы. Отдаются только вложения из видимой участнику части истории; для этого нужна capability скачивания файлов, а не просто чтение чата. Удалённые сообщения и вложения, снятые антивирусом, не возвращаются ни списком, ни поиском. Страница идёт от свежих к старым; следующая берётся непрозрачным cursor из next_cursor.

get/api/v1/chat/conversations/{id}/attachments

Request

  • Base URL
    https://erp.akeda.ru
  • Auth
    • HTTP bearer
    • or OAuth 2
      Authorization codehttps://erp.akeda.ru/oauth2/authorize
      Token URLhttps://erp.akeda.ru/oauth2/token
      Scopesakeda:delegate

Path parameters

id, string uuid required

Query parameters

media_kind, string
Example:image,video,video_circle

Фильтр по типу вложения. Принимает перечень через запятую: media_kind=image,video,video_circle.

q, string

Поиск по имени файла: до 16 слов и 256 знаков, регистр и е/ё не важны, синтаксис полнотекстового запроса не исполняется.

cursor, string

Непрозрачный курсор следующей страницы из next_cursor предыдущего ответа.

limit, integer

Headers

X-Tenant, string required

Slug выбранного кабинета; кабинет не является юрлицом

Response

Вложения чата

ChatAttachmentPage required
items, ChatForwardedAttachment[] required
has_more, boolean required

Следующая страница доказана прочитанной строкой за границей текущей, а не тем, что страница оказалась полной.

next_cursor, string

Курсор следующей страницы; присутствует только вместе с has_more=true.

Example response

{
  "items": [
    {
      "content_url": "/api/v1/chat/attachments/00000000-0000-0000-0000-000000000001/content"
    }
  ]
}

Changes

    • info

      added the optional property items/items/image_height to the response with the status

    • info

      added the optional property items/items/image_width to the response with the status

    • info

      added the optional property field to the response with the status

    7 more changes in this revision