Attachments
Upload, scan and download message attachments. Generated from the OpenAPI specification.
Upload, scan and download message attachments.
POST /v1/attachments/upload-intent
Reserve an attachment and get a 5-minute presigned PUT URL.
Authentication: Messaging token (Authorization: Bearer <token>), from the user’s device.
Request body (application/json, required)
| Field | Type | Required | Notes |
|---|---|---|---|
conversationId | string (uuid) | Yes | |
fileName | string | Yes | min length 1; max length 255 |
size | integer | Yes | ≥ 1 |
mediaType | string | Yes | pattern ^[a-z]+\/[a-z0-9.+-]+$/i |
Response 201 Created
| Field | Type | Required | Notes |
|---|---|---|---|
attachment | object | Yes | |
attachment.id | string (uuid) | Yes | |
attachment.fileName | string | Yes | |
attachment.mediaType | string | Yes | |
attachment.size | integer | Yes | |
attachment.status | "pending", "ready", "rejected" | Yes | |
attachment.scanStatus | "not_scanned", "pending", "clean", "infected", "rejected", "failed" | No | |
uploadUrl | string | Yes | |
headers | map | Yes | |
expiresAt | string | Yes |
Errors: 400 Invalid request · 401 Missing or invalid credentials · 403 Not permitted · 404 Not found (including resources of other projects) · 429 Rate limit or quota exceeded. Error bodies follow the error format.
POST /v1/attachments/{id}/complete
Verify the uploaded object (size and type) and mark it usable.
Authentication: Messaging token (Authorization: Bearer <token>), from the user’s device.
Path parameters
| Field | Type | Required | Notes |
|---|---|---|---|
id | string (uuid) | Yes |
Response 200 OK
| Field | Type | Required | Notes |
|---|---|---|---|
id | string (uuid) | Yes | |
fileName | string | Yes | |
mediaType | string | Yes | |
size | integer | Yes | |
status | "pending", "ready", "rejected" | Yes | |
scanStatus | "not_scanned", "pending", "clean", "infected", "rejected", "failed" | No |
Errors: 400 Invalid request · 401 Missing or invalid credentials · 403 Not permitted · 404 Not found (including resources of other projects) · 429 Rate limit or quota exceeded. Error bodies follow the error format.
GET /v1/attachments/{id}/url
A 5-minute presigned download URL, after membership checks.
Authentication: Messaging token (Authorization: Bearer <token>), from the user’s device.
Path parameters
| Field | Type | Required | Notes |
|---|---|---|---|
id | string (uuid) | Yes |
Response 200 OK
| Field | Type | Required | Notes |
|---|---|---|---|
url | string | Yes | |
expiresAt | string | Yes |
Errors: 400 Invalid request · 401 Missing or invalid credentials · 403 Not permitted · 404 Not found (including resources of other projects) · 429 Rate limit or quota exceeded. Error bodies follow the error format.