multipart/form-data instead of JSON.
Method
Parameters
Identifier for a Notion file upload object, obtained from the
id of the Create File Upload response.Required for multi-part uploads. Stringified integer (e.g.,
"1", "2", "3") indicating which part is being sent. Must be sequential starting from "1" and match the number_of_parts specified in create.Response
Returns an updated FileUpload object.Updated status:
"pending" (for multi-part, more parts needed) or "uploaded" (for single-part, or after all parts sent and complete called).For multi-part uploads, tracks progress:
total: Total number of parts expectedsent: Number of parts successfully uploaded
After successful upload, contains import results:
type:"success"or"error"imported_time: ISO 8601 timestamperror: Error details if type is"error"
Examples
Single-part upload
For files under 20MB, send all data in one request:Multi-part upload
For files larger than 20MB, split into parts and send sequentially:Browser file upload
Using the File API in browsers:Notes
- This endpoint sends HTTP
multipart/form-datainstead of JSON - For multi-part uploads, parts must be sent sequentially starting from
"1" - The
part_numberparameter must be a string, not a number - After sending all parts, call complete to finalize the upload
- File data is passed under the
file.dataproperty, not as the raw file
Related
- Create file upload - Initialize upload
- Complete file upload - Finalize multi-part upload
- List file uploads - Track upload status