Skip to main content
POST
Upload attachment

Authorizations

Authorization
string
header
required

Token JWT de autenticaΓ§Γ£o

Headers

x-company-id
string

Target company identifier. Required only for global API keys (type=global). Ignored for company API keys and human users.

Body

multipart/form-data
file
file
required

Arquivo para upload

fileType
enum<string>
required

Tipo do arquivo (IMAGE, AUDIO, VIDEO, DOCUMENT, STICKER)

Available options:
IMAGE,
AUDIO,
VIDEO,
DOCUMENT,
STICKER

Response

Attachment created

extension
string
required

File extension (jpg, png, pdf, and so on).

external_url
string
required

Public file URL. Deprecated: prefer deriving a signed URL from s3_key.

file_type
enum<string>
required

File type: IMAGE, AUDIO, VIDEO, DOCUMENT, or STICKER.

Available options:
IMAGE,
AUDIO,
VIDEO,
DOCUMENT,
STICKER
company
any
required

Company that owns the attachment.

_id
string

Attachment ID.

s3_key
string

Storage key of the object, used to derive the signed URL.

meta
object

Additional file metadata: mimeType, size, fileName, and others.

createdAt
any

When the attachment was created.

updatedAt
any

When the attachment was last updated.