Rate this page:

Collecting logs in Web SDK

This article will help you to collect logs from Web SDK and Web RTC.

Contents

Copy URL

How to get Web SDK logs

Copy URL

First, you have to enable logging. To do so, specify the showDebugInfo parameter while initiating an SDK instance:

showDebugInfo

showDebugInfo

Logs in Developer Console

While using a Web SDK app in a browser, open the developer console and click the Levels dropdown to check Verbose.

Web console

To view messages logged from JavaScript:

  • In Chrome, press F12 or Command+Option+J (Mac) or Ctrl+Shift+J (Windows, Linux, Chrome OS).

  • In Firefox, select "Web Console" from the Web Developer submenu in the Firefox menu (or Tools menu if you display the menu bar or are on Mac) or press Ctrl+Shift+K, Ctrl+Shift+C or Ctrl+Shift+I (Windows) or press Command+Option+K (Mac).

  • In Safari, enable the Develop menu in Advanced preferences: Safari > Preferences > Advanced > Show Develop menu, then choose Develop > Show Error Console.

Now, reproduce your issue, right-click on the console panel, and choose "Save as…" to save the output to a file.

Do not forget to send the result file to our Support team if needed.

Logs in Browser

To see logs in the browser main window, use either Chrome or Firefox browser. Depending on which one of them you use, open "chrome://webrtc-internals/" or "about:webrtc" URL respectively.

Next, open the Web application being debugged in a new tab and reproduce the problem.

Finally, go back to the logs tab and save them as Web Page, Complete.

Log Collector

For those who want to organize logs in a special way (e.g., collect them in a database for further analysis), we've got a demo called log-collector, that is available freely on Github.

The demo allows you to collect logs about calls state and send them to your backend server. What backend server to choose is up to you, the demo works fine with all of them since it sends POST requests and uses no black magic.

How to get WebRTC logs

Copy URL

WebRTC logs help developers and Voximplant technical support in case of issues with audio or video connections. Right now only Chrome and Firefox web browsers can create such logs, and this article provides a step-by-step guide on how to download them.

Chrome web browser

  1. The browser tracks and logs all WebRTC connections, so close all tabs and restart the browser.
  2. Open a new tab and point it to the "chrome://webrtc-internals/" URL.
  3. Open the Web application being debugged and reproduce the problem.
  4. Go back to the "chrome://webrtc-internals/" tab, there will be at least two tabs:
  5. GetUserMedia Requests and https://your/appllication/url. You will see logs along with stats graphs.
  6. Choose the tab with the name of your application and save the page content as Web Page, Complete.
PAY ATTENTION

Stats graphs are not available in the saved file! We recommend either analyzing graphs while being on the chrome://webrtc-internals/ tab, or making screenshots for further usage.

Firefox web browser

  1. Close all tabs, open a new one and point it to the "about:webrtc" URL.
  2. Open the Web application being debugged in the new tab and reproduce the problem.
  3. Go back to the "about:webrtc" tab and save the page content as Web Page, Complete.

How to debug remote clients

Copy URL

Learn how to collect logs about the state of calls and send them to your backend server using the Voximplant logs collector.

Here is how you can make the module serve your needs:

  1. Clone this repo.
  2. Go to the Applications section of the Voximplant control panel and click your application.
  3. Switch to the Scenarios tab and create a new scenario. Paste the code from the Scenarios.VoxEngine.js file here, then save your scenario.
  4. Go to the repo folder, open logger.js, and paste your backend server hostname in line 43. Save the file.
  5. Open index.html in any browser.
  6. Fill in the username and password fields, e.g.: username: username@appname.account.voximplant.com password: 12345
  7. Start an outgoing call or answer the incoming one.
  8. When you need to send your logs, push the Report button.