ВОЙТИ

Debugging scenarios

cloud_debugger_vp

It's much easier to develop apps with the right tools. One of the important processes during any app development is debugging. Keeping in mind that call control logic is written in Javascript and usual web developers can build apps for Voximplant, we decided to create convenient debugger to let developers debug their apps in real-time right in a web browser. We called it call control debugger and it's now available at Voximplant control panel.

The debugger is available while you open a scenario in our cloud IDE. To open a scenario, go to the Applications section, click your target application, switch to the Scenarios tab, and click on a scenario. In the upper right corner, you will see a Debug button with a dropdown menu to set debugging parameters before the first run and adjust them as needed.

When you click Debug, a Debug parameters dialog will appear. If you click Use last settings, the debugger runs immediately.

Being in Debug parameters, you can should specify the rule for debugging purposes and one of the three debugging criteria, which are available in the dropdown:

  • Calls from specific IP address – the debugger will be connected to a session started by a call from the specified IP address.
  • Calls from specific phone number – the debugger will be connected to a session started by a call to/from the specified phone number.
  • All calls – the debugger will be connected to a session started by any call that matches the specified Rule.

The debugger will be launched after the Debug button click, you can see its interface on the image below:

The interface is very similar to Developer tools (like Firebug) for web browsers that are used to debug Javascript apps and contains Scripts, Watch Expressions, Call Stack, Breakpoints and Console sections. Functionality is also similar to JS debugger. The debugger will be waiting for a new session that matches specified parameters (Application, Rule, Criteria) to appear after pressing the 'START' button. If some breakpoint was specified script execution will be paused at the line with breakpoint and Controls can be used for step-by-step debugging or to resume execution.

JavaScript scenario can output into the Debug Console via the trace() function.

The video below shows Voximplant call control debugger in action starting from 1:26 We believe that our approach significantly simplifies and speeds up the debugging process for developers and we are happy to answer any questions about the debugger and its capabilities in the comments or via email.