Documents

Defining and publishing automations

Design workflow graphs, triggers, steps, retries and approvals, and publish them as versions.

Designing the graph

  • Give every node a stable ID.
  • Declare dependencies explicitly; cycles are rejected.
  • Define what each step takes in and puts out.
  • Keep decisions separate from steps that change something outside the workflow.
  • Put an approval before the action it approves.

Triggers

StartUseDuplicate protection
Run nowA person starts a run from the dashboard; API workflows start with POST /api/v2/workflows/{workflowId}/runsThe caller's idempotency key
EventA document, link, viewing, form, annotation, room, request, Q&A or agent event starts matching automations; filters narrow itEvent ID plus workflow version
Inbound webhookA signed request reaches a Generic HTTP connectionEvent ID plus workflow version
ScheduleOnce, at an interval or on a calendar, in a chosen time zone (set in the dashboard)Scheduled time plus workflow version

Steps

  • Builder steps: process a document with a tool, create, share or revoke a secure link, send an email or an in-app notification, generate an export, ask an agent.
  • Control steps: a branch with conditions and an Otherwise path, a wait for a set time, and an approval that needs a set number of named approvers and can expire.
  • Settings can read {{trigger.payload.x}}, {{input.x}} and {{steps.<stepId>.output.x}}.
  • API workflow graphs (wellfriend-workflow/v2) use action nodes for the operations GET /api/v2/capabilities marks as workflow actions, plus branch, parallel, join, wait, approval and completion nodes.

Retry policy

  • Set the maximum number of attempts and the delay between them.
  • Retry only steps whose effect is safe to repeat.
  • Every attempt is counted, including ones that end early.
  • Permission errors and invalid input are not retried.

Publishing

The whole graph and every action it uses are checked before it is published. A published version never changes and is used by every new run; editing the draft later does not affect runs that have started or finished.