SnozeDevelopers
API referenceAssets

Complete a direct multipart upload

Finalizes the multipart upload, verifies the stored object's size against what the session declared, and returns the resulting asset with its capability URL. Requires a workspace member with the `files:write` permission. A session that has expired, been aborted, or is completed with the wrong number of parts is rejected; completing a session that already finished returns the existing asset. Send an `Idempotency-Key` header to make retries safe; a replay within the window returns the original response.

POST
/v1/workspaces/{workspaceId}/assets/uploads/{sessionId}/complete

Authorization

apiKey
headerAuthorizationBearer <snoze_sk_…>

Workspace API key created in Workspace settings → API keys. Scopes on the key bound what it can read and write.

Path Parameters

workspaceId*string
sessionId*string

Request Body

application/json
  1. body
parts*array<>

Response Body

Success

application/json
  1. response
data*
Example Request
curl -X POST 'https://api.snoze.dev/v1/workspaces/string/assets/uploads/string/complete' \  -H 'Content-Type: application/json' \  -d '{  "parts": [    {      "partNumber": 0,      "etag": "string"    }  ]}'
Example Response
{  "data": {    "fileId": "string",    "url": "string",    "name": "string",    "size": 0,    "mimeType": "string"  }}