Scripts

In the Studio application, a script is a network of actionsClosedPerforms a process within a Studio script, such as collecting customer data, playing a message or music, or routing a contact to an agent. that route and manage customer traffic for a contact center. For example, if a customer calls into a contact center, the customer will interact with an inbound phone script that might ask for specific information like an account number or will direct the caller to the appropriate department based on their reason for calling. Each action in the script has a specific purpose, such as determining skills or variables, playing on-hold music, or attaining (and passing along) customer information like a name, address, or account number. Actions link together via connectors that determine possible "pathways" or branches for a customer to navigate through the script, such as a Menu action providing options for speaking with an agent in different departments. Scripts can have basic designs, such as only routing a phone contact directly to an agent, or more complex designs that could include various branches that end in different actions based on a wide variety of parameters.

The basic workflow for developing a script is to drag and drop actions from the Tools or Framework tabs onto the canvas (which is the blank, open space in the interface), then connecting the actions to determine the possible pathways of the call flow. After creating the basic structure of actions, you can configure each action further by adding additional parameters or uploading prompts to be played.

You can schedule scripts to run through the CXone platform, see Script Schedules for more information.

For information on the Scripts page on the CXone platform, see the Scripts Page.

Scripting Interface Elements

The preceding image provides a look at the Studio user interface. The large center pane is the primary work area, called the canvas, where you will place and interact with actions to create your script. Studio offers a variety of tabs, or windows, that you can open and arrange in the panes around the canvas that provide access to the components you need to create and manage scripts. In this image, the Tools tab appears in the pane on the right, the Navigate tab appears on the left, and the Script Errors tab appears beneath the canvas. You can click and drag actions from the Tools and Framework tabs (in the right-pane of the image) onto the canvas to build a script (the Framework tab must be specifically enabled by an internal administrator).

Script Types

You can create a specific type of script that correlates with the different channels in your contact center, which are shown below:

Generic Email Chat Phone Voicemail Work Item SMS

When creating a new script, Studio prompts you to determine the type of script that you want to create. The type of script you choose must correlate with the type of routing (or other task) that you wish to achieve; most actions function in any script type, however, some can only be added to a specific script (for example, ASRClosedAutomatic Speech Recognition; allows contacts to respond to recorded voice prompts by speaking, pressing keys on their phone, or a combination of both. actions function with phone scripts). If you try to use an action from the Framework tab that is not compatible with the script type that you are creating, Studio displays an error message. Additionally, actions that are not compatible with a certain script type will not appear in the Tools tab of that script.

In addition to these main script types, Studio offers a few script templates depending on the features and applications you have enabled with your system, such as the call suppression script related to Personal Connection. If you have access to these templates, they are accessible in the Available Templates section of the Create New Script dialog.

Connectors and Branches

Connectors

A connector is an individual connection between two actions. It displays as an arrow and determines the possible movement of a contact from one action to the other, plus the condition for a contact following that connector. You can connect 2 actions by clicking the bottom-right corner of an action and dragging and dropping the connector to the next action in the flow. To help keep your script clean and organized, you can bend connectors by pressing and holding CTRL and SHIFT on your keyboard, hovering over the connector so that it turns blue, right-clicking on the connector to place a green box (which will be a pivot point), then left-clicking the green box and maneuvering the connector as desired. You can place multiple pivot points along a single connector for even more custom maneuvering.

Branches

A branch is a path that divides a script into 2 or more subdivisions, which begins with a single connector. Many actions contain default branch options for you to configure, such as Default or OnError, but you can also create custom branch conditions (called Variable Branch Conditions) when the PickBranch window appears after connecting 2 actions. The preceding image in the drop-down displays a basic example of 3 branches and connectors: info, billing, and tech support. The first connectors of each branch are labeled and also show the 3 menu options. Many scripts will be much more complex than shown in the example with more fleshed-out branches. If branches become too complex and extensive to intuitively fit onto 1 canvas, the scripter could separate branches into individual sub-scripts, then reference the sub-scripts from the main script using a Runsub or Runscript action. This is an excellent way to keep your scripts organized and tidy instead of large, cluttered, and confusing.

For example, in the following script images you can see the Yggdrasil Menu provides 8 options for the 8 other Nordic worlds, with each world representing a different branch of the script. If Heimdallr, scripter for the Asgard Hotline, wanted to include more options for each branch that would make this single script overly complex, he could create a separate sub-script for each of the 8 other worlds. After doing so, Heimdallr would use a Runsub or Runscript action for each menu option that launches/references the separate script when selected by the contact.

Script APIs

For more advanced script developers, you can programmatically open and save scripts to assist with automated development processes. Expand the following drop-downs to view basic details for each API.

Scripting Tips & Tricks

  • Renaming the caption in an action can make your script much easier to read and follow. Edit an action's caption in the Properties dialog.
  • When using Menu (or a similar action), create a branch to repeat the menu options using the Loop and Noresponse actions that connect back to the Menu action.
  • Add a Wait action after a Music action to replay the music (otherwise the audio will play for 30 seconds then end).

  • Make sure you do not have a dead end. Dead ends could be issues such as missing branches in a menu, menu branches that are not configured, or (like in the preceding item) no Wait action after a Music action.
  • When creating a menu, it is best to name the department first and then the number to dial/speak. Contacts are usually listening for the department name and then the number.
  • Use the Annotation action to add notes or instructions throughout a script.
  • Use the name of the script for the Begin action caption.
  • For Play and Menu actions, double click the action and annotate the verbiage of the prompt in the Phrase field.
  • View a script's history by right-clicking on the script in the Browse tab (View Browser) and hovering over the History option. This allows you to view previous iterations of a script.