Twilio Video

Twilio Programmable Video is a cloud communications platform enabling one-on-one and multi-party voice, chat and video to be embedded into web, desktop, and mobile software.

See also our Twilio Voice and Twilio Flex integrations.

How to use the integration

See the full documentation


<!DOCTYPE html>
    <!-- Load library (it provides window.callstats -->
    <script src=""></script>
    <!-- Load Twilio Video JS library -->
    <script src="//"></script>
    <!-- Load callstats-twilio-video library (it provides window.callstatstwiliovideo) -->
    <script src=""></script>
    <!-- Load our app code -->
    <script src="js/app.js"></script>

    <!-- your stuff -->

In app.js:

const Video = Twilio.Video;

Video.connect('$TOKEN', { name: 'room-name' }).then(room => {

  callstats = callstatstwiliovideo(room, peerToPeer, AppID, AppSecretOrTokenGenerator, localUserID, csInitCallback, csStatsCallback, configParams);

  console.log('Connected to Room "%s"',;
  // you can also set the room name later if you don't have the room info while initializing callstats


// Run the callstats-twilio-video library for this Twilio.Video.Room

Npm and bower packages for callstats-twilio-video is also available.
Read here the full documentation

Sample app can be found here -