onReady : A JavaScript function that gets called when the connection is setup.

onDisconnected : A JavaScript function that gets called when the connection to the server gets down.

onAudiostats : A JavaScript function that gets called every five second during a call and contains information about the audio quality of the call. The event parameter object structure is given hereafter as a sample

var eventsample =
{
type: "audiostats",
data: {
duration: "00:01:05", // Total call duration
opackets: "3238 ", // Packets sent to server
olostpackets: "0", // Packets sent to server and lost on the way
ipackets: "2981 ", // Packets received from server
ilostpackets: "0", // Packets sent from server and lost on the way
rtt: "0.033000" // Round Trip Time to server in seconds (also called "ping time")
}
};

Place a call from your web pages

Just call the call function on the previously created CLIENT object. Add any parameter along with your listener functions that will let you handle in-call events. All the parameters set as the first argument will be forwarded to your ExternalScriptURL as HTTP parameters, therefore allowing to control the call.

In order to allow the call to the number 0123456789, your ExternalScript must return the following XML to APIdaze :

Join a conference room, add text and video chat to your web pages

Just call the joinroom function on the previously created CLIENT object. Add the room name your want to join along with your nickname for the room and listener functions as parameters. All the parameters set as the first argument will be forwarded to your ExternalScriptURL as HTTP parameters, therefore allowing to open access to the room.

When calling joinroom, your ExternalScript receives an HTTP request with the following parameters :

roomName

nickName

…

In order to grant access to the room named myroom, your ExternalScript must return the following XML to APIdaze :