Skip to content
TALA
Esc
navigateopen⌘Jpreview

Initiate a multipart upload to S3

POST/api/upload/initiate
Authorization
AuthorizationBearer token (JWT) · headerrequired
Header parameters
x-organization-idstring
Target organization id. Defaults to the caller's personal organization when omitted.
Request body
requiredapplication/json
fileNamestringrequired
contentTypestringrequired
partCountnumberrequired
collectionIdstringrequired
Responses
201Upload initiated
any
400Bad Request
any
401Unauthorized
any
500Internal Server Error
any
Try it
Server
Authorization
Parameters
Bodyapplication/json
Request
curl -X POST "http://localhost:8000/api/upload/initiate" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "fileName": "example.png",
  "contentType": "image/png",
  "partCount": 5,
  "collectionId": "CL01"
}'
Response
{
  "message": "Upload Initiated",
  "data": {
    "uploadId": "vY7.L8mP0zRQW...",
    "key": "collection/CLq4Wm7x1P/uuid-filename.png",
    "presignedUrls": [
      "https://s3.amazonaws.com/tala-store/key?partNumber=1&uploadId=...",
      "https://s3.amazonaws.com/tala-store/key?partNumber=2&uploadId=..."
    ]
  }
}