Switch Nodes
Route a workflow down different paths based on a value. Whether you’re routing support tickets by category, handling order statuses, or choosing a follow-up action based on the sentiment expressed in a message, a Switch node keeps your routing logic in one place.
With a Switch node, you can:
Compare a value from a previous node against multiple cases.
Give each case its own output path.
Follow the first matching case.
Use a default path when no case matches.
Configuration guide
The Switch node has three main parts: the value to watch, the cases to match, and a default path.
Add cases
Each case defines a value to match and the next node to run.
Enter the value to compare against in Matches value.
Select the next node from the dropdown, or connect the case’s output on the canvas.
Click Add case to add another possible path.
For example, if your watched value is a ticket category, you could add separate cases for Billing, Technical support, and Account access.
Each case needs a destination. To remove a case, click the remove button next to it.
Set the default path
Default (no match) determines what happens when the value does not match any of your cases.
Select a next node to handle unmatched values, or leave End flow selected if no further action is needed.
A default path is useful for handling unexpected values or categories that do not need their own case.
Example: Route by message sentiment
An LLM node analyses the sentiment expressed in an incoming support message and returns a sentiment field with one of three values: Positive, Negative, or Neutral. A Switch node uses that value to route the message to an appropriate support action.
Add a Switch node after the LLM node.
Set Value to watch to the LLM’s
sentimentfield.Add the following cases and connect them to the appropriate action nodes:
Positive
Send a thank-you message
Negative
Escalate to a support agent
Neutral
Route to general support
Set Default (no match) to a general support action for any other value.
When the workflow runs, a value of Negative follows the escalation path. The other case paths are not run.
Node outputs
The Switch node displays a separate output connection for each case, plus a Default (no match) output.
Case output
The watched value matches that case, and no earlier case has matched.
Default (no match)
None of the cases match.
Connect each output to the next step you want the workflow to take.
Last updated
Was this helpful?

