Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.anyreach.ai/llms.txt

Use this file to discover all available pages before exploring further.

The Output step ends a branch of execution and produces the workflow’s return value. Every reachable branch in a workflow should terminate with an Output step.
Output step inspector

What it does

  • Evaluates any expressions in the output fields
  • Returns the result to the caller
  • Terminates that path of execution with status success
A workflow with multiple Output steps (one per Condition branch) returns whichever Output step execution reached.

Output fields

Each output field has:
  • Name — the key returned to the caller
  • Typestring, number, boolean, array, or object
  • Value — a literal value or expression resolved against ctx

When to use multiple Output steps

Use a separate Output step on each branch of a Condition step so every path has a clear termination:
[Condition]
  ├─ found       →  [Output: success — with contact data]
  ├─ not_found   →  [Output: not found — with error message]
  └─ default     →  [Output: error — with fallback]
This is cleaner than one Output step with conditional field values.

Examples

Simple success output

{
  "success": true,
  "contact_name": "{{ `Lookup contact`.body.first_name }}",
  "tier": "{{ `Lookup contact`.body.tier }}"
}

Not-found output

{
  "success": false,
  "message": "No contact found for that email address."
}

Agent-tool friendly output

When the workflow is invoked as an agent tool, keep output small and text-focused. The agent’s LLM uses the output to formulate a spoken response:
{
  "summary": "Account tier is {{ n1.body.tier }}, balance is {{ n1.body.balance }}, last active {{ n1.body.last_seen }}."
}
A single summary string is more robust than a deeply-nested object the LLM has to navigate.

Considerations

  • Output terminates the path. Any steps connected after an Output are unreachable.
  • Pure expressions preserve types. {{ n1.balance }} returns a number if the source is a number. Mixing with text (e.g., "Balance: {{ n1.body.balance }}") always produces a string.