Hi ,
Am using booth sendbirdcall.js and sendbirdchat.js.
after user complete a call i want to trigger a message in the group channel.
what will be the best approach.
Thanks
Hi ,
Am using booth sendbirdcall.js and sendbirdchat.js.
after user complete a call i want to trigger a message in the group channel.
what will be the best approach.
Thanks
You have listeners (when making and receiving calls)
const call = SendBirdCall.dial(dialParams, (call, error) => {
...
});
call.onEstablished = (call) => {
...
};
call.onConnected = (call) => {
...
};
call.onEnded = (call) => {
...
};
...
You can invoke a function inside the onEnded method:
call.onEnded = (call) => {
sendMessageToGroupChannel(call);
};
...
function sendMessageToGroupChannel(call) {
// Send your message here
}
Call object has many useful methods for you to use. You can set a breakpoint and check all the properties.