Workflows API
Download OpenAPI DocumentChain translation, review and dubbing steps into one automated run.
Chain steps such as dubbing, document translation, quality checks, exports and human approvals into one workflow, then run it as often as you like. New here? Read Workflows for the whole flow and the graph format.
Every request
Send your organization API key in the x-api-key header; it starts with uvk_. Create one in the Universe app under Settings → API keys. The key and organization limits count requests over a rolling minute. See Authentication and Rate limits.
The typical flow: find the step types you need with List step types, save a workflow with Create a workflow (check it first with Validate a workflow), read what a run asks for in its inputSchema, then Start a run and poll it with Get a run. When a run reaches an Approval gate, Approve a step or Reject a step.
Runs work in the background, so every call returns straight away. Saving a workflow is free. A run is charged step by step, as each step starts, at the rate of the product that does the work; Start a run lists the rates. Without enough credits it returns 402 and nothing starts. See Credits.
Every route needs a cosmos permission on the role of the member who created the API key: read to look, create, update and delete to manage workflows, execute to run them. Each step also needs the permission of its own product, listed in its requires.
Workflows
A workflow is a saved graph of steps and the edges between them. Create, validate, update and delete your organization's workflows here; built-in workflows can be read and run but not changed.
List workflows
Get a workflow
Create a workflow
Validate a workflow
Update a workflow
Get your copy of a ready-made workflow
Step types
The building blocks of a workflow: product steps such as dubbing, translation and quality checks, and the logic.* gates that wait, branch, run in parallel and ask for approval. Read them first to learn each step's field keys.
List step types
Runs
A run is one execution of a workflow with its own inputs. Start it, poll it until it finishes, then retry or cancel it if you need to. You can also rename a run, file it in a folder and choose who owns each step.
- POST/v1/cosmos/flows/{id}/run
- GET/v1/cosmos/executions
- GET/v1/cosmos/executions/{id}
- POST/v1/cosmos/executions/{id}/retry
- POST/v1/cosmos/executions/{id}/rename
- GET/v1/cosmos/executions/{id}/images.zip
- PATCH/v1/cosmos/executions/{id}/project
- POST/v1/cosmos/executions/{id}/images/save-to-drive
- POST/v1/cosmos/executions/{id}/nodes/{nodeId}/step-owners
Start a run
List runs
Get a run
Poll a run. status is the run's; nodes has every step's own status, its output once it has succeeded, and a link to the work it created (navigation). When status is PAUSED, an Approval gate is waiting: approve or reject it. A dub step whose status is awaiting_action while the run is RUNNING waits for its speakers' voices: approve them with Approve speaker voices in the Video Dubbing API, using the job ID in its navigation.processId. Poll every 10 to 30 seconds; runs with dubbing take minutes.
Permission: cosmos:read. An API key acts with the role of the member who created it.
Path Parameters
Run ID (executionId), from Start a run or List runs.
Responses
200The run.
Run ID.
The workflow this is a run of.
Name of the run: the one you gave, or one taken from its inputs (such as the source file name), or else the workflow name.
Name of the workflow.
RUNNING, PAUSED (an Approval gate is waiting for Approve or Reject), COMPLETED, FAILED or TERMINATED (cancelled). The last three are final.
Why the run failed, or the reason given when an Approval gate was rejected. Null otherwise.
The flow as it was when the run started. Later edits to the workflow do not change a run.
Show child attributes
Every step, including exactly one logic.start and one logic.end once the flow has a real step.
Show child attributes
Your id for the node, unique within the flow. Edges, inputBindings, run inputs and run steps refer to it. Letters, digits, - and _ keep run-input keys readable.
The step type, a key from List step types, such as tv.instant_clone, logic.approval or logic.start.
Canvas position, used only to draw the flow in the Universe app.
Show child attributes
Horizontal position on the canvas, in pixels.
Vertical position on the canvas, in pixels.
Values fixed when you save the flow, keyed by field key from the step type's inputSchema (and configSchema, for the LLM step). A field set here is not asked for when the flow runs. Gates keep their settings here too: a Delay's durationSeconds, an Approval's label and instructions, a Switch's cases and defaultCase.
Inputs read from an earlier step, keyed by input field key: { "<inputKey>": { "fromNodeId", "outputKey" } }. This is what the run reads; draw a matching binding edge so the canvas shows the wire.
Every connection between steps.
Show child attributes
id of the node the edge starts from.
id of the node the edge goes to.
Your id for the edge.
Where the edge leaves the source. For a control edge: __ctl_out, or case:<caseKey> from a Switch. For a binding edge: the source's output key. For a share edge: an input key of the source.
Where the edge enters the target. For a control edge: __ctl_in. For a binding or share edge: the target's input key.
control: run order and branching (Start → step → gate → … → End). binding: data from an output to an input (mirror it in the target's inputBindings). share: two inputs of the same type that take one value, asked for once when the flow runs. Left out, the edge is a binding.
Reserved. Stored with the flow but not used to route a run: branch with a Switch gate instead.
Show child attributes
Output key of the source node to test.
The value the output must equal.
The input the run was started with.
Every step of the run, in run order, with its live status and outputs.
Show child attributes
The step's node id.
Step type key.
Product that runs the step.
pending (not reached yet), running, awaiting_action (waiting for a person: an Approval gate, or a dub waiting for its voices to be approved), succeeded, failed, skipped (on a branch the completed run did not take) or cancelled.
The step's outputs, keyed by the step type's outputSchema keys, once it has succeeded. Null for gates and unfinished steps.
Where the work this step created opens in the Universe app. Null for gates and steps that have not started.
Show child attributes
What the link opens: tv_editor (a Video Dubbing job), qc_decision (a Quality Control result), pg_document (a document translation), and so on.
Path in the Universe web app, relative to your organization, once the step has created its job.
The job the link opens, where the step sets it.
The Quality Control result the link opens, where set.
Why the step failed. Null unless it failed.
True when the step refused its input before anything ran (an unreadable file, an unsupported language). error then says why, in words meant for the member; retrying the same input fails the same way.
True when error is the step's own message for the member (what went wrong, what was or was not charged, what to do next). Without it, error may be technical and is not shown as is.
Present on gates only.
Show child attributes
Which gate this is.
The gate's config from the flow, such as an Approval's label and instructions.
Who is responsible for which step. Empty when nobody is.
Show child attributes
The step's node id.
Member ID in your organization.
The member's user ID.
The member's name.
The member's email address.
When the run started.
When the run reached a final status. Null while it is live.
When the run last moved on: a step started or needed action, or the run finished, failed, was approved, rejected, retried or cancelled. A rename or a move to another project does not count.
True while the run is RUNNING or PAUSED; false once it is final.
400Invalid request: a field failed validation, or a parameter is malformed (for example, an ID that is not a UUID).
HTTP status code, repeated in the body.
What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.
Short name of the status.
401The `x-api-key` header is missing, or the key is invalid, expired or deleted.
HTTP status code, repeated in the body.
What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.
Short name of the status.
403Not allowed: the API key's role lacks the permission (`PermissionDenied`), the product is not enabled for your organization, or it has been turned off.
HTTP status code, repeated in the body.
What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.
Short name of the status.
404No run with this `id` in your organization, or the run is in a project you can’t see (`Execution <id> not found`).
HTTP status code, repeated in the body.
What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.
Short name of the status.
429Too many requests for this key. Wait the number of seconds in `Retry-After`, then retry.
HTTP status code, repeated in the body.
What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.
Short name of the status.
500Something failed on our side. Retry with backoff; if it persists, contact support with the `X-Request-Id`.
HTTP status code, repeated in the body.
What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.
Short name of the status.
curl '{{API_BASE_URL}}/v1/cosmos/executions/a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d' \
--header 'x-api-key: YOUR_API_KEY'{
"executionId": "a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d",
"flowId": "3c9d7e1a-5b2f-4a6c-8d0e-1f2a3b4c5d6e",
"name": "product-launch.mp4",
"flowName": "Dub to Hindi, review, export",
"status": "PAUSED",
"error": null,
"graph": {
"nodes": [
{
"id": "start",
"nodeTypeKey": "logic.start",
"position": {
"x": 0,
"y": 0
}
},
{
"id": "dub",
"nodeTypeKey": "tv.instant_clone",
"position": {
"x": 240,
"y": 0
},
"config": {
"sourceLanguage": "en-US",
"targetLanguage": "hi-IN",
"speakerCount": "2"
}
},
{
"id": "review",
"nodeTypeKey": "logic.approval",
"position": {
"x": 480,
"y": 0
},
"config": {
"label": "Review the Hindi dub",
"instructions": "Check names and numbers in the editor."
}
},
{
"id": "export",
"nodeTypeKey": "tv.export",
"position": {
"x": 720,
"y": 0
},
"config": {
"targetLanguage": "hi-IN",
"withSubtitles": true
},
"inputBindings": {
"parentProcessId": {
"fromNodeId": "dub",
"outputKey": "processId"
}
}
},
{
"id": "end",
"nodeTypeKey": "logic.end",
"position": {
"x": 960,
"y": 0
}
}
],
"edges": [
{
"id": "e1",
"source": "start",
"target": "dub",
"sourceHandle": "__ctl_out",
"targetHandle": "__ctl_in",
"kind": "control"
},
{
"id": "e2",
"source": "dub",
"target": "review",
"sourceHandle": "__ctl_out",
"targetHandle": "__ctl_in",
"kind": "control"
},
{
"id": "e3",
"source": "review",
"target": "export",
"sourceHandle": "__ctl_out",
"targetHandle": "__ctl_in",
"kind": "control"
},
{
"id": "e4",
"source": "export",
"target": "end",
"sourceHandle": "__ctl_out",
"targetHandle": "__ctl_in",
"kind": "control"
},
{
"id": "e5",
"source": "dub",
"target": "export",
"sourceHandle": "processId",
"targetHandle": "parentProcessId",
"kind": "binding"
}
]
},
"input": {
"dub__source": {
"uploadIds": [
"5e6f7a8b-9c0d-4e1f-a2b3-c4d5e6f7a8b9"
]
},
"dub__tmId": "8c7b6a5d-4e3f-4a2b-9c1d-0e9f8a7b6c5d"
},
"nodes": [
{
"nodeId": "dub",
"nodeTypeKey": "tv.instant_clone",
"galaxy": "translate-video",
"status": "succeeded",
"output": {
"processId": "9b1f6c2e-3d4a-4e5f-8a7b-1c2d3e4f5a6b"
},
"navigation": {
"kind": "tv_editor",
"deepLink": "galaxy/translate-video/editor/9b1f6c2e-3d4a-4e5f-8a7b-1c2d3e4f5a6b",
"processId": "9b1f6c2e-3d4a-4e5f-8a7b-1c2d3e4f5a6b",
"decisionId": "4a8e2b71-0c3d-4f5e-9a6b-7c8d9e0f1a2b"
},
"error": null,
"inputError": true,
"errorForMember": true,
"control": {
"kind": "approval",
"config": {
"label": "Review the Hindi dub",
"instructions": "Check names and numbers in the editor."
}
}
}
],
"stepOwners": [
{
"nodeId": "review",
"memberId": "2b4d6f8a-1c3e-4a5b-8c7d-9e0f1a2b3c4d",
"userId": "Uq3x9KpL2vT8wYz1",
"name": "Priya Sharma",
"email": "priya@example.com"
}
],
"startedAt": "2026-10-02T14:10:00.000Z",
"finishedAt": null,
"lastActivityAt": "2026-10-02T14:31:05.000Z",
"live": true
}Retry a run
Rename a run
Download a run’s images
Move a run to a project
Save a run’s images to Drive
Set step owners
Approvals
An Approval gate pauses a run until someone decides. While it waits, the run's status is awaiting_action: approve the step to continue, or reject it to stop the run.