Definition

Deactivating the audio session means the iOS telephony system has finished using the app’s call audio environment and the app should stop or release audio-related resources.

In CallKit, this is communicated through:

func provider(
    _ provider: CXProvider,
    didDeactivate audioSession: AVAudioSession
)

Core Concept

When a call ends, CallKit eventually tells the app:

“Your telephony audio session is no longer active.”

At this point, the app should stop:


Deactivation Flow

Call ends
        ↓
CallKit terminates telephony audio lifecycle
        ↓
didDeactivate audioSession fires
        ↓
App stops audio-related work

Delegate Method

func provider(
    _ provider: CXProvider,
    didDeactivate audioSession: AVAudioSession
)

This method is automatically called by CallKit.