Skip to main content
POST
/
files
/
uploads
/
{upload_id}
/
complete
curl -X POST https://api.u1.archetypeai.app/v0.5/files/uploads/upl-7d6c9f0a3b51/complete \
  -H "Authorization: Bearer $ATAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "parts": [
      { "part_number": 3, "part_token": "\"f912ab83e0d1...\"" },
      { "part_number": 4, "part_token": "\"203fa182b97c...\"" }
    ]
  }'
{
  "file_uid": "1d4f9b2e-3a8c-4e1d-bb02-7d6c9f0a3b51",
  "file_name": "training-data.parquet",
  "num_bytes": 1073741824,
  "file_status": "Registered",
  "file_attributes": {
    "metadata_status": "not_extracted"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.archetypeai.app/llms.txt

Use this file to discover all available pages before exploring further.

Overview

Finalize a direct-to-cloud upload after the client has PUT every part to its presigned URL. The server validates the supplied part_tokens, assembles the final file, and registers it with the organization. Parts already submitted via Checkpoint Upload Parts do not need to be repeated here — only supply tokens for parts not yet checkpointed.
Direct-to-cloud file uploads support files up to 250GB.

Path Parameters

upload_id
string
required
Upload identifier returned by Initiate Upload

Request Body

parts
array
required
Completed parts that have not already been checkpointed

Response

file_uid
string
Internal unique identifier of the completed file
file_name
string
Name of the completed file
num_bytes
integer
Total size of the completed file in bytes
file_status
string
Lifecycle status of the file. After a successful upload, the status is Registered. Other values are: Unknown, Uploading, Ingested, Deleting, Deleted, and Corrupt.
The format of the status string returned for direct-to-cloud uploads is different from the file_status string returned by the Get File Metadata endpoint.
file_attributes
object
Type-specific attributes for the file. Shape depends on the file type — see Get File Metadata for the variants.
curl -X POST https://api.u1.archetypeai.app/v0.5/files/uploads/upl-7d6c9f0a3b51/complete \
  -H "Authorization: Bearer $ATAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "parts": [
      { "part_number": 3, "part_token": "\"f912ab83e0d1...\"" },
      { "part_number": 4, "part_token": "\"203fa182b97c...\"" }
    ]
  }'
{
  "file_uid": "1d4f9b2e-3a8c-4e1d-bb02-7d6c9f0a3b51",
  "file_name": "training-data.parquet",
  "num_bytes": 1073741824,
  "file_status": "Registered",
  "file_attributes": {
    "metadata_status": "not_extracted"
  }
}