Results and files

Routes in this group. Authentication, scope and rate limit errors apply to every route and are on the errors page.

All routes

GET/batches/{batchId}/preview.png

Read the contact sheet preview of one output file.

Scope
results:read
Rate bucket
read, 240 a minute per key
GET /api/pipeline/v1/batches/{batchId}/preview.png parameters
NameInTypeRequiredNotes
batchIdpathstringYes
pathquerystringYesmax length 512

Request. Query: path, the output file path (at most 512 characters). Needs results:read.

Returns. image/png. Previews are kept outside the result ZIP.

Errors specific to this route. 404 batch_not_found, 404 preview_not_found. Authentication, scope and rate limit errors apply to every route.

GET/batches/{batchId}/result-url

Get a short-lived link to the result ZIP in storage.

Scope
results:read
Rate bucket
read, 240 a minute per key
GET /api/pipeline/v1/batches/{batchId}/result-url parameters
NameInTypeRequiredNotes
batchIdpathstringYes

Request. Path: the batch id. Needs results:read. Same refusals as result.zip.

Returns. url, expiresAt, sha256 and bytes. The link lasts at most 15 minutes and never outlives the export.

Errors specific to this route. 404 batch_not_found, 409 result_not_ready, 410 batch_expired, 410 result_expired, 409 partial_output_refused, 409 result_too_large, 404 result_object_missing, 503 result_busy. Authentication, scope and rate limit errors apply to every route.

GET/batches/{batchId}/result.json

Read the batch result document.

Scope
results:read
Rate bucket
read, 240 a minute per key
GET /api/pipeline/v1/batches/{batchId}/result.json parameters
NameInTypeRequiredNotes
batchIdpathstringYes

Request. Path: the batch id. Needs results:read.

Returns. The myrlin.asset-batch-result/1 document: every asset, its files, hashes and the checks they passed or failed. Download the schema from the manifest page's schema links.

Errors specific to this route. 404 batch_not_found, 409 result_not_ready, 410 batch_expired. Authentication, scope and rate limit errors apply to every route.

GET/batches/{batchId}/result.zip

Download the ZIP of delivered files.

Scope
results:read
Rate bucket
read, 240 a minute per key
GET /api/pipeline/v1/batches/{batchId}/result.zip parameters
NameInTypeRequiredNotes
batchIdpathstringYes

Request. Path: the batch id. Needs results:read.

Returns. application/zip, with the sha256 of the archive as its ETag. The ZIP is at most 128 MB. Verify its size and sha256 against result.json before you install anything.

Errors specific to this route. 404 batch_not_found, 409 result_not_ready, 410 batch_expired, 410 result_expired, 409 partial_output_refused, 409 result_too_large, 409 result_bytes_changed, 503 result_busy. Authentication, scope and rate limit errors apply to every route.

GET/files/{fileId}

Read the bytes of one delivered PNG or OGG file you own.

Scope
results:read
Rate bucket
read, 240 a minute per key
GET /api/pipeline/v1/files/{fileId} parameters
NameInTypeRequiredNotes
fileIdpathstringYes

Request. Path: the file id. Needs results:read. Send If-None-Match to get 304 for a file you already hold.

Returns. The file, at most 2 MB. Any other format, a larger file, a file you do not own or a superseded file answers 404 file_not_found. A file id never changes its bytes.

Errors specific to this route. 404 file_not_found, 409 result_bytes_changed, 503 result_busy. Authentication, scope and rate limit errors apply to every route.

GET/files/{fileId}/download

Download one delivered file you own, any format, up to 256 MB.

Scope
results:read
Rate bucket
read, 240 a minute per key
GET /api/pipeline/v1/files/{fileId}/download parameters
NameInTypeRequiredNotes
fileIdpathstringYes

Request. Path: the file id. Needs results:read. Works for live and superseded files.

Returns. The file as an attachment, with the file kind's media type (else application/octet-stream), never cached. Its bytes are checked against the stored size and sha256 before or while they are sent. A file you do not own, an unknown id or a missing file answers 404 file_not_found; a file over 256 MB answers 413 file_too_large with maxBytes.

Errors specific to this route. 404 file_not_found, 413 file_too_large, 409 result_bytes_changed, 503 result_busy. Authentication, scope and rate limit errors apply to every route.