All nodes/Data/Values & State
Template
Builds text from a template with values substituted from other nodes: {{nodes.llm_1.output}}, {{inputs.message}}. Used to compose prompts, messages, and strings from dynamic data.
Type in the graph: template
Exec
An error output can be enabled to handle failures on their own path.
Ports can be split into separate execution and data handles.
Try it
Minimal working scenario
- Execute + Data
Runs as pasted
When to use it
Template is the node for anything whose output has to be text: a prompt for a model, a reply to the user, a request body, a key to store something under. It assembles one string from values that live in different nodes and variables.
You do not always need a separate node: many text fields on other nodes (a prompt, a message body) understand the same substitution syntax. Reach for Template when the assembled text is consumed by several nodes, when the assembly is a step in its own right that you want to see in the run log, or when the text must be built before it reaches a node that has no templatable field.
How it works
The same namespaces are available as in any other templatable field:
{{ inputs.input }}— the value that arrived at the Input port. This is also the default template: a freshly dropped node simply passes the value through.{{ nodes.<id>.output }}— the result of any node that already ran, addressed by its id.{{ variables.<name> }}— session variables declared by Variable nodes.{{ var }}— the value of the Var node wired into the Variable port; this is also how thread-scoped variables are read.{{ loop.* }}— the current iteration’s data when the node sits inside a loop.
Template conditions and loops ({% if %}, {% for %}) work, as do filters such as
| default("—") or | join(", "). The node has no execution input: it is either triggered
through the Input port, or its value is pulled by a consumer over a data edge.
Common mistakes
- An empty template is rejected. It would return an empty string and throw the incoming
value away, so the run stops with a message saying the template text is required. If you
want the node to pass things through, leave
{{ inputs.input }}in place. nodes.<id>is the node id, not its label. A reference to an id that does not exist renders as nothing; the validator warns about it and suggests the closest real id.- The result is always a string. Even when the expression evaluated to a number or an object, what travels downstream is text. If the consumer needs an object, route the value around the template or parse it further with another node.
{{ variables.X }}only sees session variables. Read a thread-scoped one through the Variable port ({{ var }}) or through{{ nodes.<id>.output }}of the Var node.
Inputs
| Port | Wire | Payload | Notes |
|---|---|---|---|
Inputinput | Execute + Dataexecute_data | — | Run trigger and context for {{inputs.input}} in the template |
Variablevar | Datadata | — | Optional: connect a Var node for {{var}} in the template |
Outputs
| Port | Wire | Payload | Notes |
|---|---|---|---|
Valueoutput | Execute + Dataexecute_data | object |
Configuration
| Field | Type | Default | Description |
|---|---|---|---|
Templatetemplate | string | {{ inputs.input }} | Use {{var}}, {{nodes.id.output}}, {{inputs.handle}}. Connect a Var node to the Var handle for stateful context. An empty template returns an empty string and drops the incoming value. supports templates |
Shared fields
Every node has these three — the platform adds them, not the node author.
expose_error_output— When enabled, show an execution output to connect nodes that run if this step fails.split_ports_in— Show separate execution and data input handles instead of one combined port.split_ports_out— Show separate execution and data output handles instead of one combined port.
Ready-made examples using this node
- The agent calls your own scenario as a tool
- A customer books an appointment in the conversation
- The bot tells a customer when you are free
- A reminder an hour before, and exactly one
- A chat message is written into the amoCRM deal
- The bot calls a human when it cannot cope
- Primary is down, try the backup; both down, call a human
- What your documents are missing collects itself
- Mark the habit, the bot keeps the streak
- Every conversation lands in a table as a summary
- A request routes itself to the right team
- A long text edited in pieces
- An email from a customer, an answer from your documents
- A request from the inbox becomes a row in a table
- A digest across a batch of documents
- A recording of a stand-up becomes minutes with tasks
- One summary for every address
- One scenario answering in every channel
- An order that lives in a table between runs
- Send a link, get a summary that stays in your base
- A photo of a receipt becomes a line of spending
- “Remind me on Friday”, and on Friday it does
- Reviews sorted by tone and topic
- A second brain: throw thoughts in, ask in your words
- A shopping list the bot keeps for you
- An agent answer in your own format
- A form request, parsed and filed
- Any service can now write to you in Telegram