Skip to main content
POST
Start a large file upload

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
filename
string
required

Name for the file, without extension (the extension is added from the MIME type). 1–64 characters: letters, numbers, underscores, and hyphens.

mime_type
string
required

MIME type of the file. Must be one of the supported file types.

size
integer<int64>
required

Exact file size in bytes (2 KB – 10 GB, and within your remaining CDN quota).

folder
string

Optional folder prefix (same character rules as filename; "error-pages" is reserved).

expire_at
string<date-time>

Optional expiration time in RFC3339 format. Must be more than 3h50m from now.

Response

Upload started

id
string<uuid>

Upload ID, used in the finalize call.

filename
string

The name the file is stored under (folder, name and extension). Also what you pass to DELETE /cdn/files?fileName= to cancel the upload.

parts
object[]
expires_at
string<date-time>

When the part URLs stop working and finalize is refused.