Skip to main content
POST
cURL

Authorizations

Authorization
string
header
required

JWT Bearer token obtained from authentication. Pass as: Authorization: Bearer

Path Parameters

messageId
string
required

ID of the message to attach the file to

Pattern: ^[cC][^\s-]{8,}$

Body

application/json

Request body for initiating a file attachment upload

filename
string
required

Filename for the attachment (max 255 characters)

Required string length: 1 - 255
mimeType
string
required

MIME type of the file being uploaded

Minimum string length: 1
sizeBytes
integer
required

File size in bytes (must be greater than zero)

Required range: x >= 0

Response

200 - application/json

OK

File attachment associated with a message

id
string
required

Unique identifier of the attachment

Pattern: ^[cC][^\s-]{8,}$
filename
string
required

Original filename of the attachment

mimeType
string
required

MIME type of the attachment (e.g. application/pdf)

sizeBytes
integer
required

File size in bytes

Required range: x >= 0
storageKey
string
required

Internal storage key for retrieving the file

url
string<uri> | null
required

Pre-signed download URL, or null if not yet generated

createdAt
string<date-time>
required

Timestamp when the attachment was created

scanStatus
enum<string>
required

Content-scan verdict. BLOCKED attachments cannot be downloaded — inspect before fetching bytes.

Available options:
PENDING,
CLEAN,
FLAGGED,
BLOCKED
detectedMimeType
string | null
required

MIME type inferred from magic bytes; may differ from the declared mimeType