Input & Output
Output ports, written memory state, and how to reference assigned variables from downstream nodes.
Output Ports
| Port | Condition | Description |
|---|---|---|
| success | Assignment completed without error | The variable was written to workflow memory. The workflow continues along this port. Downstream nodes can immediately read the variable using var.variableName. |
| error | Expression evaluation failed or invalid variable name | An error occurred while evaluating value_expression, or the variable name is invalid. The error port carries an error object with message and code fields. If no error handler is connected, the workflow halts. |
What Gets Written to Memory
Variable Assignment does not produce a traditional node output object. Instead, it writes directly to the workflow's execution memory store (a key-value map scoped to the current run). The written entry is then accessible to all downstream nodes.
Memory vs. Node Output
Variable Assignment has no output.* object — it does not produce node output data. The sole side-effect is writing to var.* memory. To access the value downstream, always use var.variableName, not output.NodeName.*.
Referencing Variables Downstream
| Expression Syntax | What It Does | Example |
|---|---|---|
{@ var.variableName } |
Reads the current value of a workflow variable by name | {@ var.invoiceTotal } → 1234.56 |
{@ var.myObj.property } |
Reads a nested property from an object stored as a variable | {@ var.customer.address.city } → "Austin" |
{@ var.myArray[0] } |
Reads an element from an array stored as a variable | {@ var.lineItems[0].amount } → 99.99 |
{@ var.counter + 1 } |
Performs arithmetic on a numeric variable inline | Useful in loop accumulators without needing a separate CodeExecute node |
Example: Memory State After Two Assignments
After running two Variable Assignment nodes sequentially:
// Node 1: AssignCustomerId
// variable_name: "customerId", value: "CUST-7891"
// Node 2: AssignOrderTotal
// variable_name: "orderTotal", value_expression: "{@ $input.current.subtotal + $input.current.tax }"
// Resulting workflow memory:
{
"customerId": "CUST-7891",
"orderTotal": 582.40
}
// Any downstream node can reference:
// {@ var.customerId } → "CUST-7891"
// {@ var.orderTotal } → 582.40
Error Output Schema
When the error port fires, the following object is available via output.NodeName.error:
{
"error": {
"code": "EXPRESSION_EVAL_ERROR",
"message": "Failed to evaluate value_expression: undefined variable 'missingVar'",
"node": "StoreInvoiceTotal",
"timestamp": "2026-05-23T10:34:12Z"
}
}