Skip to main content
The File resource is split into two sets of endpoints:
  • Metadata APIs — create and manage the file’s metadata record (filename, type, access, and more).
  • File data APIs — upload, download, and delete the actual file bytes at the upload_url returned when you create the metadata.

Sample payload

Metadata APIs

Create file metadata

POST /files Create a file metadata record. The response includes an upload_url you use with the File data APIs to upload the file bytes.

Get file metadata

GET /files/<file_key> Retrieve a file’s metadata by its key.
file_key
string
required
Unique key of the file.

Update file metadata

PATCH /files/<file_key> Update a file’s metadata. Include only the fields you want to change.
file_key
string
required
Unique key of the file.

Delete file metadata

DELETE /files/<file_key> Delete a file’s metadata.
file_key
string
required
Unique key of the file.

File data APIs

These endpoints operate on the upload_url returned by Create file metadata (the upload_url field of the file record). Use that URL directly in place of <upload_url> below.

Upload file

PUT <upload_url> Upload the file’s bytes to the upload_url.

Download file

GET <upload_url> Download the file’s bytes from the upload_url.

Delete file

DELETE <upload_url> Delete the file’s bytes at the upload_url.