# Output (/docs/nodes/output)



The **Output** node is where a run ends. It builds the response field by field from the payload and the variables the flow computed, and that response is what the caller receives. Like Input, every flow has one and it cannot be deleted.

## When to use it [#when-to-use-it]

* Shape the answer: decide exactly which values leave the decision and under which names.
* Return the headline answer under the `decision` key, next to supporting values such as a score or reason codes.

## How it works [#how-it-works]

<Diagram node="output" kind="anatomy" />

1. For every entry of the **response mapping**, the node evaluates its expression against the payload and the variables.
2. Keys with dots build nested objects: `customer.id` becomes `{ "customer": { "id": ... } }`.
3. The result becomes the **outputs** of the run. The `decision` key is the headline answer and is also reported as the decision of the execution.
4. There is nothing after it: the node has no ports and the run ends.

## Ports [#ports]

The Output node has no ports. Reaching it ends the run.

## Configuration [#configuration]

| Field            | What it does                                                                                               |
| ---------------- | ---------------------------------------------------------------------------------------------------------- |
| Name             | Label shown on the canvas and in the trace.                                                                |
| Response mapping | Each output field and the expression that produces it. Dotted keys nest.                                   |
| Output model     | The schema that describes the response. It documents the contract; the mapping is what actually builds it. |

## What it writes [#what-it-writes]

It does not write variables. It produces the outputs of the run, and the trace records `Response assembled` with them.

## In a real flow [#in-a-real-flow]

<Diagram node="output" kind="example" />

A calculation derives a fee. The Output node maps it, together with the decision, into the response. The output model describes the same shape for whoever integrates with the decision.

## When it fails [#when-it-fails]

* An expression of the mapping fails: the run fails with `EXPRESSION_FAILED` and names the field.
* An empty mapping is only a warning, but callers would receive an empty response.

## Good to know [#good-to-know]

* A branch that ends at a port with no connection stops the run without reaching Output, so the outputs are empty. The Checks panel warns about every unconnected port.
* Several branches can converge on the same Output node.

## Related [#related]

* [Input](/docs/nodes/input)
* [Expressions](/docs/concepts/expressions)
