Condition
Legacy component
Condition is a legacy component. Use the If-Else component instead.
The Condition component routes Data objects based on a condition applied to a specific key in the data. It checks the value of a named key in each Data object and routes it to either the True Output or False Output port.
Unlike the If-Else component, which operates on text messages, Condition works directly on Data objects and their key-value pairs.
Supported operators
- equals: Value matches exactly.
- not equals: Value does not match.
- contains: Value contains the match text.
- starts with: Value begins with the match text.
- ends with: Value ends with the match text.
- boolean validator: Treats the value as a boolean. Values like
true,1,yes,y, andonevaluate to true.
Condition parameters
Some parameters are hidden by default in the visual editor. You can modify all component parameters through the component inspection panel that appears when you select a component.
| Name | Type | Description |
|---|---|---|
| Data Input | Data | Input parameter. The Data object or list of Data objects to evaluate. |
| Key Name | Text | Input parameter. The key in the Data object whose value is evaluated. |
| Operator | Dropdown | Input parameter. The comparison operator to apply. |
| Match Text | Text | Input parameter. The value to compare against. Not used when the operator is boolean validator. |
| True Output | Data | Output parameter. The Data object(s) for which the condition evaluated to true. |
| False Output | Data | Output parameter. The Data object(s) for which the condition evaluated to false. |