更新时间:2023-10-12 GMT+08:00
拨打呼叫
应用场景
座席侧登陆成功后,主动调用呼叫接口,实现音视频电话的主动呼叫。
前提条件
- 座席已经签入CTI平台。
- 话机账号登陆注册成功。
流程说明
调用OpenEyeCall的startCall接口进行接听呼叫。
/**
* 呼出
*/
function startCall() {
//需要区分匿名呼叫还是非匿名
var ischecked = document.getElementById("toggle-button-anonymous").checked;
if(ischecked){
this.global_openEye_SDK.openEyeCall.startAnonymousCall(document.getElementById("calloutNumber").value, false, {
response: startCallResponse
});
}else{
this.global_openEye_SDK.openEyeCall.startCall(document.getElementById("calloutNumber").value, false, {
response: startCallResponse
});
}
}
/**
* 呼出的响应
*/
function startCallResponse(data) {
if (data.result == 0) {
console.info("StartCall success. callid="+JSON.stringify(data));
tupCurrentCallId = data.param.callId;
} else {
console.error("StartCall failed. The ErrorCode is " + data.result);
console.info(data);
alert("StartCall failed. The ErrorCode is " + data.result);
}
}
父主题: 座席侧集成H5软电话开发指导