Conditional Router
Route messages based on flexible text comparisons, enabling smart branching in your workflows.

Component description
How the Conditional Router component works
Conditional Router
The Conditional Router is a flow component designed to direct the flow of messages based on customizable text comparison logic. This makes it a powerful tool for branching processes, enabling dynamic decision-making within your AI workflows.
What the Component Does
At its core, the Conditional Router examines a piece of input text and compares it against a specified match value. Based on the result of this comparison (using a chosen operator, such as “equals,” “contains,” or “is empty”), the message is routed down one of two possible paths: the True Route or the False Route. This allows your workflow to automatically handle different scenarios based on message content or structure.
Inputs
The Conditional Router accepts several parameters to configure its behavior:
Input Name | Type | Description | Required | Advanced |
---|---|---|---|---|
Input Text | String | The primary text input for the operation. | No | No |
Match Text | String | The text input to compare against. | No | No |
Operator | String | The operator for comparing the texts (see below). | No | Yes |
Case Sensitive | Boolean | Whether the comparison should be case sensitive. | No | Yes |
Message | String | The message object to pass through on either route. | No | No |
Available Operators:
equals
not equals
contains
starts with
ends with
is empty
is not empty
is_url
is_email
is_number
This wide choice of operators enables sophisticated routing logic, such as matching by substring, checking for empty inputs, or validating the format of a URL/email/number.
Outputs
The component provides two output paths:
- True Route: Activated when the comparison evaluates to true. The original message is passed through this output.
- False Route: Activated when the comparison evaluates to false. The original message is passed through this output.
Both outputs are of type “Message,” ensuring compatibility with downstream components in your workflow.
Use Cases and Benefits
The Conditional Router is especially useful for:
- Branching Logic: Directing messages to different components or actions based on their content.
- Validation: Filtering messages that meet specific text criteria (e.g., emails, URLs, non-empty fields).
- Personalization: Customizing the flow of user interactions depending on user input.
- Automation: Automating responses or actions for certain keyword triggers or message patterns.
By integrating this component into your workflow, you can build highly responsive and adaptable AI processes that react intelligently to a wide range of input scenarios.
Frequently asked questions
- What does the Conditional Router component do?
It evaluates input text against a defined value using operators like equals, contains, or is empty, and sends the message down different paths based on the result.
- Which comparison operators are supported?
Operators include equals, not equals, contains, starts with, ends with, is empty, is not empty, is_url, is_email, and is_number.
- Can I make the comparison case sensitive?
Yes, you can enable or disable case sensitivity for your comparisons.
- How can I use Conditional Router in my workflow?
Use it to create logic branches—such as sending users to different responses or actions based on their input, making your automation more interactive and responsive.
- Is Conditional Router suitable for non-developers?
Absolutely! It’s designed to be user-friendly, letting you set up advanced routing logic without coding.
Try Conditional Routing in FlowHunt
Design smarter, adaptive workflows with the Conditional Router. Start building decision-based flows today.