support

POST /v1/tickets/{ticketId}/messages/{messageId}/attachments

Attach a file to a ticket message.

Все эндпоинты support

Аутентификация

Отправьте ключ API в качестве токена носителя (bearer token). Ключ должен иметь разрешение tickets.reply; ключ без него отклоняется с кодом 403, а не 404.

Этот эндпоинт не принимает идентификатор организации. Ваш ключ уже определяет организацию, к которой он принадлежит, и ответ ограничивается ее рамками.

Попробовать

Замените всё в угловых скобках на собственные значения, а плейсхолдер ключа — на ключ из вашей панели управления.

curl -X POST https://api.zinndigital.com/v1/tickets/{ticketId}/messages/{messageId}/attachments \
  -H "Authorization: Bearer zdk_live_…"

Вошли в систему? Консоль API в вашей панели управления автоматически подставляет реальный идентификатор вашей организации и ваш собственный ключ, а также выполняет запрос к работающему API, чтобы вы могли увидеть актуальный ответ. Откройте эту конечную точку в API-консоли

Подробнее

Uploads one file and records it against the message. The file is accepted immediately and is **not downloadable by anyone — including staff — until a malware scan has passed** (`scan_state: clean`). ⛔ Only the types on the allow-list are accepted, and the declared content type is verified against the file's own leading bytes: a `.png` beginning `MZ` is refused whatever the header says. Maximum 25 MB. Requires `tickets.reply`.

Параметры

ИмяТипОбязательноЧто это
ticketId (path)UuidДаThe ticket's id.
messageId (path)UuidДаThe message the file belongs to.

Ответ

ИмяТипОбязательноЧто это
idUuidДаUUIDv7 identifier — sortable by creation time (docs/02 §8).
filenamestringДаThe name the uploader's machine gave it. ⛔ Display only — it is attacker-controlled text and is never used to build a storage path.
content_typestringДа
size_bytesintegerДа
scan_statestring<pending, clean, infected, error>Да`pending` — uploaded, not yet scanned. `clean` — the only servable state. `infected` — the scanner found something; the row survives as evidence and the bytes never leave. `erro…
downloadablebooleanДаWhether these bytes may be served. True only for `clean`.

Ошибки, которые может возвращать этот эндпоинт

401 · 403 · 404 · 422 · 429