Join us for our Developer Platform Hackathon, May 16-17. Apply now →
import { Client } from "@notionhq/client"
const notion = new Client({ auth: process.env.NOTION_API_KEY })
const response = await notion.fileUploads.complete({
file_upload_id: "a02fc1d3-db8b-45c5-a222-27595b15aea7"
}){
"object": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_time": "2023-11-07T05:31:56Z",
"created_by": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "person"
},
"last_edited_time": "2023-11-07T05:31:56Z",
"in_trash": true,
"expiry_time": "2023-11-07T05:31:56Z",
"status": "pending",
"filename": "<string>",
"content_type": "<string>",
"content_length": 1,
"upload_url": "<string>",
"complete_url": "<string>",
"file_import_result": {
"imported_time": "2023-11-07T05:31:56Z",
"type": "<string>",
"success": {}
},
"number_of_parts": {
"total": 1,
"sent": 1
}
}Use this API to finalize a mode=multi_part file upload after all of the parts have been sent successfully.
import { Client } from "@notionhq/client"
const notion = new Client({ auth: process.env.NOTION_API_KEY })
const response = await notion.fileUploads.complete({
file_upload_id: "a02fc1d3-db8b-45c5-a222-27595b15aea7"
}){
"object": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_time": "2023-11-07T05:31:56Z",
"created_by": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "person"
},
"last_edited_time": "2023-11-07T05:31:56Z",
"in_trash": true,
"expiry_time": "2023-11-07T05:31:56Z",
"status": "pending",
"filename": "<string>",
"content_type": "<string>",
"content_length": 1,
"upload_url": "<string>",
"complete_url": "<string>",
"file_import_result": {
"imported_time": "2023-11-07T05:31:56Z",
"type": "<string>",
"success": {}
},
"number_of_parts": {
"total": 1,
"sent": 1
}
}Documentation Index
Fetch the complete documentation index at: https://developers.notion.com/llms.txt
Use this file to discover all available pages before exploring further.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
The API version to use for this request. The latest version is 2026-03-11.
2026-03-11 Identifier for a Notion file upload object.
Always file_upload
"file_upload"Show child attributes
One of: pending, uploaded, expired, failed
pending, uploaded, expired, failed x >= 0Show child attributes
Show child attributes