Skip to content

Workflows

Workflows

Durable, event-driven workflows that coordinate systems, data, people and agents — designed visually or authored as JSON.

Last updated 2 min read Edit this page on GitHub
On this page

A workflow is a directed graph: one trigger node, then nodes connected by edges. The engine executes the published version node by node, carrying variables from step to step, recording every step, and pausing safely whenever it has to wait.

The workflow designer
The designer: palette on the left, canvas in the middle, the selected node's settings on the right.

What a workflow can do#

  • Start from a task event, a data-table row change, a webhook, a schedule, an SLA or error in another workflow, a retention review, or a direct API / MCP / CLI call. See Triggers.
  • Decide with conditions, value switches and decision tables.
  • Repeat with for-each and N-times loops, and run parallel branches.
  • Call integration references, HTTP endpoints, custom workflow actions (your own sandboxed steps, or the official ones), AI agents and other workflows.
  • Change data in data tables and tasks; transform text, dates, JSON, collections, CSV/Excel files and Office documents.
  • Involve people with User Tasks that wait for an outcome, and send email from templates.
  • Wait for minutes, days or a date without holding a server process (see Delays and pauses).

All 93 node types (plus the section and live-reference canvas tools) are listed in the node reference.

Lifecycle#

  1. Draft — edit on the canvas or send a definition with PATCH /api/v1/workflows/{id} (usertasks workflows update). Validation runs as you edit.
  2. Test — the designer's Save & test saves the draft and runs your test cases, showing each node's input, output and log.
  3. Publish — freezes the draft as a new version. Runs always use the published version. See Versions and runs.
  4. Activate — an active workflow listens to its trigger; deactivate it to stop new runs without deleting anything.

Each run has a Timeline next to its Process view: who started it, who each step went to, comments, approvals with their outcomes, notable automatic steps (emails, records, decisions, waits, errors) and where it is now, in plain words. It is the first tab for people who don't build workflows. See Timeline.

Authoring as JSON#

The designer and the API use the same definition: nodes, edges, user_variables and optional swimlanes.

A minimal workflow definitionJSON
{
  "name": "Notify on large invoices",
  "trigger_type": "webhook_received",
  "nodes": [
    { "id": "t1", "type": "webhook_received", "label": "Invoice received", "position": { "x": 400, "y": 40 }, "config": {} },
    { "id": "n1", "type": "condition", "label": "Over 10k?", "position": { "x": 400, "y": 200 },
      "config": { "branches": [{ "label": "Large", "logic": "AND", "rules": [{ "field": "{{amount}}", "operator": "greater_than", "value": "10000" }] }], "has_else": true } },
    { "id": "n2", "type": "send_email", "label": "Tell finance", "position": { "x": 250, "y": 360 },
      "config": { "to": "finance@example.com", "subject": "Large invoice {{invoice_number}}", "body": "Amount: {{amount}}" } }
  ],
  "edges": [
    { "id": "e1", "source": "t1", "target": "n1" },
    { "id": "e2", "source": "n1", "target": "n2", "label": "Large" }
  ]
}
Bash
usertasks workflows create -f notify.json
usertasks workflows publish <id>

AI assistants can author workflows the same way through MCP (workflows_catalog, workflows_create, workflows_update); see MCP.

Was this page helpful?