Workflow Reference
A workflow is a graph of connected nodes that runs when its trigger fires. Every Outrun agent runs on a workflow. This page is for anyone editing a workflow on the canvas.
Node types
The canvas offers these node types. On a phone-width screen the palette shows all of them except Human Review.
| Node | What it does |
|---|---|
| Trigger | Starts the workflow. |
| AI Step | Sends instructions and data to a language model and returns its response. |
| Decision | Chooses one branch based on conditions. |
| Action | Performs an operation, such as sending an email or updating a connected app. |
| Human Review | Pauses for a person to approve or edit before the workflow continues. See human-in-the-loop review. |
Triggers
Choose how a workflow starts in the Trigger node:
| Trigger | Starts the workflow when |
|---|---|
| On a schedule | A schedule is due |
| When data changes | Data is added, updated or removed |
| An email arrives | |
| Message | A message arrives in a channel or platform |
| Webhook | Another service sends an HTTP request |
Schedule options are: every 5, 10, 15 or 30 minutes, every hour, every 6 hours, daily at specific times, weekly, monthly, or a custom cron expression.
Execution order
- A workflow cannot contain a cycle. Outrun rejects a graph that loops back on itself.
- A node runs only after every node it depends on has finished.
- Nodes that do not depend on each other run at the same time when they are the same number of steps from the trigger.
Decision nodes
A Decision node checks its conditions in order. It takes the branch of the first condition that matches. If none matches, it takes its default branch.
| Operator | Matches when the field |
|---|---|
equals |
Equals the value |
not_equals |
Does not equal the value |
contains |
Contains the value as text |
not_contains |
Does not contain the value |
starts_with |
Starts with the value |
ends_with |
Ends with the value |
greater_than |
Is a number greater than the value |
less_than |
Is a number less than the value |
is_empty |
Is missing, empty, blank, 0 or false |
is_not_empty |
Has a non-blank value other than 0 or false |
matches |
Matches the value as a regular expression |
A condition with any other operator is ignored.
Note: When you branch on an AI Step's output, ask the AI Step to return JSON with a fixed field, such as
"category": "support". Decisions on predictable values are more reliable than decisions on free text.
Skipped branches
- Only the branch the Decision chose runs. Nodes reachable only through other branches are skipped.
- A node where several branches meet still runs if at least one branch that ran leads to it.
- If a reviewer rejects a human review step, the nodes after it are skipped, unless another branch that ran also leads to them. See human-in-the-loop review.
When a step fails
By default a step that fails stops the run. A step can instead be set to continue when it fails. Its output then says that it failed and why, so a Decision after it can send the case to a person, for example with a Human Review that names the email and the problem.
AI Step settings
| Setting | Range |
|---|---|
| Randomness | 0 (Precise) to 2 (Creative). A value of 0 runs as 0.7, so use 0.1 for the most predictable output. |
| Max Tokens | 100 to 4000 tokens. |
Template variables
Use template variables in node settings to insert data from the trigger or from earlier nodes.
| Variable | Inserts |
|---|---|
{{trigger.<field>}} |
A field from the trigger data |
{{<nodeId>.<field>}} |
A field from an earlier node's output. Use dots for nested fields. |
{{ai.<field>}} |
A field from the most recent AI Step output |
{{$item}}, {{$index}} |
The current item and its zero-based position, inside a node that runs once per item |
Variables refer to a node by its ID, not its label. If a variable cannot be resolved, it stays in the text as written. Check for leftover { characters in outputs when you test a workflow.
Run history
The workflow editor lists the last 5 runs under Recent Runs, with each run's start time and status.
Custom actions
Turn on Make available as custom action in a workflow's settings to let agents in the same workspace use that workflow as a tool. Write a clear workflow description: it tells the agent when to use the workflow. Add the workflow to an agent from the agent's Tools section.
End the workflow with a Return step to give the agent a result. The Return step takes a set of named values, up to 16 KB. A workflow without a Return step gives an empty result. The agent gets one of these outcomes: completed with the result, failed, waiting (the workflow is waiting for human approval), timeout (the workflow is still running) or refused.
An Execute Workflow step can also wait for the result of another workflow in the same workspace. Turn on its wait option and set how long to wait.