Skip to main content
POST
Upload File

Authorizations

x-user-auth
string
header
required

Your API key from account settings

x-bot
string
header
required

Your bot ID from account settings

Body

multipart/form-data
Attachment
file
required

The file to upload

Model.FileType
string

Optional: Image, Audio, Video, or File. Inferred from the file content-type if omitted.

Example:

"File"

ConvertAttachmentTo
string

Optional target format to convert the attachment to

EncryptFileName
boolean
default:false

Whether to encrypt the stored file name

Response

200 - application/json

File uploaded successfully

FileURL
string<uri>

Presigned URL of the uploaded file

FileMimeType
string

MIME type of the uploaded file

Example:

"text/plain"

FileName
string

Stored file name

FilePath
string

Path of the file in storage