Teneo Developers

Global Variables


Global Variables, as opposed to Flow Variables, are accessible by all Flows in a solution and have an unlimited validity, meaning that Global Variables can hold data that is persistent during the session and only expires when the session ends or times out. Variables get their values from Listeners, and hence the Variables and Listeners are closely connected: a Variable with an empty value must be declared so that a Listener can access it in its operation, and therefore when a Listener's TLML Syntax is fulfilled (usually when a certain user input is found), the script of the Listener is able to assign a certain value to the Variable.

View of Global Variables

The Global Variables are available in the backstage of Teneo Studio by clicking the Solution tab in the main window of Teneo Studio, then Globals and lastly Variables.

Global Variable view

In this view, the user will find:

  • Left side:
    • Text filter
    • List of existing Global Variables
  • Right side:
    • Ribbon options allowing to Edit, Search, Delete, view History, set/unset Stable version, include/exclude in branching (Localization setup); read more in the Edit section below
    • Details of the selected Variable providing a read-only summary
    • Global Variable's Id

The Global Variables are available on the Solution dashboard in the Globals tile; clicking the right-pointing arrow takes the user to the list of Global Variables.

View of Global Variables

In this view the user will find:

  • The list of existing Global Variables (if any)
  • Option to order the list per column header
  • Create button allowing to create a new Global Variable
  • Text filter available in the top ribbon



In the Global Variables section in the backstage of Teneo Studio (Solution tab > Globals > Variables), simply follow the below steps to create a new Global Variable:

  • Click Add next to the text filter
  • In the right side of the screen, write a Name and optionally a Description
  • Next, provide the Value of the variable
  • Click Save in the top to preserve the changes.

To create a new Global Variable, follow the below steps:

  • First, either:
    • Click the Create button next to Variables in the Globals tile on the Solution dashboard, or
    • In the Global Variables list, click on Create New Global Variable

Create New Global Variable

  • The Edit global variable opens, now give the Global Variable a Name and optionally write a description
  • Write the Variable value in the last field
  • Click Create
  • Next, optionally write a comment and click Save again to confirm the addition of the new Global Variable.


In the list of Global Variables:

  • Select the Variable to edit
  • Click Edit (right side of the screen above the Variable's summary)
  • Now, update the Name, Description and/or Value as needed
  • Remember to Save the changes when done, or alternatively click Cancel to discard the changes and exit the edit-mode.

Below please find an overview of more editing options available in the ribbon when working with Global Variables.

ButtonCommentMore information
EditAllows to open the Global Variable in edit-mode
Search - Search by Variable NameAllows to search through all places a variable can be used when referenced by name, for example, in scripts, Output Answers, etc.
Search - Search by Variable ReferenceAllows to search through trigger/transition Match requirements and After Match actions, Flow Link and Integration transfer Variables
DeleteProvides the option to delete a Global VariableDelete Global Variable
HistoryOpens the History of the selected Global Variable; previous versions and revisions of the Global Variable are listed, comments added at save are also displayed here. Select any of the revisions to view its content.Set a previous version as stable by selecting it in the list and clicking Set Stable, restore a previous version by selecting it and clicking Restore.Version flag
Set/unset stableSet the current version of the selected Global Variable as stable or unset itVersion flag
Include/ExcludeInclude or Exclude the selected Global Variable from branching when working in a Localization setupLocalization setup

To edit a Global Variable, follow the below steps:

  • Go to the list of Global Variables (Solution dashboard > Globals tile > Variables)
  • In the list, select and click the Variable to edit
  • Now, in the Edit Global Variable view, perform the needed modifications
  • Remember to Save the Variable to preserve the changes.


When a Global Variable is in edit-mode, the Save button becomes available in the ribbon above the details of the Variable itself; click Save to save with comment or alternatively press Alt and click Save to bypass the comment.

To save a Global Variable in edit mode, follow the below steps:

  • Click Save at the bottom of the Edit global variable view
  • Optionally add a comment for the Version History
  • Click Save again to confirm.

The Save button only becomes clickable in the Edit global variable view when changes are performed to an already existing Global Variable or if the Global Variable has not been saved earlier

Successful save is confirmed with a "Document saved successfully!" message; by clicking elsewhere in the browser window the message is closed.


In Teneo Studio Desktop, the view of a Global Variable in edit mode is closed by either clicking Cancel or Save to preserve any possible modifications.

To close a Global variable without modification simply click the x in the upper right side of the Edit Global Variable view; to close with modifications click Save.


To delete a Global Variable, follow the below steps:

  • Select the variable(s) to be deleted, multi-select is available by pressing Ctrl while selecting.

  • Click Delete in the top-area of the screen.

  • Note that the right-side of the screen will now display an Variable delete pending view, which the user should either Cancel or Apply for each of the selected variables for the actual deletion to be performed.

If Teneo Studio detects that the Global Variable is in use, the user is prompt to confirm a Force delete or Cancel the deletion.

To delete a Global Variable in Teneo Studio Web, follow the below steps:

  • Navigate to the list of Global Variables (Solution dashboard > Globals tile > Variables)
  • Hovering over the Variable in the list, an icon of a recycle bin appears in the right side of the browser window, click on it
  • The user is prompt to confirm the deletion of the Global Variable:
    • Click Delete to perform usage check before deletion
    • Check Do not check usage and click Delete to delete without performing a usage check
    • Click Cancel to abort the deletion.

Read more about deletion and usage check

Note that deletion of a Global Listener currently cannot be undone in Teneo Studio Web, for this action please refer to the Recycle Bin available in Teneo Studio Desktop.


A text filter is available at the top of the list of Global Listeners; to filter on the available variable, simply writhe the wanted letter combination to start filtering on the list.

A text filter is available in the top ribbon of Teneo Studio Web which allows to filter on the displayed list of documents; simply write the wanted letter combination to start filtering on the list.

The filter works on the following columns: Name, Description, Value, Author.

Clicking the column headers allows to sort the list of documents alphabetically when clicking the Name, Description, Value or Author header; when clicking Updated it is possible to sort by the date/time the documents were updated or created.


Naming conventions

Variables are placeholders for changeable values and can be used to store text strings, Boolean, Lists, Maps (key/value pairs) and numbers. Each Variable in a solution needs to have a unique name and the following conventions are recommended:

  • Start the Variable name with a lowercase character indicating the type of information the Variable contains:
    • s (string)
    • b (Boolean)
    • n or i (numbers)
    • l (list)
    • ss (list containing strings)
    • bb (list containing Booleans)
    • nn or ii (list containing numbers)
    • m (maps)
  • When using multiple words in the name, the word should be concatenated with no separating character between them
  • The first letter of each word should be capitalized

Examples: sUserName, sCompanyName, nHour, iMonth

Global Variables coming with Teneo Conversational Modules are prefixed with Lib_