Skip to content

Data between steps

Every run carries its data with it. Steps read that data through expressions and add their own results to it.

Name What it holds
input.<field> The values the run started with: the API body’s input, the arguments an agent passed, a scheduled item, or the mapped fields of a business event.
data.<name> Values stored during the run. A data name can also be used on its own, so data.booking and booking are the same.
steps.<stepId>.<field> The result of a step, by its step id.
correlation.<key> The run’s correlation values, such as customerRef or appointmentId.
trigger.<field> Details the trigger adds. A Channel inbound trigger sets trigger.channel, trigger.language and trigger.withinHours.
item, index Inside a For each: the current item (also under the name you choose) and its position.
error.message In an error path: why the step failed. The full failure is in data.error.
status.code The run’s current status code.
now The current time, as ISO 8601 text.

A name that does not exist evaluates to null, so coalesce(input.nickname, input.name) is a safe way to fall back.

Triggers that receive data (API / webhook, Started by an agent) list their Input fields. Each field has a key, a type and whether it is required.

Type Accepts
text Any text
number A number, or text such as "1,250.50"
boolean true/false, or yes/no, 1/0, on/off
date A date such as 2026-12-31
phone A phone number, such as +919800000000
email An email address
choice One of the options you list

Values are checked and converted when the run starts. A run that is missing a required field, or has a value of the wrong type, is refused with 422 invalid_input and a message that names the field. For an agent, this message goes back to the model so it can ask the customer again.

Values you send that are not listed as input fields, such as a list of documents, are passed through to input unchecked.

The run’s input is limited to 64 KB.

Most steps that produce a result have a Store result as field (on some steps, Store answers as or Store event as). With booking there, the result is available as data.booking for the rest of the run. The result is always available as steps.<stepId> as well.

Examples:

  • An MCP tool step stores the tool’s response.
  • An Approval or Human task stores the answers to its form.
  • A Collect form step stores the customer’s checked answers.
  • A Wait for event step stores the event’s data.
  • A Sub-workflow stores the child run’s outcome and its End step’s output.

Fields such as Condition, Recipient or Wait until take an expression. Expressions are a small, safe language:

  • values: numbers, text in quotes, true, false, null, lists;
  • operators: and, or, not, comparisons, in, + - * / // % **, and a if condition else b;
  • functions: len, min, max, sum, round, floor, ceil, sqrt, pow, abs, int, float, str, lower, upper, contains, coalesce, join, add_minutes, add_hours, add_days, days_between.

Dates are ISO 8601 text. Include the time zone offset (2026-12-04T10:00:00+05:30); a time without one is read as UTC.

input.amount > 500000
contains(lower(input.message), "refund")
add_hours(input.appointmentAt, -24)
days_between(now, input.dueDate) < 3

Text fields such as Instructions or Task are templates: plain text with expressions in double braces.

Check the documents for {{ input.customerName }}, application {{ input.applicationId }}.

The Data mapper step stores values under names the rest of the workflow uses. Each row is a name and an expression.

Name Expression
customerName input.customer.firstName
isPriority input.tier == "gold"
dueDate add_days(now, 7)

With Store under empty, each name goes straight into data (data.customerName). With Store under set to customer, they go into data.customer.customerName.

For arithmetic, such as an EMI or a late fee, use Compute, which also rounds to the decimal places you choose.

Run data ends with the run. To keep a fact for later runs, use the shared context.

  • Write context stores values for a customer, a case or a conversation. You can set how long a value is kept and whether an existing value is overwritten.
  • Read context recalls values. Each key is stored in data under the same name, so later steps can use it at once. You choose whether a missing key is an error.

Whose context it is comes from Whose context, or by default from the run’s correlation: customerRef for a customer, caseRef for a case, conversationId for a conversation. Start runs with these correlation keys and the context steps work without extra settings.

Consent recorded by the Consent step (beta) is kept in the same customer context, so a later run can check it without asking again.

A Status update step sets a customer-safe status for the run: a code, the text the customer may be told, optional translations and a progress percentage.

This is the only part of a run your systems and customers see. The public run status (statusCode, statusLabel) and the run.status_updated webhook carry it, while the run’s data, timeline and tasks stay private. Write the label as you would say it to the customer: “An underwriter is reviewing your application.”

Turn on Also tell the customer now to send the label as a message at the same time.

  • Use Mask PII before personal data reaches another agent, system or the run view. You can mask for the rest of the run, the next step only, or only in logs and run views.
  • Pass only what a step needs. An agent step’s Context to pass in and a task agent’s Inputs limit what the agent receives.