Skip to main content
Version: 2.0.x

External Call Detection Events - iOS

External Call Detection Events - iOS​

VideoSDK provides external call detection events that notify you when a participant is on another call while in a meeting. These events help track call states and handle UI changes accordingly.

onExternalCallRinging​

  • Triggered when the participant receives an incoming call or starts dialing an outgoing call, and the call is ringing but not yet answered.

onExternalCallAnswered​

  • Triggered when the participant answers an incoming call or when an outgoing call is picked up by the other party.

onExternalCallRejected​

  • Triggered when the participant rejects an incoming call or ends the call while it is still ringing.

onExternalCallHangup​

  • Triggered when the participant ends an answered call or when the other party hangs up the call.

All of the above methods can be implemented in the abstract class MeetingEventListener and added as listeners to the Meeting class using the addEventListener() method.

For example, suppose a meeting is running with Alice and Bob. If Alice receives a call or makes a call, only Alice will receive the onExternalCallRinging event.

Example​

extension MeetingViewController: MeetingEventListener {
func onExternalCallRinging(callType: String) {
print("\(callType.capitalized) call is ringing...")
}

func onExternalCallAnswered(callType: String) {
print("\(callType.capitalized) call answered!")
}

func onExternalCallRejected(callType: String) {
print(" \(callType.capitalized) call rejected before answering!")
}

func onExternalCallHangup(callType: String) {
print("\(callType.capitalized) call ended after being answered.")
}
}

Got a Question? Ask us on discord