support
POST /v1/tickets/{ticketId}/messages/{messageId}/attachments
Attach a file to a ticket message.
Autentikasi
Kirim kunci API sebagai token bearer. Kunci tersebut harus memiliki izin tickets.reply; kunci tanpa izin tersebut akan ditolak dengan status 403, bukan 404.
Endpoint ini tidak memerlukan id organisasi. Kunci Anda telah mengidentifikasi organisasi tempatnya berafiliasi, dan respons akan dibatasi untuk organisasi tersebut.
Coba
Ganti apa pun di dalam tanda kurung sudut dengan nilai Anda sendiri, dan placeholder kunci dengan kunci dari dasbor Anda.
curl -X POST https://api.zinndigital.com/v1/tickets/{ticketId}/messages/{messageId}/attachments \
-H "Authorization: Bearer zdk_live_…"Sudah masuk? Konsol API di dasbor Anda akan mengisi ID organisasi asli dan kunci Anda sendiri, serta menjalankan permintaan terhadap API langsung sehingga Anda dapat melihat respons aktualnya. Buka titik akhir ini di konsol API
Detail
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`.
Parameter
| Nama | Jenis | Wajib | Tentang apa ini |
|---|---|---|---|
ticketId (path) | Uuid | Ya | The ticket's id. |
messageId (path) | Uuid | Ya | The message the file belongs to. |
Tanggapan
| Nama | Jenis | Wajib | Tentang apa ini |
|---|---|---|---|
id | Uuid | Ya | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
filename | string | Ya | 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_type | string | Ya | — |
size_bytes | integer | Ya | — |
scan_state | string<pending, clean, infected, error> | Ya | `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… |
downloadable | boolean | Ya | Whether these bytes may be served. True only for `clean`. |
Kesalahan yang dapat dikembalikan oleh titik akhir ini
401 · 403 · 404 · 422 · 429