Skip to main content
POST
Create a resource

Authorizations

Authorization
string
header
required

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

Body

application/json
name
string
required

Display name for the file.

Minimum string length: 1
mime_type
string

MIME type of the file.

size_bytes
number

File size in bytes.

url
string

External URL (e.g. a Google Sheet link). When provided, creates a link-type file with no R2 upload.

description
string

Description for the file.

Response

The created resource, including an upload_url.

data
object
required

Response payload.