Frequently Asked Questions

  1. 1Getting started
  2. 2Technical specs
  3. 3Features
  4. 4Developer troubleshooting
  5. 5Launching your application
  6. 6Third-party code contributions
  7. 7Group Chat Embed
  8. 8Video Messages App

1Getting started

Where do I find documentation?

All the information you need to get started is located here. We have comprehensive documentation, but you might want to start with our basic tutorial.

What is an API key, and why do I need one?

You'll need an API key to access our development environment and start building your application. Your API key is unique and private.

What is the difference between the server-side API and the client-side API?

The client-side API is a JavaScript library that gives you control over how you size, place, move and connect video streams within your application. For Flash developers, we also provide a client-side ActionScript library. The server-side API is a library in your programming language of choice that you can use to generate tokens and sessions IDs programmatically in a way that talks to your app.

Why doesn't the sample code work from my desktop?

If you are running the HTML page from your desktop as a "file://" URL, what is happening is that Flash is putting up a security wall in order to prevent "cross-domain" communication from taking place. If you step through the code, you will likely see that session.connect() never returns.

This problem only occurs when you run the file from your desktop using the "file://" URL. If you use a local server (ie. a localhost URL), the problem will go away. If you serve the file from a web server, the problem will go away.

To enable the page to work directly from the desktop using a "file://" prefix, you need to change Flash's security settings. You can do this using a page online that Adobe provides:

  1. Go to this web page: http://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04.html
  2. Wait patiently while the Flash app initializes (it can take a while)
  3. Select "Add location" from the "Edit locations..." pull down menu
  4. Either specify the individual file location of the HTML page, or the file folder in which it is located (to make sure any other app pages you might have in the same directory also work).

You should find that the HTML page starts working after this.

2Technical specs

I am having trouble using OpenTok. What should I do?

Quickly go through our user diagnostic tool so we can make sure that your hardware, software and Internet are all up to par to use the OpenTok platform.

I am having trouble using OpenTok with Mac OS X Lion. What should I do?

Make sure that you have installed the latest version of Flash Player. There were some issues in previous versions on Mac OS X Lion.

What are the technical requirements for end users using OpenTok?

End users will need the following:

  • Flash Player 10.3 or later
  • Firefox 3.0+, Safari 4.0+, Internet Explorer 7+, Chrome
  • Windows XP+, OSX 10.4+
  • A webcam and a microphone!
  • A standard DSL line with a minimum upload and download speed of 160kb per call participant

Does this work on mobile devices / iPads?

We are working on new libraries to support mobile and tablet devices. If you would like to learn more, please email us at bizdev@tokbox.com

Why just Flash?

We believe that no download is the key to seamless video communication on the web — particularly as a platform that's woven into third-party applications. Today, Flash is the best way to deliver no download, browser- based video chat. However, by breaking apart the monolithic video chat window and giving you, the developer, JavaScript control over the elements, we are moving towards support for live video streaming using the new HTML5 <video> tags. As the browser implementations mature to support real-time video, switching from Flash-based video display to HTML5-based video display will be transparent to the developer.

3Features

How many users can participate in a session?

For details on OpenTok's current capacity, visit here. Contact us at if you have specific questions on OpenTok's ability to scale.

What's the baseline video / audio quality?

The quality varies based on users' connectivity. Please check here for system requirements

What are the security and privacy features?

As a developer, you generate an authentication token with the server-side APIs. You use this token when connecting to an OpenTok session. For sessions, TokBox protects privacy by generating a unique session ID —a randomized string of up to 255 alphanumeric characters—for each video chat session. Also, with OpenTok the developer can build functionality to remove unwanted participants.

I'm looking for [xyz] feature — can you build it? When?

If you don't see something you want/need — please contact us at .

How much does this cost?

We want lots of people to use OpenTok and are offering the basic live streaming for free. For more information see our pricing page

4Developer troubleshooting

My app isn't responding. What can I do?

Try the following:

See the API reference documentation for the TB class.

Developers using the OpenTok JavaScript library should use a HTML debug console, such as Firebug (for Firefox) or the Google Chrome Debugger.

Why is my app working erratically in IE8?

In Internet Explorer 8, links with href targets that invoke JavaScript actions cause a window.onbeforeunload event to be thrown. This event causes OpenTok to unload all components and disconnect from all sessions. Consequently, clicking on these kinds of links can unexpectedly disconnect OpenTok sessions, resulting in seemingly erratic behavior. In order to work around this problem, ensure that links with JavaScript actions are written as <a href="#" onclick="javascript:startPublishing();">Action</a> rather than as <a href="javascript:startPublishing();">Action</a>.

Why can I sometimes not click to allow my camera on Mac Firefox?

This issue is fixed in Firefox 4.

In previous versions of Firefox for Mac, the Allow button in the Adobe Settings Panel cannot be clicked. There are bugs filed with both Adobe and Mozilla. The Adobe issue describes it as happening when you center a Flash SWF. We have found that it also happens if you position the SWF relatively such that its x and y coordinates are not integers. As a workaround, add 0.5px to the margin-left of the SWF if the width of the window is odd; this is to make the x,y coordinates an integer. This doesn't work in every case, though.

I just started generating my own session IDs. Why can't one page subscribe to videos published in other pages?

For users to see each others audio-video streams, they need to connect to the same session (using the same session ID). Each OpenTok session is a collection of audio-video streams that can communicate with one another. To have users see each other's streams, do not generate unique session IDs for each user. Reuse the same session ID for each page in the session, and pass that session ID to the TB.initSession() method. (You do, however, generate unique connection tokens for each user.)

Why is a Publisher or Subscriber destroyed when I set the CSS style of container DIV to display:none?

This is a known issue in Firefox and Chrome (see Mozilla bug 90268).

Why is the container DIV destroyed when I publish or subscribe?

This is the correct behavior for the OpenTok JavaScript API. The element you pass into the Session.publish() or Session.subscribe() method is an HTML DOM element to be replaced. It is not a container element. You can create a container DIV element that contains another replacement element, and then pass that replacement element to the Session.publish() or Session.subscribe() method.

Do you support HTTPS?

The OpenTok JavaScript library supports HTTPS. If your page loads via HTTPS, be sure to load the OpenTok JavaScript library via HTTPS (otherwise the browser will display a warning to the user):

  • In staging — <script src="https://staging.tokbox.com/v0.91/js/TB.min.js" ></script>
  • In production — <script src="https://swww.tokbox.com/v0.91/js/TB.min.js" ></script>

(Note, however, that OpenTok video streams are not sent on a secure socket.)

5Launching your application

Why can't I use "devtoken" in production?

"devtoken" is our public token that we give out to developers for rapid prototyping in our staging environment. For security reasons, in the production environment we require that you generate your own token using a server-side API.

6Third party code contributions

.NET

Server-side library created by OpenTok community member trebor: (OpenTok server-side library for .NET)

Node.js

Server-side library created by OpenTok community member bsstoner: (OpenTok server-side library for node.js)

Perl

Server-side library created by OpenTok community member mephist: (OpenTok server-side library for Perl)

7Group Chat Embed

What is the Group Chat Embed widget?

The Group Chat Embed widget lets you as a site owner add live video chat to your site in just a couple of minutes. It is easy to set up and requires no fancy technical knowledge.

How do I get the Group Chat Embed widget?

If you'd like to get the Group Chat Embed widget, go to http://tokbox.com/opentok/plugnplay/basicembed.

Where can I put this embed?

You can embed the conversation in your own personal website, or on the following social network and blogging platforms:

  • Facebook
  • Ning
  • MySpace
  • Tumblr
  • Blogger
  • Posterous
  • Weebly
  • Webs
  • SquareSpace

How many users can participate in the chat at a time?

Up to twenty participants can be on-screen and publishing.

What is a "secret"?

The secret is a specific code we send to the chat owner's e-mail address once they've registered for the Group Chat Embed widget. The owner will need to use this secret to turn the embed "on." Identification using this secret will also give the owner the ability to ban participants who are acting rowdy.

What do I do if I've lost my secret?

If you've lost your secret, please go the page that includes your embed. Click "I'm a moderator," then click "Provide Secret," and then click "Forgot Secret." We will automatically send you an e-mail.

Can I kick someone out of the chat?

If you are the chat owner and have identified yourself using the secret, you can ban participants from the chat. Simply hover over the video stream of a rowdy participant and click the "Ban" icon in the upper-righthand corner of the participant's video. This ban is permanent.

What is the difference between the Group Chat Embed widget and the OpenTok API?

The Group Chat Embed lets you easily place video chat directly in a web page. The Group Chat Embed includes a set design for displaying videos in the page. The OpenTok API includes a JavaScript library and ActionScript library. These libraries also allow developers to integrate video chat directly into their own websites. It also provides support for building AIR apps (including apps for Android and iOS devices). The OpenTok API provides developers with complete control over the selection, layout, and interaction of individual audio/video streams.

What is with the black screen that is displayed when I first look at the widget?

Until other guests need to join, your session, the background is black.

How do I invite users to my chat?

You can invite users to your chat by sharing the URL of the webpage that uses your embed. You can also click the Twitter and Facebook logos in the embed to send a message to those social groups.

What do I do if the embed says "Temporarily Closed?"

In order to turn the embed back on, you must click the "restart" button, located in the bottom-right corner of the embed. You will then be prompted to input your secret, which can be found in the e-mail message TokBox sent to you.

The embed is free. What are the limits of the embed?

The Group Chat Embed can support up to 20 participants in a call at any one time. After 20 participants only viewers are allowed.

Does the Group Chat Embed work on mobile devices / iPads?

The Group Chat Embed is not supported on mobile devices or iPads.

8Video Messages App

What is the Video Messages App?

The Video Messages App allows any visitor to your website to leave recorded video messages. After they have finished recording their message, you will be emailed a unique URL that lets you watch their video message. Each video message has its own unique URL.

Where can I use the Video Messages App?

Just like our basic video chat embed, Video Messages App can be embedded into any HTML website such as Tumblr, Weebly or your personal website.

How long can visitors record for?

The maximum length of a video message is 10 minutes. During the beta program, we do not plan to limit the number of video messages each visitor can record. In the future, we may limit the number of submissions allowed per Video Messages App.

Can I share these video messages to other people?

Yes! Just point anyone to the unique URL that is created for each video message.

Can I delete video messages?

Currently, the Video Messages App does not allow you to delete messages. However, this will change as we evolve the product.

How much does the Video Messages App cost?

The Video Messages App is FREE as long as it remains in beta. There is no cost to download or use during the beta period. After the beta period ends, we will charge to store video messages.

How long will the beta period last?

The beta period is planned to last through the end of 2011. We will give plenty of notice before the beta period does end.

How long will you store these video messages? Are they secure?

We plan on storing these video messages at least through the beta period. While in beta, we make no guarantee regarding video message data loss. If you'd like to store messages for a long period of time please email us at support@tokbox.com so that we can help.

What if I have more questions?

Feel free to contact us through our forums.

For any other questions, please post to our forums.
To report a bug, please email .

From our blogs

TokBox blog

Read up on the latest news, views, and developer insights from TokBox

Follow us on Twitter