Skip to main content
POST
Complete file upload
Step two of the two-step upload. Call it after the file’s bytes are PUT to the upload_url from Start large upload. The computer pulls the file into the folder you asked for, replacing a file of the same name, and the temporary copy in storage is deleted. The computer must be running. If placing the file fails, the stored copy is kept, so you can call this again with the same upload_token until it expires (one hour after the upload started).

Request

Send a JSON body.
string
required
The same computer ID you passed to Start large upload.
string
required
The upload_token from Start large upload.

Response

boolean
true when the file was placed on the computer.
string
The file’s name on the computer.
string
The folder the file was placed in: your destPath, or the desktop when you sent none or desktop. The file name is not appended.
integer
The file’s size in bytes.

Example

Response

Errors

Every error carries the shape {"error": "<message>"}. The scope-mismatch 403 adds code, key_workspace_id, and target_workspace_id. The checks below run in order.

Authorizations

Authorization
string
header
required

API key authentication. Get your key at orgo.ai/workspaces

Body

application/json
desktopId
string
required

The same computer ID as step 1.

upload_token
string
required

The upload_token from POST /files/uploads.

Response

The file is in place.

ok
boolean
filename
string
placedIn
string

The folder it was placed in.

size_bytes
integer