Skip to main content
Control audio output routing during calls. Switch between speaker, earpiece, Bluetooth, and wired headphones based on user preference or device availability.

Available Audio Modes

ModeDescription
SPEAKERRoutes audio through the device loudspeaker
EARPIECERoutes audio through the phone earpiece (for private calls)
BLUETOOTHRoutes audio through a connected Bluetooth device
HEADPHONESRoutes audio through wired headphones

Set Initial Audio Mode

Configure the audio mode when joining a session:

Change Audio Mode During Call

Switch audio modes dynamically during an active call:

Listen for Audio Mode Changes

Monitor audio mode changes using MediaEventsListener:

Hide Audio Mode Button

To prevent users from changing the audio mode, hide the button in the call UI:
The SDK automatically detects connected audio devices. If Bluetooth or wired headphones are connected, they become available as audio mode options.