Execute a workflow by slug or slug@version
Submit a workflow for execution using its globally unique slug.
Identical to runWorkflow but uses the human-readable slug instead of UUID.
The slug must belong to the specified team’s workflows.
Pass slug@version (for example, text-to-image@2) to run the workflow
JSON and parameter definitions saved for that version snapshot.
Accepts JWT Bearer, sk- integration credential, or dk- device credential.
Authorizations
User session JWT (Bearer ). Must be paired with the X-Team-ID
request header on team-scoped endpoints so the server knows which
team's resources to operate on.
Headers
UUID of the team to scope the request to. Used by dual-auth endpoints (runtime + scoped management):
- JWT callers MUST send it — a user may belong to multiple teams and the runtime cannot otherwise know which one to operate on. Missing header → 400.
- Credential callers (
sk-,dk-) can omit it because the team is derived from the credential row itself. Any value sent is ignored.
"019abc12-4567-7890-abcd-ef1234567891"
Path Parameters
Workflow slug for runtime lookup. Use slug for the latest version or
slug@version to reference an immutable workflow snapshot, e.g. text-to-image@2.
128^[a-z0-9]+(?:-[a-z0-9]+)*(?:@[1-9][0-9]*)?$"text-to-image@2"
Body
Request body to execute a workflow with optional parameter overrides.
Workflow run usage
Step 1 — Discover available parameters
Call GET /r/workflows/{workflowId} or
GET /r/workflows/slug/{workflowSlug} to retrieve the workflow
detail. To target a previous workflow version, use slug@version
(for example, text-to-image@2). The parameters array contains ParameterDef entries that describe
every user-configurable input. Each entry has:
Example parameters from a workflow detail response:
Step 2 — Build the run request
Use the key values from the parameter definitions as keys in the
parameters object:
For type: file parameters, upload the file first, then pass the file_key:
POST /r/files/presignwith{"file_name": "photo.png", "file_size": 1048576, "content_type": "image/png"}- Upload the file to the returned
upload_urlvia HTTP PUT. - Pass the
file_keyas the parameter value:
Step 3 — Validation rules
- Unknown keys →
400 Bad Request(only keys from ParameterDef are accepted). - Missing required keys →
400 Bad Request. - Type mismatch →
400 Bad Request(e.g. string for a number parameter). - Out of range →
400 Bad Request(number outside min/max bounds). - Invalid select value →
400 Bad Request(value not in the options list). - File not uploaded →
400 Bad Request(file_key not found in S3). - File wrong team →
400 Bad Request(file_key must belong to the team). - File type rejected →
400 Bad Request(file MIME doesn't matchacceptpattern). - Omitted optional keys → the workflow's
defaultvalue is used automatically. - Empty body
{}→ valid if no parameters are required (all have defaults). - Workflow with no parameters → send
{}or omitparametersentirely.
Step 4 — Poll for results
The response contains a task_id. Poll status:
When task_status is completed, fetch the output:
Key-value map of parameter overrides. Keys must match the key field
of a ParameterDef entry defined in the workflow's parameters array.
For type: file parameters, the value must be a file_key string
obtained from POST /r/files/presign. Upload the file first, then pass
the key here.
Retrieve available keys by calling GET /r/workflows/{workflowId}
or GET /r/workflows/slug/{workflowSlug} and inspecting
the parameters array in the response. Use workflowSlug@version to
discover parameters for a previous workflow version.
Maximum 100 parameter keys per request.
Where to execute this task:
agent(default): Execute on a local BYOC agent.comfy_cloud: Execute on ComfyUI Cloud (requires configured API key).
If omitted, the workflow's default_dispatch_target is used, falling
back to agent.
agent, comfy_cloud "agent"
Dispatch pool for this task. Only meaningful when
dispatch_target=agent.
team(default): route to an agent in the same team — the P2.1 behaviour.community: route to any opted-in agent across teams via the Cyberun community pool. Submitting team does not need to opt in to consume; the serving agent does.
If omitted, defaults to team.
team, community "team"
Submitter's declared geographic / network locality, used by
the P3.1 scoring engine to favour region-matching agents
when multiple candidates are eligible. Opaque user-supplied
string (e.g. us-east, eu-central, ap-southeast); normalised
server-side to lowercase + trimmed. Empty / omitted →
scorer treats as unknown (neutral 0.5 region factor; no
agent is disqualified). Has no effect on
dispatch_target=comfy_cloud.
64"us-east"
Tool runtime used by this workflow:
comfyui: ComfyUI API workflow JSON (default, backward compatible).nerfstudio: Nerfstudio 3DGS pipeline spec.
comfyui, nerfstudio "comfyui"
Response
Task submitted
ID of the created task. Use this to poll task status and results.
"019abc12-9012-7890-abcd-ef1234567896"
