tencent cloud

All product documents
Cloud Contact Center
Last updated: 2024-04-01 18:09:28
uni-app
Last updated: 2024-04-01 18:09:28

Call-related API Functions

API
Description
call
Initiates a call
answer
Answers the inbound call
terminate
Ends the call
sendDTMF
Sends Dual-Tone Multi-Frequency (DTMF) signals
mute
Mutes.
unmute
Unmutes.
startPlayMusic
Starts playing music
stopPlayMusic
Stops playing music

Sample Code for Initiating and Ending a Call

// Initiate a call. Call the login API before initiating a call. tcccSDK.login
tcccSDK.call({
to: '134xxxx', // Contact number (required)
remark: "xxx", // Number remarks, which will replace the number displayed in the call bar (optional)
uui: "xxxx", // User-defined data (optional)
}, (code,message) => {
if (code == TcccErrorCode.ERR_NONE) {
// Initiation succeeded
} else {
// Initiation failed
}
});
// End the call
tcccSDK.terminate();
// Answer the call
tcccSDK.answer((code,message) => {
if (code == TcccErrorCode.ERR_NONE) {
// Answer succeeded
} else {
// Answer failed
}
});

Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback

Contact Us

Contact our sales team or business advisors to help your business.

Technical Support

Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

7x24 Phone Support
Hong Kong, China
+852 800 906 020 (Toll Free)
United States
+1 844 606 0804 (Toll Free)
United Kingdom
+44 808 196 4551 (Toll Free)
Canada
+1 888 605 7930 (Toll Free)
Australia
+61 1300 986 386 (Toll Free)
EdgeOne hotline
+852 300 80699
More local hotlines coming soon