OpenTok, the flexible video-chat API brought to you by Tokbox

Rick Donohoe's picture
Oct 20th 2012Account Manager

Recently we were presented with the problem of integrating a custom video-chat solution into Drupal.

Online video-chat is certainly nothing new, in fact you will most likely have seen and used many examples yourself such as Skype, Google Hangouts or even the notorious Chat Roulette. What we were looking for was a solution which had a highly customisable interface, functionality to integrate with the rest of the desired system, the ability to connect more than 10 users at once, and most importantly a high level of privacy within the video-chat. Unfortunately, the more common video-chat clients mentioned above are built as a standalone application, and are built with the philosophy that openness and sharing between participants is a goal rather than an undesirable lack of privacy amongst users.

What we needed was a highly customisable API which we found in OpenTok.


OpenTok's popularity comes from it's high level of customisation, vast documentation and variety of languages. OpenTok uses JavaScript, ActionScript, Native iOS, Titanium and PhoneGap Front-End libraries alongside PHP, Java, Python and Ruby Server-Side libraries. Allowing us to combine PHP and JavaScript made it a perfect candidate to integrate it in with Drupal.

Because of its flexibility Developers have managed to utilize its functionality to provide a variety of different examples such as:

  • Large group conferences
  • Chat shows
  • Online Poker with video-chat
  • Chat with the band/celebrities
  • Tutoring
  • Lectures and public talks

Web RTC and the future of Video-Chat

Unfortunately – and I'm sure many people will agree from experience – video chat is in no way perfect. Audio/video latency, feedback and connection problems are some of the many things which limit its true potential and can greatly affect the instantaneous, free-flowing natural conversation which is often taken for granted when speaking to someone in person.

Another limitation of video-chat is that the majority of solutions run on Flash, which is now becoming unsupported across different devices, especially since Apple have flat out refused to support it on their iPads, iPhones and other devices. Thankfully since the introduction of HTML5, the future of video-chat is now being defined with WebRTC.

WebRTC (Real Time Communications) enables users to build RTC applications through the capabilities of the browser, as opposed to using a plug-in. Ideally this will eventually create one universal solution which is supported all round and eliminates the need to download, install or update external plug-ins.

Currently there are limited browsers which support RTC, and some of the technological giants such as Microsoft and Apple are slow to get on-board with the whole project. Because of this the technology as a whole is far from reaching it's potential, and many features are currently in development or at a testing stage, which means it will most likely not be seen in many public applications just yet.

Interestingly OpenTok however are one of the first video-chat API's to begin using WebRTC, and there current progress can be seen within the OpenTok Labs. Although OpenTok have not managed to transfer all of the features of their Flash version to the new WebRTC version, progress is looking very impressive which can be seen through examples in the lab. Primarily there is a huge improvement in video quality, noticeable differences in latency, and an improved connection time which is up to 6x faster!


On November 6th, 2012 Tokbox announced it's first major product release of OpenTok on WebRTC. Effectively not only is this a big step forward in terms of more users adopting the technology, but it is a clear statement that Tokbox have developed OpenTok to a point where it is a full product as opposed to a lab project falling far behind the Flash version.

The best thing about the WebRTC release? You can switch your Flash based application over to WebRTC simply by changing the JavaScript library source to “”.

Rick Donohoe's picture

You may also like...

How does the EU Cookie Law affect you?

Rick Donohoe, Jul 1st 2012
On 26th May 2011 the Privacy and Electronic Communications Regulations changed, with the major change relating to the use and storage of cookies...

Add new comment

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.

Related Blogs

Sophie Shanahan-Kluth's picture
Rick Donohoe's picture
Mark Pavlitski's picture