Skip to content
中文

Batches

Guide →

Base URL and authentication

Create batch

POST /media/v1/libraries/{library_id}/batches

Parameter Location Type Description
library_id path string Library ID

Request body

Field Type Required Description
action "tag" / "untag" yes Batch action
tags string[] yes Asset tags. Uploads accept a comma-separated string (items trimmed, empty items dropped), an array, or repeated tags fields; PATCH accepts an array only and replaces the whole list
Field Type Required Description
action "set_context" yes Batch action
context object yes Custom text key/value pairs; PATCH replaces the whole map, {} clears it
Field Type Required Description
action "move" yes Batch action
asset_folder string yes Organizational folder; does not change public_id. Listing by it matches that level only, not subfolders; an empty string is the root
Field Type Required Description
action "delete" yes Batch action
Field Type Required Description
action "reprocess" yes Batch action
kinds ProcessingKind[] no Per-kind processing states
Field Type Required Description
selector BatchSelector yes Select by IDs or expression
reason string no —

Returns: Job.

Response

HTTP 200

Successful response.

application/json

Name Type Description
id string Job identifier: job_ followed by 32 lowercase hexadecimal characters. Poll it with jobs.retrieve.
library_id string Identifier of the library the job runs in; the produced assets land here.
action string Batch operation: tag adds labels, untag removes labels, set_context replaces custom metadata, move changes asset_folder, and delete removes selected assets. reprocess starts fenced understanding Workflows for retryable failed steps and legacy source-size unsupported steps; kinds narrows the selection. Other unsupported and permanent steps remain unchanged.
status string Where the job is. A generation job moves queued, then in_progress, then ends as completed (every output succeeded), failed (no output succeeded) or canceled (stopped by a caller). Keep polling until it is completed, failed or canceled; do not stop at queued. Batch jobs and generation jobs written earlier use running, completed_with_errors and cancelled for the same states, and a job some of whose outputs succeeded answers completed with those outputs marked failed in failures.
type string Category of media this job produces. Image jobs answer image and video jobs answer video; omitted for batch jobs, which change existing assets rather than producing new media.
operation string The operation this job performs: generate for a plain text-to-image or text-to-video job, or the edit operation an image edit applied to its source asset. Omitted for batch jobs.
source_asset_id string Asset this job edits, present on an image edit job and omitted on generation jobs. The produced asset records the same asset in its derived_from field; use assets.lineage for the whole edit tree.
progress number Fraction of this job already processed, from 0 to 1. Poll the job or read its done and total counts to observe progress; do not treat this value as a percentage.
queue_reason string Why a queued generation job has not started yet. queue_reason is omitted once the job starts.
queue_position number Present while the job waits for a slot (queue_reason concurrency): its place in line among the waiting jobs of its type in this library, 1 for the next to start. Waiting jobs start oldest first; keep polling the job, there is nothing to resubmit.
total number Generation job: number of outputs requested (images or videos; text segments for speech). Batch job: number of distinct assets selected when the job was created.
done number Number of outputs or items successfully processed; failed ones are counted separately. For reprocess, this counts accepted launches; inspect asset progress for model completion.
failed number Number of outputs or items that could not be produced or processed.
failures array<object> Always present, including an empty array before any item failure or when all items succeed. At most 20 item failures are returned.
failures[].asset_id string Identifier supplied for the failed item; it may identify a missing asset.
failures[].index integer Zero-based output index for a failed video-generation item.
failures[].code string Domain error code explaining the individual item failure.
failures[].detail_code string The upstream model service’s finer reason for this failure, such as MODEL_PROTOCOL_LINE_UNAVAILABLE or VOICE_SAMPLE_REJECTED. Present when the failure came from a model call, and SHORT_DELIVERY when the model returned fewer outputs than asked (Media’s own, since no upstream code exists); code stays the media error code to branch on: CONTENT_REJECTED, INVALID_PARAMS, UPSTREAM_FAILED and RATE_LIMITED classify the refusal, GENERATION_FAILED is the rest.
failures[].model_request_id string Request id of the model call that failed, the same id shown in the model request log, so the failure can be traced there. Present only when the failure came from a model call.
failures[].message string The model service’s own words for this failure, for a person to read, for example why moderation refused an input. Present only when the failure came from a model call; branch on code, not on this text.
intent string Generation intent recorded on the earliest video jobs; newer generation jobs describe themselves with type and operation instead.
model string Model that produced the outputs of a generation job; omitted for batch jobs.
tier string The performance tier that actually served this job’s model, present only when the request named a tier instead of a model. It is the tier that ran: a balanced request that a capability answers with its economy model reports economy, so a caller can see what it got. model keeps its own meaning and value alongside it.
outputs array<object> Per-output results of a generation job, in index order: one entry per requested image or video, and one per text segment for speech. Every successful output is already a library asset, and its viewer_url opens it in the Console.
outputs[].index integer Zero-based position of this output in the requested count.
outputs[].status string State of this requested output.
outputs[].preview_url string Short-lived signed URL for previewing this output; read the Job again to obtain a fresh URL.
outputs[].seed number | null Seed for this output, when the model returned one; it may be absent.
outputs[].expires_at string Present only on a job written before ADR-094 §2, when outputs were candidates with a retention window. New outputs land in the library as assets and never expire.
outputs[].asset_id string Library asset identifier for this output once the library has stored it.
outputs[].viewer_url string Console page that shows this output in the media library, present once asset_id is. Give this link to the person; the asset_id alone does not open anywhere. Example: https://console.deepraxis.com/media/lib_example?asset_id=9dfa312ef9bc4b00816339b598b1152c.
usage object What this job has been charged, as US dollars in a decimal string with six decimals, for example 0.042300. It is the sum of what the model calls cost, so it can be partial while the job is in_progress and is final once the status is completed or failed. Tell the person this amount. Absent when nothing was charged: every output failed, was refused, or was canceled before a paid call finished. Failed and refused outputs are never charged, so in a job where some outputs failed it counts the succeeded ones only.
usage.amount string US dollars as a decimal string with six decimals, for example 0.042300; never a floating-point number.
usage.currency string Currency code for amount; USD.
created_at string Time the job was created, in UTC.
finished_at string | null Time the job reached a terminal status, or null while queued or running.
pipeline_run_id string Automation run (its root run) that started this job. Omitted when the job was not started by a pipeline. Filter jobs by it with the pipeline_run_id query parameter.
elements array<object> Generation jobs only: the elements the job’s request expanded, each with the version read when the job was created; absent when none were. Same records as the outputs’ provenance.elements. A request that named no element answers no elements key.
elements[].asset_id string Element asset the generation expanded, in the same library as the output.
elements[].version number Element version read when the job was created. Replaying the same Idempotency-Key after the element changed is refused as a different request.
elements[].material_type string Kind of element. character, product and scene contribute their pictures and guidance; brand contributes guidance and palette only, never a picture.
result object Present on a completed align job: how the two recordings line up, with offset_seconds and confidence. Absent on every job that produced assets instead of a fact.
result.offset_seconds number How many seconds later the reference asset starts, relative to the source asset the route named; positive means the reference comes later, so a caller holding both recordings knows which one to slide. It is the negation of the model’s own lag, decided once in the domain.
result.confidence number How sure the alignment is, from 0 to 1; a low value means the two recordings share little to correlate.
终端窗口
curl -X POST "https://api.deepraxis.com/media/v1/libraries/${LIBRARY_ID}/batches" \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"action":"tag","tags":["sample"],"selector":{"ids":["2c25673fd03c41929a22fe860b33d920"]}}'

HTTP 200

{
"id": "job_1c30b97a33cb40dc8f3467a31de1160c",
"library_id": "lib_200f2b495e5f456194e746d66a3a8999",
"action": "tag",
"status": "queued",
"total": 1,
"done": 0,
"failed": 0,
"created_at": "2026-11-13T06:16:58.273Z",
"failures": [],
"finished_at": null
}

Get batch

GET /media/v1/libraries/{library_id}/batches/{job_id}

Parameter Location Type Description
library_id path string Library ID
job_id path string Job ID

Returns: Job.

Response

HTTP 200

Successful response.

application/json

Name Type Description
id string Job identifier: job_ followed by 32 lowercase hexadecimal characters. Poll it with jobs.retrieve.
library_id string Identifier of the library the job runs in; the produced assets land here.
action string Batch operation: tag adds labels, untag removes labels, set_context replaces custom metadata, move changes asset_folder, and delete removes selected assets. reprocess starts fenced understanding Workflows for retryable failed steps and legacy source-size unsupported steps; kinds narrows the selection. Other unsupported and permanent steps remain unchanged.
status string Where the job is. A generation job moves queued, then in_progress, then ends as completed (every output succeeded), failed (no output succeeded) or canceled (stopped by a caller). Keep polling until it is completed, failed or canceled; do not stop at queued. Batch jobs and generation jobs written earlier use running, completed_with_errors and cancelled for the same states, and a job some of whose outputs succeeded answers completed with those outputs marked failed in failures.
type string Category of media this job produces. Image jobs answer image and video jobs answer video; omitted for batch jobs, which change existing assets rather than producing new media.
operation string The operation this job performs: generate for a plain text-to-image or text-to-video job, or the edit operation an image edit applied to its source asset. Omitted for batch jobs.
source_asset_id string Asset this job edits, present on an image edit job and omitted on generation jobs. The produced asset records the same asset in its derived_from field; use assets.lineage for the whole edit tree.
progress number Fraction of this job already processed, from 0 to 1. Poll the job or read its done and total counts to observe progress; do not treat this value as a percentage.
queue_reason string Why a queued generation job has not started yet. queue_reason is omitted once the job starts.
queue_position number Present while the job waits for a slot (queue_reason concurrency): its place in line among the waiting jobs of its type in this library, 1 for the next to start. Waiting jobs start oldest first; keep polling the job, there is nothing to resubmit.
total number Generation job: number of outputs requested (images or videos; text segments for speech). Batch job: number of distinct assets selected when the job was created.
done number Number of outputs or items successfully processed; failed ones are counted separately. For reprocess, this counts accepted launches; inspect asset progress for model completion.
failed number Number of outputs or items that could not be produced or processed.
failures array<object> Always present, including an empty array before any item failure or when all items succeed. At most 20 item failures are returned.
failures[].asset_id string Identifier supplied for the failed item; it may identify a missing asset.
failures[].index integer Zero-based output index for a failed video-generation item.
failures[].code string Domain error code explaining the individual item failure.
failures[].detail_code string The upstream model service’s finer reason for this failure, such as MODEL_PROTOCOL_LINE_UNAVAILABLE or VOICE_SAMPLE_REJECTED. Present when the failure came from a model call, and SHORT_DELIVERY when the model returned fewer outputs than asked (Media’s own, since no upstream code exists); code stays the media error code to branch on: CONTENT_REJECTED, INVALID_PARAMS, UPSTREAM_FAILED and RATE_LIMITED classify the refusal, GENERATION_FAILED is the rest.
failures[].model_request_id string Request id of the model call that failed, the same id shown in the model request log, so the failure can be traced there. Present only when the failure came from a model call.
failures[].message string The model service’s own words for this failure, for a person to read, for example why moderation refused an input. Present only when the failure came from a model call; branch on code, not on this text.
intent string Generation intent recorded on the earliest video jobs; newer generation jobs describe themselves with type and operation instead.
model string Model that produced the outputs of a generation job; omitted for batch jobs.
tier string The performance tier that actually served this job’s model, present only when the request named a tier instead of a model. It is the tier that ran: a balanced request that a capability answers with its economy model reports economy, so a caller can see what it got. model keeps its own meaning and value alongside it.
outputs array<object> Per-output results of a generation job, in index order: one entry per requested image or video, and one per text segment for speech. Every successful output is already a library asset, and its viewer_url opens it in the Console.
outputs[].index integer Zero-based position of this output in the requested count.
outputs[].status string State of this requested output.
outputs[].preview_url string Short-lived signed URL for previewing this output; read the Job again to obtain a fresh URL.
outputs[].seed number | null Seed for this output, when the model returned one; it may be absent.
outputs[].expires_at string Present only on a job written before ADR-094 §2, when outputs were candidates with a retention window. New outputs land in the library as assets and never expire.
outputs[].asset_id string Library asset identifier for this output once the library has stored it.
outputs[].viewer_url string Console page that shows this output in the media library, present once asset_id is. Give this link to the person; the asset_id alone does not open anywhere. Example: https://console.deepraxis.com/media/lib_example?asset_id=9dfa312ef9bc4b00816339b598b1152c.
usage object What this job has been charged, as US dollars in a decimal string with six decimals, for example 0.042300. It is the sum of what the model calls cost, so it can be partial while the job is in_progress and is final once the status is completed or failed. Tell the person this amount. Absent when nothing was charged: every output failed, was refused, or was canceled before a paid call finished. Failed and refused outputs are never charged, so in a job where some outputs failed it counts the succeeded ones only.
usage.amount string US dollars as a decimal string with six decimals, for example 0.042300; never a floating-point number.
usage.currency string Currency code for amount; USD.
created_at string Time the job was created, in UTC.
finished_at string | null Time the job reached a terminal status, or null while queued or running.
pipeline_run_id string Automation run (its root run) that started this job. Omitted when the job was not started by a pipeline. Filter jobs by it with the pipeline_run_id query parameter.
elements array<object> Generation jobs only: the elements the job’s request expanded, each with the version read when the job was created; absent when none were. Same records as the outputs’ provenance.elements. A request that named no element answers no elements key.
elements[].asset_id string Element asset the generation expanded, in the same library as the output.
elements[].version number Element version read when the job was created. Replaying the same Idempotency-Key after the element changed is refused as a different request.
elements[].material_type string Kind of element. character, product and scene contribute their pictures and guidance; brand contributes guidance and palette only, never a picture.
result object Present on a completed align job: how the two recordings line up, with offset_seconds and confidence. Absent on every job that produced assets instead of a fact.
result.offset_seconds number How many seconds later the reference asset starts, relative to the source asset the route named; positive means the reference comes later, so a caller holding both recordings knows which one to slide. It is the negation of the model’s own lag, decided once in the domain.
result.confidence number How sure the alignment is, from 0 to 1; a low value means the two recordings share little to correlate.
终端窗口
curl -X GET "https://api.deepraxis.com/media/v1/libraries/${LIBRARY_ID}/batches/job_1c30b97a33cb40dc8f3467a31de1160c" \
-H "Authorization: Bearer $PRAXIS_API_KEY"

HTTP 200

{
"id": "job_1c30b97a33cb40dc8f3467a31de1160c",
"library_id": "lib_200f2b495e5f456194e746d66a3a8999",
"action": "tag",
"status": "completed",
"total": 1,
"done": 1,
"failed": 0,
"created_at": "2026-11-13T06:16:58.273Z",
"failures": [],
"finished_at": "2026-11-13T06:16:58.320Z"
}

Batch assets alias

POST /media/v1/libraries/{library_id}/assets:batch

Parameter Location Type Description
library_id path string Library ID

Request body

Field Type Required Description
action "tag" / "untag" yes Batch action
tags string[] yes Asset tags. Uploads accept a comma-separated string (items trimmed, empty items dropped), an array, or repeated tags fields; PATCH accepts an array only and replaces the whole list
Field Type Required Description
action "set_context" yes Batch action
context object yes Custom text key/value pairs; PATCH replaces the whole map, {} clears it
Field Type Required Description
action "move" yes Batch action
asset_folder string yes Organizational folder; does not change public_id. Listing by it matches that level only, not subfolders; an empty string is the root
Field Type Required Description
action "delete" yes Batch action
Field Type Required Description
action "reprocess" yes Batch action
kinds ProcessingKind[] no Per-kind processing states
Field Type Required Description
selector BatchSelector yes Select by IDs or expression
reason string no —

Returns: Job.

Response

HTTP 200

Successful response.

application/json

Name Type Description
id string Job identifier: job_ followed by 32 lowercase hexadecimal characters. Poll it with jobs.retrieve.
library_id string Identifier of the library the job runs in; the produced assets land here.
action string Batch operation: tag adds labels, untag removes labels, set_context replaces custom metadata, move changes asset_folder, and delete removes selected assets. reprocess starts fenced understanding Workflows for retryable failed steps and legacy source-size unsupported steps; kinds narrows the selection. Other unsupported and permanent steps remain unchanged.
status string Where the job is. A generation job moves queued, then in_progress, then ends as completed (every output succeeded), failed (no output succeeded) or canceled (stopped by a caller). Keep polling until it is completed, failed or canceled; do not stop at queued. Batch jobs and generation jobs written earlier use running, completed_with_errors and cancelled for the same states, and a job some of whose outputs succeeded answers completed with those outputs marked failed in failures.
type string Category of media this job produces. Image jobs answer image and video jobs answer video; omitted for batch jobs, which change existing assets rather than producing new media.
operation string The operation this job performs: generate for a plain text-to-image or text-to-video job, or the edit operation an image edit applied to its source asset. Omitted for batch jobs.
source_asset_id string Asset this job edits, present on an image edit job and omitted on generation jobs. The produced asset records the same asset in its derived_from field; use assets.lineage for the whole edit tree.
progress number Fraction of this job already processed, from 0 to 1. Poll the job or read its done and total counts to observe progress; do not treat this value as a percentage.
queue_reason string Why a queued generation job has not started yet. queue_reason is omitted once the job starts.
queue_position number Present while the job waits for a slot (queue_reason concurrency): its place in line among the waiting jobs of its type in this library, 1 for the next to start. Waiting jobs start oldest first; keep polling the job, there is nothing to resubmit.
total number Generation job: number of outputs requested (images or videos; text segments for speech). Batch job: number of distinct assets selected when the job was created.
done number Number of outputs or items successfully processed; failed ones are counted separately. For reprocess, this counts accepted launches; inspect asset progress for model completion.
failed number Number of outputs or items that could not be produced or processed.
failures array<object> Always present, including an empty array before any item failure or when all items succeed. At most 20 item failures are returned.
failures[].asset_id string Identifier supplied for the failed item; it may identify a missing asset.
failures[].index integer Zero-based output index for a failed video-generation item.
failures[].code string Domain error code explaining the individual item failure.
failures[].detail_code string The upstream model service’s finer reason for this failure, such as MODEL_PROTOCOL_LINE_UNAVAILABLE or VOICE_SAMPLE_REJECTED. Present when the failure came from a model call, and SHORT_DELIVERY when the model returned fewer outputs than asked (Media’s own, since no upstream code exists); code stays the media error code to branch on: CONTENT_REJECTED, INVALID_PARAMS, UPSTREAM_FAILED and RATE_LIMITED classify the refusal, GENERATION_FAILED is the rest.
failures[].model_request_id string Request id of the model call that failed, the same id shown in the model request log, so the failure can be traced there. Present only when the failure came from a model call.
failures[].message string The model service’s own words for this failure, for a person to read, for example why moderation refused an input. Present only when the failure came from a model call; branch on code, not on this text.
intent string Generation intent recorded on the earliest video jobs; newer generation jobs describe themselves with type and operation instead.
model string Model that produced the outputs of a generation job; omitted for batch jobs.
tier string The performance tier that actually served this job’s model, present only when the request named a tier instead of a model. It is the tier that ran: a balanced request that a capability answers with its economy model reports economy, so a caller can see what it got. model keeps its own meaning and value alongside it.
outputs array<object> Per-output results of a generation job, in index order: one entry per requested image or video, and one per text segment for speech. Every successful output is already a library asset, and its viewer_url opens it in the Console.
outputs[].index integer Zero-based position of this output in the requested count.
outputs[].status string State of this requested output.
outputs[].preview_url string Short-lived signed URL for previewing this output; read the Job again to obtain a fresh URL.
outputs[].seed number | null Seed for this output, when the model returned one; it may be absent.
outputs[].expires_at string Present only on a job written before ADR-094 §2, when outputs were candidates with a retention window. New outputs land in the library as assets and never expire.
outputs[].asset_id string Library asset identifier for this output once the library has stored it.
outputs[].viewer_url string Console page that shows this output in the media library, present once asset_id is. Give this link to the person; the asset_id alone does not open anywhere. Example: https://console.deepraxis.com/media/lib_example?asset_id=9dfa312ef9bc4b00816339b598b1152c.
usage object What this job has been charged, as US dollars in a decimal string with six decimals, for example 0.042300. It is the sum of what the model calls cost, so it can be partial while the job is in_progress and is final once the status is completed or failed. Tell the person this amount. Absent when nothing was charged: every output failed, was refused, or was canceled before a paid call finished. Failed and refused outputs are never charged, so in a job where some outputs failed it counts the succeeded ones only.
usage.amount string US dollars as a decimal string with six decimals, for example 0.042300; never a floating-point number.
usage.currency string Currency code for amount; USD.
created_at string Time the job was created, in UTC.
finished_at string | null Time the job reached a terminal status, or null while queued or running.
pipeline_run_id string Automation run (its root run) that started this job. Omitted when the job was not started by a pipeline. Filter jobs by it with the pipeline_run_id query parameter.
elements array<object> Generation jobs only: the elements the job’s request expanded, each with the version read when the job was created; absent when none were. Same records as the outputs’ provenance.elements. A request that named no element answers no elements key.
elements[].asset_id string Element asset the generation expanded, in the same library as the output.
elements[].version number Element version read when the job was created. Replaying the same Idempotency-Key after the element changed is refused as a different request.
elements[].material_type string Kind of element. character, product and scene contribute their pictures and guidance; brand contributes guidance and palette only, never a picture.
result object Present on a completed align job: how the two recordings line up, with offset_seconds and confidence. Absent on every job that produced assets instead of a fact.
result.offset_seconds number How many seconds later the reference asset starts, relative to the source asset the route named; positive means the reference comes later, so a caller holding both recordings knows which one to slide. It is the negation of the model’s own lag, decided once in the domain.
result.confidence number How sure the alignment is, from 0 to 1; a low value means the two recordings share little to correlate.
终端窗口
curl -X POST "https://api.deepraxis.com/media/v1/libraries/${LIBRARY_ID}/assets:batch" \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"action":"tag","tags":["docs"],"selector":{"ids":["0b189e47017149e5aea17955ada66d31"]}}'

HTTP 200

{
"id": "job_d3d8539613874085ae39b3d14f446d32",
"library_id": "lib_ab7c545e85994e108974c89aa2078cf8",
"action": "tag",
"status": "queued",
"total": 1,
"done": 0,
"failed": 0,
"created_at": "2026-11-13T06:17:14.445Z",
"failures": [],
"finished_at": null
}

Get job alias

GET /media/v1/libraries/{library_id}/jobs/{job_id}

Parameter Location Type Description
library_id path string Library ID
job_id path string Job ID

Returns: Job.

Response

HTTP 200

Successful response.

application/json

Name Type Description
id string Job identifier: job_ followed by 32 lowercase hexadecimal characters. Poll it with jobs.retrieve.
library_id string Identifier of the library the job runs in; the produced assets land here.
action string Batch operation: tag adds labels, untag removes labels, set_context replaces custom metadata, move changes asset_folder, and delete removes selected assets. reprocess starts fenced understanding Workflows for retryable failed steps and legacy source-size unsupported steps; kinds narrows the selection. Other unsupported and permanent steps remain unchanged.
status string Where the job is. A generation job moves queued, then in_progress, then ends as completed (every output succeeded), failed (no output succeeded) or canceled (stopped by a caller). Keep polling until it is completed, failed or canceled; do not stop at queued. Batch jobs and generation jobs written earlier use running, completed_with_errors and cancelled for the same states, and a job some of whose outputs succeeded answers completed with those outputs marked failed in failures.
type string Category of media this job produces. Image jobs answer image and video jobs answer video; omitted for batch jobs, which change existing assets rather than producing new media.
operation string The operation this job performs: generate for a plain text-to-image or text-to-video job, or the edit operation an image edit applied to its source asset. Omitted for batch jobs.
source_asset_id string Asset this job edits, present on an image edit job and omitted on generation jobs. The produced asset records the same asset in its derived_from field; use assets.lineage for the whole edit tree.
progress number Fraction of this job already processed, from 0 to 1. Poll the job or read its done and total counts to observe progress; do not treat this value as a percentage.
queue_reason string Why a queued generation job has not started yet. queue_reason is omitted once the job starts.
queue_position number Present while the job waits for a slot (queue_reason concurrency): its place in line among the waiting jobs of its type in this library, 1 for the next to start. Waiting jobs start oldest first; keep polling the job, there is nothing to resubmit.
total number Generation job: number of outputs requested (images or videos; text segments for speech). Batch job: number of distinct assets selected when the job was created.
done number Number of outputs or items successfully processed; failed ones are counted separately. For reprocess, this counts accepted launches; inspect asset progress for model completion.
failed number Number of outputs or items that could not be produced or processed.
failures array<object> Always present, including an empty array before any item failure or when all items succeed. At most 20 item failures are returned.
failures[].asset_id string Identifier supplied for the failed item; it may identify a missing asset.
failures[].index integer Zero-based output index for a failed video-generation item.
failures[].code string Domain error code explaining the individual item failure.
failures[].detail_code string The upstream model service’s finer reason for this failure, such as MODEL_PROTOCOL_LINE_UNAVAILABLE or VOICE_SAMPLE_REJECTED. Present when the failure came from a model call, and SHORT_DELIVERY when the model returned fewer outputs than asked (Media’s own, since no upstream code exists); code stays the media error code to branch on: CONTENT_REJECTED, INVALID_PARAMS, UPSTREAM_FAILED and RATE_LIMITED classify the refusal, GENERATION_FAILED is the rest.
failures[].model_request_id string Request id of the model call that failed, the same id shown in the model request log, so the failure can be traced there. Present only when the failure came from a model call.
failures[].message string The model service’s own words for this failure, for a person to read, for example why moderation refused an input. Present only when the failure came from a model call; branch on code, not on this text.
intent string Generation intent recorded on the earliest video jobs; newer generation jobs describe themselves with type and operation instead.
model string Model that produced the outputs of a generation job; omitted for batch jobs.
tier string The performance tier that actually served this job’s model, present only when the request named a tier instead of a model. It is the tier that ran: a balanced request that a capability answers with its economy model reports economy, so a caller can see what it got. model keeps its own meaning and value alongside it.
outputs array<object> Per-output results of a generation job, in index order: one entry per requested image or video, and one per text segment for speech. Every successful output is already a library asset, and its viewer_url opens it in the Console.
outputs[].index integer Zero-based position of this output in the requested count.
outputs[].status string State of this requested output.
outputs[].preview_url string Short-lived signed URL for previewing this output; read the Job again to obtain a fresh URL.
outputs[].seed number | null Seed for this output, when the model returned one; it may be absent.
outputs[].expires_at string Present only on a job written before ADR-094 §2, when outputs were candidates with a retention window. New outputs land in the library as assets and never expire.
outputs[].asset_id string Library asset identifier for this output once the library has stored it.
outputs[].viewer_url string Console page that shows this output in the media library, present once asset_id is. Give this link to the person; the asset_id alone does not open anywhere. Example: https://console.deepraxis.com/media/lib_example?asset_id=9dfa312ef9bc4b00816339b598b1152c.
usage object What this job has been charged, as US dollars in a decimal string with six decimals, for example 0.042300. It is the sum of what the model calls cost, so it can be partial while the job is in_progress and is final once the status is completed or failed. Tell the person this amount. Absent when nothing was charged: every output failed, was refused, or was canceled before a paid call finished. Failed and refused outputs are never charged, so in a job where some outputs failed it counts the succeeded ones only.
usage.amount string US dollars as a decimal string with six decimals, for example 0.042300; never a floating-point number.
usage.currency string Currency code for amount; USD.
created_at string Time the job was created, in UTC.
finished_at string | null Time the job reached a terminal status, or null while queued or running.
pipeline_run_id string Automation run (its root run) that started this job. Omitted when the job was not started by a pipeline. Filter jobs by it with the pipeline_run_id query parameter.
elements array<object> Generation jobs only: the elements the job’s request expanded, each with the version read when the job was created; absent when none were. Same records as the outputs’ provenance.elements. A request that named no element answers no elements key.
elements[].asset_id string Element asset the generation expanded, in the same library as the output.
elements[].version number Element version read when the job was created. Replaying the same Idempotency-Key after the element changed is refused as a different request.
elements[].material_type string Kind of element. character, product and scene contribute their pictures and guidance; brand contributes guidance and palette only, never a picture.
result object Present on a completed align job: how the two recordings line up, with offset_seconds and confidence. Absent on every job that produced assets instead of a fact.
result.offset_seconds number How many seconds later the reference asset starts, relative to the source asset the route named; positive means the reference comes later, so a caller holding both recordings knows which one to slide. It is the negation of the model’s own lag, decided once in the domain.
result.confidence number How sure the alignment is, from 0 to 1; a low value means the two recordings share little to correlate.
终端窗口
curl -X GET "https://api.deepraxis.com/media/v1/libraries/${LIBRARY_ID}/jobs/job_d3d8539613874085ae39b3d14f446d32" \
-H "Authorization: Bearer $PRAXIS_API_KEY"

HTTP 200

{
"id": "job_d3d8539613874085ae39b3d14f446d32",
"library_id": "lib_ab7c545e85994e108974c89aa2078cf8",
"action": "tag",
"status": "completed",
"total": 1,
"done": 1,
"failed": 0,
"failures": [],
"created_at": "2026-11-13T06:17:14.445Z",
"finished_at": "2026-11-13T06:17:14.493Z"
}

Job

Field Type Required Description
id JobId yes Resource ID
library_id LibraryId yes Library ID
action tag / untag / set_context / move / delete / reprocess / "generate" yes Batch action
status JobStatus yes Resource status
type GenerationType no Resource or event type
operation GenerationOperation no —
source_asset_id AssetId no —
progress number no —
queue_reason "concurrency" / "provider_throttled" / "provider_queue" no —
queue_position number no —
total number yes Total assets in this job
done number yes Completed count; completion flag for chunk responses
failed number yes Failure count
failures object[] yes —
intent string no —
model string no —
tier MediaTier no —
outputs object[] no —
usage object no —
created_at IsoTimestamp yes Creation time
finished_at IsoTimestamp / null yes Completion time; null while unfinished
pipeline_run_id string no —
elements ElementUse[] no —
result AlignResult no Operation result

BatchSelector

Field Type Required Description
ids AssetId[] yes Asset IDs
Field Type Required Description
expression string yes Structured query expression; an empty expression returns every asset
exclusions AssetId[] no Asset IDs excluded from selection

BatchAction

Field Type Required Description
action "tag" / "untag" yes Batch action
tags string[] yes Asset tags. Uploads accept a comma-separated string (items trimmed, empty items dropped), an array, or repeated tags fields; PATCH accepts an array only and replaces the whole list
Field Type Required Description
action "set_context" yes Batch action
context object yes Custom text key/value pairs; PATCH replaces the whole map, {} clears it
Field Type Required Description
action "move" yes Batch action
asset_folder string yes Organizational folder; does not change public_id. Listing by it matches that level only, not subfolders; an empty string is the root
Field Type Required Description
action "delete" yes Batch action
Field Type Required Description
action "reprocess" yes Batch action
kinds ProcessingKind[] no Per-kind processing states