support
POST /v1/tickets/{ticketId}/messages/{messageId}/attachments
Attach a file to a ticket message.
Authentification
Envoyez une clé API en tant que jeton du porteur. La clé doit posséder l'autorisation tickets.reply ; une clé qui ne l'a pas est refusée avec le code 403, et non 404.
Cet endpoint ne prend aucun identifiant d'organisation. Votre clé identifie déjà l'organisation à laquelle elle appartient, et la réponse y est limitée.
Essayer
Remplacez tout ce qui se trouve entre crochets par vos propres valeurs, et le espace réservé à la clé par une clé de votre tableau de bord.
curl -X POST https://api.zinndigital.com/v1/tickets/{ticketId}/messages/{messageId}/attachments \
-H "Authorization: Bearer zdk_live_…"Connecté ? La console d'API de votre tableau de bord saisit votre véritable ID d'organisation ainsi que votre propre clé, et exécute la requête sur l'API de production afin que vous puissiez voir la réponse réelle. Ouvrir ce point de terminaison dans la console API
Détails
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`.
Paramètres
| Nom | Type | Obligatoire | Qu'est-ce que c'est |
|---|---|---|---|
ticketId (path) | Uuid | Oui | The ticket's id. |
messageId (path) | Uuid | Oui | The message the file belongs to. |
Réponse
| Nom | Type | Obligatoire | Qu'est-ce que c'est |
|---|---|---|---|
id | Uuid | Oui | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
filename | string | Oui | 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 | Oui | — |
size_bytes | integer | Oui | — |
scan_state | string<pending, clean, infected, error> | Oui | `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 | Oui | Whether these bytes may be served. True only for `clean`. |
Erreurs que cet point de terminaison peut renvoyer
401 · 403 · 404 · 422 · 429