Working with Variables

Variablesvariables - Variables allow you to collect data and use it to make routing decisions. It includes, for example, information collected via IVR menus or via data dips into the account’s CRM system. Once added in a step, a variable can be reused in another step. Variables for Callbar can be managed through the 'Manage context' menu. can be used in multiple locations in a Studio flowFlow - Actions performed during the lifecycle of a call. to collect data points that will be used to make routing decisions.

Each componentcomponent - Components are the basic building blocks of a call flow. There are multiple components available that you can add and configure to suit your needs. Check the full list of available components in the "Studio Components" section of this guide. may expose “step variables” or data points from which the variables can be created when clicking on the dropdown and then on Create variable:

These variables can later be used to initialize or update some flow variables.

For example, the ​ Incoming Call component exposes 7 data points (contact details, source, and dialed phone numbers).

Another example is the ​Standard IVR​ component, which collects the keys pressed by the caller and populates the "selection" variable; it also populates the “exit_name” variable, whose value retrieves the name of the exit assigned to the selected key press.

These variables can then be used in other componentscomponents - Components are the basic building blocks of a call flow. There are multiple components available that you can add and configure to suit your needs. Check the full list of available components in the "Studio Components" section of this guide..

How to write the name of a new variable:
• Do not use spaces. You can use an underscore and numbers instead.
• Write all letters in lowercase.
• Do not use accents, apostrophes, or other special characters.
• Add an underscore before the number, if you are using letters and numbers to name a context variable.

Example: case_1

When used in a text field, the syntax to reference a variable is:

%{current_flow.variable_name}

Using the example above, the syntax would be:

%{current_flow.case_1}

For example, you can use a variable in the Play Audio component to play a customized greeting message.

The variable can be initialized from the initial component (Incoming Call) or via a data dipdata dip - Data dips are search points that collect data from external platforms (like a CRM) or within the call flow. For example, if you ask a caller to input their customer number, this number will be verified against a database. in your CRM system.

📘

Note

Please keep in mind that an underscore should be placed before the number in case you are using letters and numbers to name a variable that will later need to be referenced (in a query, for example).

Additional Resources: