Vidyo.io is a platform as a service (PaaS) that enables developers to provide high-quality, real-time video communication capabilities. The service includes the VidyoClient SDK, which provides the APIs for integrating such communication capabilities into a variety of applications and workflows.
CTLive offers a built-in Vidyo integration by extending the contact chat object adding method and properties to control the media audio/video escalation.
Media escalation feature
CTLive offers a basic media escalation feature. A customer with an ongoing chat can request an engagement of the audio/video channel by creating a video conference. The CTLive SDK library offers a notification and response API allowing you to perform a request-response-engagement flow on the video channel.
Request API (on customer side)
contact.requestVideoUpgrade(String <divID>, Boolean <useAudio>, Boolean <useVideo>) // Example: contact.requestVideoUpgrade("videoPanel", true, true);
divID: Element div/panel ID where the composited video will be rendered
useAudio: flag that indicates whether to perform a media escalation on the current chat using the audio channel
useVideo: flag that indicates whether to perform a media escalation on the current chat using the video channel
Request Event notification (on agent side)
Register a callback on contact object for the “requestVideoUpgrade” event.
contact.on("requestVideoUpgrade", function (event) { // the Agent can accept/refuse the video media escalation } );
Response API (on agent side)
contact.responseVideoUpgrade(Boolean <true/false>, String <divID>); // Example: Agent accept the media escalation contact.responseVideoUpgrade(true, "videoPanel"); // Example: agent rejected the media escalation contact.responseVideoUpgrade(false, "videoPanel");
Response Event notification (on customer side)
contact.on("responseVideoUpgrade", function (event) { console.log("On [responseVideoUpgrade] event", event.response); // no action is required by the integration. // the audio / video connection will be automatically engaged // upon receipt of the positive response. } )
Participants Events Callback
A custom integration can bind a callback to receive notification about the participants members of the video engagement session.
contact.bindVideoParticipantEvent( function(event, eventName) { console.log("[CTLIVE AGENT SDK] PARTICIPANT Event [" + eventName + "]"); } );
Name | Type | Description |
---|---|---|
event | object | jQuery standard event notification object |
eventName | String | Participant event name. It can be one of the following values:
|