Run a Claude-Code-format dynamic workflow.

Synopsis

workflow run <file.js> [--args <json>] [--budget <n>] [--concurrency <n>] [--wait]

Description

Runs a JavaScript workflow file (or inline script) that can fan out work across parallel agent calls. Default is non-blocking and returns a run id; pass --wait to block and print the full result.

Options

run <file.js> [--args <json>] [--budget <n>] [--concurrency <n>] [--wait] Start a workflow from a file.

run --script '<inline js>' [...] Start a workflow from an inline script.

list List known workflow runs.

status <runId> Show the status of a run.

stop <runId> Stop a running workflow.

save <runId> <name> [--force] Save a run's result under a name.

Examples

$ workflow run build.js --wait

Run a workflow and block until it finishes.

$ workflow status abc123

Check the status of a running workflow.

$ workflow list

List known workflow runs.

Notes

Results land at /shared/workflow-runs/<id>.json. Workflow code must be deterministic: Date, Math.random, crypto, and timers throw inside a workflow script.

See Also

agent