Skip to content

Loop

The Loop component runs a set of components over and over, either a set number of times or while a condition remains true. It is a good fit whenever a flow needs to replay the same steps, for example, offering a menu again or sending the caller back to an earlier point. This page covers what the component does, how to configure it, and which component can follow it once the loop ends.

The Loop component shown on the call flow canvas

  1. Drop the Loop component onto the canvas, then click it to open its settings.

    Opening the Loop component settings

  2. Choose a loop method, then click Confirm. The two methods are described below.

    Loop until the fixed count is reached

    Configuring the Loop component to repeat a fixed number of times

    1. In the Loop Method drop-down list, select Loop until the fixed count is reached.

    2. In the Count field, enter how many times the loop should run.

    Loop while condition is true

    Configuring the Loop component to repeat while a condition holds

    1. In the Loop Method drop-down list, select Loop while condition is true.

    2. In the Expression field, enter a function. For example, FX_EQUAL($Session.ani,"1001") enters the loop only when the caller ID is 1001.

  3. Click Add component inside the loop to add the components you want to repeat.

    Nesting a Loop component inside another loop

    The components you add appear inside the Loop component.

    Components placed inside the Loop component

A Loop component connects to exactly one component, which runs after the loop finishes. You can connect any of the following.

ComponentDescription
PromptPlays one or more audio prompts or a text-to-speech message to the caller. See Prompt.
Business HoursSends calls to different destinations depending on the time of day. See Business Hours.
MenuOffers callers a set of options and routes each call by the DTMF (Dual-Tone Multi-Frequency, the touch-tone keypad digit) key pressed. See Menu.
User InputCollects DTMF digits from the caller, often paired with Condition to evaluate what was entered and route the call. See User Input.
LanguageSwitches the system prompt language for the components that follow in the flow. See Language.
RecordStarts recording once the caller connects to another party, with optional prompts to announce recording at the start and while it runs. It can also turn recording off for calls that would otherwise be recorded. See Record.
Dial by NumberLets callers dial a number directly to reach their destination. See Dial by Number.
Dial by NameAn end component that closes the caller’s path through the flow, letting them reach an extension user by keying the first three letters of that user’s name. See Dial by Name.
TransferAn end component that hands the caller off to a chosen destination, with optional prompts to announce the transfer. See Transfer.
Hang Up CallAn end component that disconnects the call as soon as it is reached. See Hang Up Call.
ConditionBranches calls by evaluating logical expressions. See Condition.
LoopRepeats a group of components, either a set number of times or until a condition is satisfied. See Loop.
Internal Data OpsReads from and writes to the built-in PBX (Private Branch Exchange, the phone system) database. See Get Extension Presence Status, Set Extension Presence Status, Get Queue Agent, Get Queue Info, Get Agent Status, Set Agent Status, Get System Info, Get System Capacity, Get Extension Info, and Get Company Contact Info.
Email SenderSends email from within the flow for real-time notifications, alerts, or user-specific details. See Email Sender.
Database AccessRuns SQL operations against a database mid-flow to retrieve or update data. See Database Access.
HTTP RequestSends HTTP requests to external web servers to exchange data with third-party services. See HTTP Request.