> For the complete documentation index, see [llms.txt](https://docs.mediarithmics.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mediarithmics.io/audience-and-activation/automate/automations-reference/flow-control.md).

# Flow control

Wait, If and Split, and the exit conditions that can remove a user from anywhere in the flow.

## What flow control is

**Flow control** components alter the natural flow of an automation. They are in the Automation Components drawer on the right of the builder: drag the one you want into the path of your automation, then configure it. Click a component later to edit its configuration or remove it.

## The three components

<table data-search="false"><thead><tr><th width="130">Component</th><th>What it does</th><th width="230">Configuration</th></tr></thead><tbody><tr><td><strong>Wait</strong></td><td>Halts the flow for a specified interval of time.</td><td>The interval, plus optional opening hours and days</td></tr><tr><td><strong>If</strong></td><td>Creates a condition check point, with a true path and a false path.</td><td>A query, in the Advanced Segment Builder interface</td></tr><tr><td><strong>Split</strong></td><td>Divides the flow into several branches in equal proportions.</td><td>The number of branches</td></tr></tbody></table>

## Wait

The Wait component halts the flow for the interval you specify.

You can also configure "opening" hours and days, so the flow is held until a reasonable time is reached - which is how you avoid sending text messages in the middle of the night.

{% hint style="warning" %}
Two things a wait interacts with, both documented elsewhere and both easy to forget:

* A user sitting in a wait node **cannot re-enter the scenario**. See [Re-entry](/audience-and-activation/automate/automations-reference/triggers.md#re-entry).
* Wait nodes are the subject of two [usage limits](/audience-and-activation/automate/automations-reference.md#usage-limits) - 20 wait nodes across active scenarios, and an indicative 50,000 users awoken per wait node per hour.
  {% endhint %}

## If

The If component creates a condition check point. If the condition is verified the user proceeds to the **If Condition True** path; if not, to the **If Condition False** path.

It uses the same interface as the [Advanced Segment Builder](/audience-and-activation/build-your-audiences/segment-reference/segment-builders/advanced-segment-builder.md), which is why the objects, field conditions and frequency options available to you are the ones documented there rather than a separate set.

{% hint style="info" %}
**Worked through.** Configure the If node with a query for at least one `$basket_view` event, and the logic becomes:

* The user arriving at this node **has had** at least one `$basket_view` event in the past: move on to **If Condition True**.
* The user has not: move on to **If Condition False**.
  {% endhint %}

## Split

The Split component divides the automation flow into several branches, in **equal** proportions.

{% hint style="info" %}
Split into 2 branches and 1 user out of 2 goes down branch A, the other down branch B. There is no weighting - the flow is always divided equally between the branches you configure.
{% endhint %}

{% hint style="danger" %}
A Split component **cannot be edited after the scenario is created**. Decide the number of branches before you save.
{% endhint %}

## Exit conditions

An **exit condition** is a condition that, if verified at any moment during the automation, makes the user exit the automation **regardless of their current position in it**.

Add one with the **Add Exit condition** button in the bottom right corner of the builder. The node configuration lets you choose which events cause the user to exit.

{% hint style="info" %}
Exit conditions are the counterpart to the [re-entry rule](/audience-and-activation/automate/automations-reference/triggers.md#re-entry). A user who leaves through an exit condition becomes eligible to enter the scenario again; a user still travelling through it does not. In a cart-abandonment scenario, the exit condition on a confirmed transaction does two jobs at once: it stops the reminder, and it releases the user for next time.
{% endhint %}

## Related pages

<table data-view="cards" data-search="false"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>Cart abandonment automation</strong></td><td>Wait plus exit condition, worked end to end.</td><td><a href="/audience-and-activation/automate/cart-abandonment-automation.md">Cart abandonment automation</a></td></tr><tr><td><strong>Lifecycle, testing &#x26; analytics</strong></td><td>Reading the per-node counters, including on exit conditions.</td><td><a href="/audience-and-activation/automate/automations-reference/lifecycle-testing-and-analytics.md">Lifecycle, testing &amp; analytics</a></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.mediarithmics.io/audience-and-activation/automate/automations-reference/flow-control.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
