Skip to content
REST API

Start a file upload

POST
/notes/{noteId}/files

Reserves a file on the note and returns a signed upload. POST the file to upload.url with the upload.fields within 10 minutes, then call POST /files/{fileId}/complete. A file that is never completed is deleted after 24 hours. Each user can hold 200 files and 2 GiB, and each note 25 files. Files on trashed notes count until permanent deletion.

Required scopes: files:upload

Authorization

AuthorizationBearer <token>

In: header

Path Parameters

noteId*string

Note id, scoped to the key's user.

Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid

Header Parameters

Idempotency-Key?string

A client-generated key (1 to 255 visible ASCII characters) that makes this POST safe to retry. A retry with the same key and body replays the original response; the same key with a different body returns 409 idempotency_conflict. Stored for 24 hours.

Match^[\x21-\x7E]{1,255}$
Length1 <= length <= 255

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/notes/497f6eca-6276-4993-bfeb-53cbbbba6f08/files" \  -H "Content-Type: application/json" \  -d '{    "fileName": "string",    "mimeType": "string",    "sizeBytes": 1  }'
{  "data": {    "id": "3c2b1a09-8f7e-4d6c-9b5a-4e3d2c1b0a9f",    "status": "awaiting_upload",    "upload": {      "url": "https://storage.example.com/workroad",      "fields": [        {          "name": "bucket",          "value": "workroad"        },        {          "name": "key",          "value": "note/3c2b1a09-8f7e-4d6c-9b5a-4f3e2d1c0b9a/3c2b1a09-8f7e-4d6c-9b5a-4e3d2c1b0a9f-cell-biology-lecture.pdf"        },        {          "name": "Content-Type",          "value": "application/pdf"        },        {          "name": "x-amz-date",          "value": "20260115T093000Z"        },        {          "name": "x-amz-algorithm",          "value": "AWS4-HMAC-SHA256"        },        {          "name": "x-amz-credential",          "value": "EXAMPLEKEY/20260115/us-east-1/s3/aws4_request"        },        {          "name": "policy",          "value": "eyJleHBpcmF0aW9uIjoiMjAyNi0wMS0xNVQwOTo0MDowMFoifQ=="        },        {          "name": "x-amz-signature",          "value": "9b2f0c1d8e7a6b5c4d3e2f1a0b9c8d7e6f5a4b3c2d1e0f9a8b7c6d5e4f3a2b1c"        }      ]    },    "expiresAt": "2026-01-15T09:40:00.000Z"  }}