Handling call events
#
Listening to the call eventsIn order to listen to the call events you need to set delegate to the CallManagerDelegate sdk using the below method
- Swift
- Objective-C
info
AudioLevel ranges from 0 to 10, 0 being very low sound and 10 being too loud.
#
Handling mute eventsWhenever call end user mute/unmute video or audio, the below delegate will be triggered.
- Swift
- Objective-C
muteEvent
value will be anyone of the values of annotation class MuteEvent
.
muteEvent Value | Call event |
---|---|
MuteEvent.ACTION_REMOTE_VIDEO_MUTE | when the remote user muted his video |
MuteEvent.ACTION_REMOTE_VIDEO_UN_MUTE | when the remote user unmuted his video |
MuteEvent.ACTION_REMOTE_AUDIO_MUTE | when the remote user muted his audio |
MuteEvent.ACTION_REMOTE_AUDIO_UN_MUTE | when the remote user unmuted his video |
MuteEvent.ACTION_LOCAL_AUDIO_MUTE | when the local user muted his audio |
MuteEvent.ACTION_LOCAL_AUDIO_UN_MUTE | when the local user unmuted his video |
#
Handling call status eventsWhenever call status changed in video or audio call, the below delegate will be triggered.
- Swift
- Objective-C
callStatus
value will be anyone of the values of annotation class CallStatus
.
callStatus Value | Call event |
---|---|
CallStatus.CALLING | the initial state of the call |
CallStatus.CONNECTING | The current call is in connecting state |
CallStatus.RINGING | the remote user is having internet and acknowledged the call |
CallStatus.ATTENDED | the user attended call and UI can be presented with the users in the call |
CallStatus.CONNECTED | the call is successfully connected and audio/video tracks transmission is about to start |
CallStatus.DISCONNECTED | the call is disconnected and call UI can be closed |
CallStatus.RECONNECTING | the call is in reconnecting state |
CallStatus.RECONNECTED | the call is connected back after a reconnecting state |
CallStatus.ON_HOLD | the remote user has put your call on hold, it will happedn when the remote user attended gsm call |
CallStatus.ON_RESUME | the remote user has resumed your call after a on hold, it will happen when the remote user disconnected gsm call |
CallStatus.CALL_TIME_OUT | when we don't receive ack for the outgoing call from the remote user within 30 seconds, When we don't receive ack for the incoming call from the caller within 30 seconds, When we don't receive ack for the call invite from the invited user within 30 seconds |
#
Handling call action eventsWhenever call action received in video or audio call, the below delegate will be triggered,
- Swift
- Objective-C
callAction
value will be anyone of the values of annotation class CallAction
.
callAction Value | Call event |
---|---|
CallAction.ACTION_LOCAL_HANGUP | whenever you disconnect the call, the action will be received |
CallAction.ACTION_DENY_CALL | when you decline the incoming call, the action will be received for callee |
CallAction.ACTION_PERMISSION_DENIED | when you attend the incoming call without required permissions, the action will be received for the callee |
CallAction.ACTION_REMOTE_ENGAGED | when the remote user is engaged in the another call, the action will be received for the caller |
CallAction.ACTION_REMOTE_BUSY | when the remote user declines incoming the call, the action will be received for the caller |
CallAction.ACTION_AUDIO_DEVICE_CHANGED | whenever the audio device changed in call, update the audio device UI |
CallAction.ACTION_INVITE_USERS | When you invite users to the call, this will be triggered so that you can update your UI |
CallAction.ACTION_VIDEO_CALL_CONVERSION_REJECTED | When remote user declined our video call switch request |
CallAction.ACTION_VIDEO_CALL_CONVERSION_ACCEPTED | When remote user accepted our video call switch request |
CallAction.ACTION_VIDEO_CALL_CANCEL_CONVERSION | When remote user cancels the video call switch request made by them |
CallAction.ACTION_CAMERA_SWITCH_DONE | When camera switch done, the action will be received |
CallAction.CHANGE_TO_AUDIO_CALL | When ui needs to be changed as audio call ui this action will be received |
CallAction.ACTION_REMOTE_VIDEO_ADDED | When the remote user video track is received, this action will be received |
CallAction.ACTION_PERMISSION_DENIED | When Audio or Camera permission is denied and makes a call |
CallAction.INCOMING_ACTION_PERMISSION_DENIED | When Audio or Camera permission is denied and receives a call |
#
Handling the video track eventsWhen the remote user video track is received, this action will be received: CallAction.ACTION_REMOTE_VIDEO_ADDED. When this action is triggered, request SDK to fetch the track of the user
- Swift
- Objective-C
#
Observing the Missed call Notification on ForegroundIn order to Observe the missed call notification in foreground you need to set the delegate MissedCallNotificationDelegate in AppDelegate using the below method
- Swift
- Objective-C