Looking for a job? We're hiring!

Callstats.io Integration with JsSIP
By: , , ,
21 December 2016
Callstats.io integration with JsSIP



In the holiday spirit and to ease the anguish of customer support over the holidays. We are thrilled to announce that callstats.io is available with the JsSIP library bringing monitoring and analytics for JsSIP. If your app uses the SIP signalling like products from Twilio, Voxbone, Kazoo, Plivo, you must use the callstats-jssip shim. Big thanks to the team behind JsSIP, especially Iñaki Baz Castillo from Nimble Ape for integrating callstats.js!

Documentation

Callstats.io support landed with v3.0 of JsSIP. The documentation for integrating the callstats-shim is available here.

Download the latest shim from https://api.callstats.io/static/callstats-jssip.min.js.

Integrating in HTML

<!DOCTYPE html>
<html>
  <head>
    <!-- Load callstats.io library (it provides window.callstats -->
    <script src="https://api.callstats.io/static/callstats.min.js"></script>
    <!-- Load JsSIP library -->
    <script src="js/jssip.js"></script>
    <!-- Load callstats-jssip library (it provides window.callstatsjssip) -->
    <script src="https://api.callstats.io/static/callstats-jssip.min.js"></script>
    <!-- Load our app code -->
    <script src="js/app.js"></script>
  </head>
  <body>
    <!-- your stuff -->
  </body>
</html>

Integrating in app.js

// Create a JsSIP.UA instance
var ua = new JsSIP.UA(config);

// Run it
ua.start();

// Run the callstats-jssip library for this UA
callstatsjssip(ua, AppID, AppSecret);

Demo app

Enabling callstats.io in JsSIP settings

Enabling callstats.io in JsSIP settings

Enabling callstats.io with https://tryit.jssip.net is very simple. The app has a settings page, where callstats.io statistics can be toggled on or off on a per call basis. More details are available on the try-it’s github page.


We have multiple SDKs that have integrated with callstats.io, and any developer or company can integrate their own library with callstats.io. The integration instructions are available on our integrate page.



comments powered by Disqus