Complete a multipart upload
POST
/v1/uploads/{id}/complete
const url = 'https://api.wirevod.online/v1/uploads/example/complete';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"parts":[{"number":1,"etag":"\"a1b2c3\"","sha256":"9f2c4d5e6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b2c3d"}]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.wirevod.online/v1/uploads/example/complete \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "parts": [ { "number": 1, "etag": "\"a1b2c3\"", "sha256": "9f2c4d5e6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b2c3d" } ] }'Authorizations
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”id
required
string
Request Body
Section titled “Request Body”Media typeapplication/json
object
parts
Array<object>
object
number
required
integer
etag
string
sha256
string
Example
{ "parts": [ { "number": 1, "etag": "\"a1b2c3\"", "sha256": "9f2c4d5e6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b2c3d" } ]}Responses
Section titled “ Responses ”Upload verified and completed; processing starts (idempotent).
Media typeapplication/json
object
upload
required
object
id
required
string
asset_id
required
string
status
required
string
part_size
required
integer
part_count
required
integer
size_bytes
required
integer
expires_at
required
integer
created_at
required
integer
completed_at
required
integer | null
asset
required
One of:
object
id
required
string
title
required
string
status
required
string
failure_code
required
string | null
source_width
required
integer | null
source_height
required
integer | null
source_fps
required
number | null
source_codec
required
string | null
source_duration_ms
required
integer | null
source_bitrate_kbps
required
integer | null
origin_size_bytes
required
integer | null
checksum_sha256
required
string | null
drm_enabled
required
boolean
visibility
required
string
published_at
required
integer | null
created_at
required
integer
null
Example
{ "upload": { "id": "upl_01J9Z", "asset_id": "ast_01J9Z", "status": "completed", "part_size": 16777216, "part_count": 8, "size_bytes": 120000000, "expires_at": 1760086400000, "created_at": 1760000000000, "completed_at": 1760000100000 }, "asset": { "id": "ast_01J9Z", "title": "Launch keynote", "status": "uploaded", "failure_code": null, "source_width": null, "source_height": null, "source_fps": null, "source_codec": null, "source_duration_ms": null, "source_bitrate_kbps": null, "origin_size_bytes": 120000000, "checksum_sha256": "9f2c4d5e6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b2c3d", "drm_enabled": false, "visibility": "private", "published_at": null, "created_at": 1760000000000 }}The request was malformed or failed validation.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "invalid_request", "code": "invalid_request", "message": "asset_id is required"}Missing or invalid credentials.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "unauthorized", "code": "unauthorized", "message": "Authentication required"}The principal lacks the required scope or role.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "forbidden", "code": "forbidden", "message": "Missing required scope: write"}The resource does not exist in the tenant, or the route is unknown.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "not_found", "code": "not_found", "message": "Asset not found"}The request conflicts with the resource’s current state.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "upload_in_progress", "code": "upload_in_progress", "message": "An upload is already in progress for this asset"}Too many requests in the current window.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "rate_limited", "code": "rate_limited", "message": "Too many requests", "details": { "retry_after": 60 }}Headers
Section titled “Headers”Retry-After
integer
Seconds to wait before retrying.
A temporary storage problem occurred; retry with backoff.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "storage_error", "code": "storage_error", "message": "Media storage unavailable"}