Skip to main content
POST
Upload File

Authorizations

Authorization
string
header
required

Primary scheme: Authorization: Key <key_id>:<secret>.

Body

multipart/form-data
file
file
required

The file to upload.

Response

Successful Response

POST /v3/files result. The presigned url is the file handle: pass it as {"source": "url", "url": <url>} in any media input the model's schema advertises (image / end_image / images / audio / video) on submit.

url
string
required

Presigned GET URL for the stored bytes — the handle itself. Pass it back verbatim, query string included: a modified URL is not recognised as your handle and is rejected as an external URL.

content_type
string
required

MIME type sniffed from the uploaded bytes; the request's own Content-Type and filename are never trusted. Decides which media inputs will accept this handle.

expires_at
string<date-time>
required

ISO-8601 instant url stops being accepted — one hour after upload. Submitting with a lapsed handle is a 400 with reason: "expired", not a fetch failure; upload the file again for a fresh handle. The stored object is deleted separately by a bucket lifecycle policy about a day after upload, so treat re-uploading, not re-presigning, as the remedy.