Skip to main content
POST
Upload a file

Authorizations

Authorization
string
header
required

An API key of one app, sent as Authorization: Bearer <key>. Keys start with fk_test_ (test mode: sandbox senders and test data only) or fk_live_ (live mode). Keep live keys on your server; never ship them in an app or page.

Headers

Idempotency-Key
string

A unique string (up to 255 characters) that makes this request safe to retry. A repeat with the same key within 24 hours returns the first answer instead of acting again. See "Idempotency" in the introduction.

Required string length: 1 - 255
Flow-Version
string<date>

The API version to use, as a date. Without it, the version pinned to your app when it was created is used.

Example:

"2026-11-01"

Body

multipart/form-data

A file to upload, as multipart form data.

file
file
required

The file's bytes. Its real type is read from its first bytes.

filename
string

The name to show for the file; defaults to the uploaded part's file name.

Maximum string length: 255
channel
enum<string>

A messaging channel.

Available options:
telegram,
whatsapp,
imessage

Response

The file was stored.

A stored file. Send it as media or voice content by file_id.

id
string
required

A file ID, file_ and a ULID.

Pattern: ^file_[0-9A-HJKMNP-TV-Z]{26}$
Example:

"file_01JB8ZG7Q9S1V3X5Z7B9D1F3G5"

mime_type
string
required

The real type, checked from the first bytes.

size_bytes
integer
required

The file's size.

url
string<uri>
required

Its Flow URL (https://api.flow.engineer/v1/files/{file_id}), which redirects to the bytes for an authenticated request.

livemode
boolean
required

Whether the file belongs to live mode.

created_at
string<date-time>
required

When the file was stored.

expires_at
string<date-time>
required

When the file will be deleted under your plan's retention.

filename
string

The file's name, if it has one.