Branches and decision trees
Most automations don’t run a single sequence — they run different sequences depending on what’s true. Branches are how the automation chooses.
A rule has one trigger but can have many branches. Each branch has its own condition group and its own ordered list of actions.
The four branch types
- Always — Every time the rule fires, regardless of conditions
- If — Its condition group evaluates to true
- Else if — Prior branches didn’t match, and its own condition is true
- Else — Nothing above matched
Branches are evaluated top to bottom. The first If or Else if that matches runs its actions; subsequent branches do not. Always branches always run, regardless of what else matched. Else runs only if no preceding If / Else if matched.
The shape of a typical decision tree
A “route by customer tier” rule might look like this:
TRIGGER: Conversation created
BRANCH 1 — Always
Action: Add tag "auto-routed"
BRANCH 2 — If: customer level is VIP
Action: Assign team = Premium
Action: Add tag "VIP"
BRANCH 3 — Else if: subject contains "billing"
Action: Assign team = Billing
BRANCH 4 — Else
Action: Assign team = General
When a new conversation arrives:
- The “auto-routed” tag is added on every run (Always).
- VIPs go to Premium and get tagged.
- Non-VIPs whose subject mentions billing go to Billing.
- Everything else goes to General.
Common patterns
Tier-based routing
Use If for the highest priority case, Else if for the next, Else as the fallback. See VIP routing recipe.
One-hot escalation
Use a single If when the rule should only do something in a specific situation. No need for Else.
Side-effect plus main path
Pair an Always branch (logging, tagging) with downstream If/Else branches that do the work.
When to split into multiple rules instead
Branches keep related logic in one place — but if you find yourself with five or six branches all doing wildly different things, it’s often clearer to split into separate rules with their own triggers and conditions. Some heuristics:
- If two branches use unrelated trigger fields (one matches on tags, another on customer level), you may be conflating two rules.
- If two branches need different throttling or schedule restrictions, they have to be split — those settings are per-rule, not per-branch.
- If you can’t describe the rule’s purpose in one sentence, it’s probably more than one rule.