Understanding the Conditional branch node for Automate flows
The Conditional branch node allows you to split your flow into different paths based on specific criteria. This helps you create more dynamic Automate flows by applying different actions depending on customer, subscription, or order details.
This guide explains how to use conditions in the Conditional branch node for Automate flows, along with common use cases and considerations.
- Shopify Checkout Integration
- Migrated Shopify Checkout Integration
Before you start
- This article only applies to Automate flows. Conditional logic for other flow types may differ. See Understanding the Conditional branch node when building flows for more information.
How it works
Conditional branch nodes are used after a flow has already been triggered. Unlike the Trigger node, which controls which orders can enter a flow, the Conditional branch node determines which path the flow follows next based on the conditions you define.
As you plan your conditions, consider:
- What decision the flow needs to make (for example, whether a customer is tagged VIP)
- Which order, subscription, or customer details should determine the path
- Whether the logic belongs in the Trigger node instead of a branch node
The Conditional branch node evaluates the conditions you set and routes the flow down different paths.
Each branch represents a possible outcome:
- If conditions are met, the flow follows that branch
- If conditions are not met, the flow continues to the next branch or default path
Conditional branch nodes help you:
- Customize actions based on customer, subscription, or order details
- Build flexible automations with more precise logic
Conditional branch nodes also help you avoid:
- Overusing trigger conditions for logic that belongs later in the flow
- Complex branching patterns that are harder to maintain
Configure conditional branches
You can add and edit conditional branch nodes directly in the flow canvas.
- In your Recharge merchant portal, click Products and select Automate.
- Create a new flow from a template, or open an existing, inactive flow.
- Click on the Conditional Branch node, or drag the node from the Add a node menu.
- Click the pencil icon to update the branch.
- Set your conditions.
- Add additional branches as needed.
- Save your changes.
Each branch can contain its own sequence of actions depending on the conditions you set.
Use AND/OR logic to fine-tune branching
Conditional branch nodes support AND and OR logic, so you can create precise decision paths:
- Use AND when all conditions must be met.
- Use OR when any of the condition groups can be met.
Example:
(Customer tag equals VIP) AND (Processed charge total price is greater than 50)
OR (Line item contains Subscription A)
Available conditions
Conditional branch conditions include options for targeting customers, subscriptions, processed charges, and shipping details.
For a complete list of all available conditions, see Available conditions for Automate flows.
Common condition types include:
- Subscription conditions: Target specific subscription details such as product, interval, or order milestones
- Customer conditions: Target customers based on attributes such as tags, segments, or subscription activity
- Processed charge conditions: Target order-level details like charge date, total price, or discount code
- Processed charge line item conditions: Target specific products or variants within a processed charge
- Shipping address conditions: Target orders based on the delivery location
Use cases
The examples below reflect common Automate actions available in the canvas.
Use case |
Conditional logic and canvas actions |
|---|---|
| Offer different actions for VIP customers |
Branch condition: Customer condition: Customer tag matches VIP Canvas actions: Use one branch to apply a VIP-specific action, and use the else path for standard customers. |
| Apply different delays based on product |
Branch condition: Processed charge line item condition: Variant equals Canvas actions: Use one branch with a shorter Delay node, and another branch with a longer Delay node before updating the subscription. |
| Split flows by order value |
Branch condition: Processed charge condition: Total price is greater than the threshold you want to target Canvas actions: Use one branch for higher-value orders and another for standard orders. |
| Handle first-time and returning customers differently |
Branch condition: Customer condition: Number of subscription orders processed Canvas actions: Use one branch for first-time customers and another branch for returning customers to tailor the next action. |
Considerations
Consider the following when using the Conditonal Branch node for Automate flows:
Consideration |
Details |
|---|---|
| Branch order matters | Conditions are evaluated in sequence. Place more specific branches before broader ones when needed. |
| Include a fallback path | Make sure the flow accounts for cases where none of the branch conditions are met. |
