Complete a presigned upload
POST/files/{file_id}/complete
Finalize a presigned upload after you have PUT the bytes to the upload URL. Kicks off ingest/moderation and returns the file, which transitions to ready (or failed) asynchronously — poll GET /files/{file_id} to observe the terminal state.
Complete a presigned upload
curl https://agents.lumalabs.ai/v1/files/$FILE_ID/complete \
-X POST \
-H "Authorization: Bearer $LUMA_AGENTS_API_KEY"{
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"created_at": "2019-12-27T18:11:19.117Z",
"mime_type": "mime_type",
"purpose": "input",
"size_bytes": 0,
"state": "pending",
"deleted_at": "2019-12-27T18:11:19.117Z",
"expires_at": "2019-12-27T18:11:19.117Z",
"failure_reason": "failure_reason",
"filename": "filename",
"user_id": "user_id"
}Returns Examples
{
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"created_at": "2019-12-27T18:11:19.117Z",
"mime_type": "mime_type",
"purpose": "input",
"size_bytes": 0,
"state": "pending",
"deleted_at": "2019-12-27T18:11:19.117Z",
"expires_at": "2019-12-27T18:11:19.117Z",
"failure_reason": "failure_reason",
"filename": "filename",
"user_id": "user_id"
}