You can track the progress and performance of your script (and the actions within the script) through the Trace Output tool. This tool traces the contact through the script and displays the results of each action that fired, what variables are being set and when, and so forth. You can control several tracing functions from both the Studio toolbar or menu system, such as starting a trace or choosing to continually trace and capture each time the script fires. This page describes the trace output window, along with relevant actions you can take related to tracing scripts. Utilizing a script trace is an excellent method of testing and debugging your script. See the Simulate Interactions page for more information.
Errors also affect script traces. If you attempt to run a script trace on an unsaved script, Studio prompts you to save the script. If you have errors in the script, the script will not save and you might lose changes caused by validation errors. The trace will run, but it will run on the last saved version of the script.
Trace Output Tool
Click on a numbered area in the image below to learn more about that area's interface elements (displayed as a default layout).
This button provides options to display the following panels: (descriptions of these panels are in the table rows below)
You can also select Save Layout to save the layout of how you customized these panels for the next time you open the Trace Output window.
|Show||Click this button to display the following options:
|Watch||You can use these buttons to add or delete a variable to the Watch List. See the Add New Watch section below for more information.|
You can select one of the thee options to expand or collapse all the actions that contain additional information, or to automatically expand and scroll as the trace progresses through the script and actions with additional information fire.
|Contact ID||This area displays the contact ID and the script name.|
|Properties Panel||This panel displays the properties of the script being traced, such as parameters and configured branches.|
This area displays the result of each action that fires during the trace. If an action appears in the script, but does not fire during the trace, it will not appear on this list. If an action contains extensive details, you can expand that action's "event" in the list to view the additional details.
A trace might span more than one script. The left most column, entitled Script, indicates the script in which the action fired.
|Variables and Watch List Panels||
Variables — displays all of the variables that are returned throughout the script with their corresponding values.
Watch List — displays the list of variables that you specifically added for the purpose of observing changes to the variables (or their values) in one location while tracing the script. You can add variables to this list by using the Watch buttons in the Trace Output toolbar (see the Watch interface element above).
Trace with Specific ANI or DNIS
You can set a specific ANI Also known as caller ID. Listed phone number of an incoming voice call. or DNIS Identifies the number the contact dialed to reach you for inbound voice calls and the number the agent or system dialed on outbound voice calls. to fire a trace when a call from the specified number comes into the system. To target a specific number:
- Click the Trace Script drop-down in the Studio toolbar.
- Depending on which type of number with which you want to trace, select either Trace when ANI is or Trace when DNIS is. After selecting one of those options, a new field will appear next to the drop-down for you to enter the number.
- Enter the ANI or DNIS number into the Insert <number> field.
- Click the Capture Next Instance button once to trace the next instance of the script running with the specified number; the circle icon will turn red. You can click twice to continuously trace the future instances of the script running with the specified number, which changes the icon into two red circles. You can also click three times to clear the capture, which changes the circle icon back to blank (as shown in the preceding drop-down).
Add New Watch
A watch is a variable that you specifically want to track - or watch - in a trace. The Watch List allows you to observe variables from the trace in one short list instead of requiring you to search for the variable amidst all of the actions in the script details. To assist you in debugging a script and testing the performance, you can conveniently observe how the variable(s) change during the script as the IVR changes their values. To add a new watch:
- Run an initial trace of the script.
- Search for the specific variable(s) that you want to watch by clicking through the list of actions in the script details section; the variables associated with each action will appear in the Variables panel.
- Select the variable that you want to watch in the Variables panel and click the Add to Watch List icon in the toolbar (indicated by a pair of glasses). If you want to remove a variable from the Watch List, simply select it in the Watch List and click the minus button (—) in the toolbar.
After adding the desired variables to the watch list, you can trace the script again and observe the variables in the Watch List panel.