Compare
condition.compare
SF Symbol:
arrow.triangle.branch
The Compare node evaluates a condition against the incoming payload and routes execution to either the Yes or No outlet. This is the primary branching mechanism in Watchflows.
Ports
Inlet
Input
Accepts any payload type. The payload is evaluated against the configured condition.
Outlet
Yes (any)
Fires when the condition evaluates to true. Passes the original payload through unchanged.
Outlet
No (any)
Fires when the condition evaluates to false. Passes the original payload through unchanged.
Configuration
A Condition can hold multiple rules, each with its own field, operator, value, and a NOT toggle. Rules combine with AND (all must match) or OR (any may match), and a case-insensitive option applies to text comparisons. The table below describes a single rule.
| Field | Type | Default | Description |
|---|---|---|---|
field |
dropdown (variable picker) | — | Payload field to compare, chosen from a dropdown of variables published by upstream nodes — no hand-typing of key names. To compare a nested field, choose Custom key… and type the dot-notation path (e.g. body.message). |
operator |
dropdown | equals |
Comparison operator. See operators table below. |
value |
text | — | Comparison value. Supports {{variable}} interpolation. |
Operators
| Operator | Description |
|---|---|
equals |
True when the field value exactly matches the comparison value (case-sensitive). |
not_equals |
True when the field value does not match the comparison value. |
contains |
True when the field value contains the comparison value as a substring. |
starts_with |
True when the field value begins with the comparison value. |
ends_with |
True when the field value ends with the comparison value. |
greater_than |
True when the field value is numerically greater than the comparison value. Both values are coerced to numbers. |
less_than |
True when the field value is numerically less than the comparison value. Both values are coerced to numbers. |
matches_regex |
True when the field value matches the comparison value interpreted as a regular expression. Note: {{variable}} content is spliced into the pattern verbatim — metacharacters like parentheses or dots act as regex syntax, and an invalid resulting pattern evaluates to No. |
is_empty |
True when the field value is empty, null, or missing. The value field is ignored. |
is_not_empty |
True when the field value is present and non-empty. The value field is ignored. |
Output Variables
Passthrough — The Compare node inherits all upstream variables. The incoming payload is forwarded unchanged to whichever outlet fires. No new variables are added.
Example Workflow
Route incoming webhook requests based on HTTP method. POST requests are forwarded to an API, while all other methods trigger a notification.