Skip to main content
Version: 0.0.x

Switch Audio Output (BETA)

This feature will help yout to switch audio output device during the session.

Get Connected Device List

This method will help you to list down all possible connected audio devices.

Supported Audio Output Devices :

  • SPEAKER_PHONE - Switch audio to device speaker

  • EARPIECE - Switch audio to device earpiece

  • WIRED_HEADSET - Switch audio to connected wired device

  • BLUETOOTH - Switch audio to connected bluetooth device

import { getAudioDeviceList } from "";

const onPress = async () => {
const device = await getAudioDeviceList();
console.log("Device :", device); // ["SPEAKER_PHONE","WIRED_HEADSET"]

Switch Audio to Another Device

This method will help you to switch specific audio output device.

import { switchAudioDevice } from "";

switchAudioDevice("SPEAKER_PHONE"); // for device speaker

switchAudioDevice("EARPIECE"); // for device earpiece

switchAudioDevice("WIRED_HEADSET"); // for wired headset

switchAudioDevice("BLUETOOTH"); // for bluetooth device

EARPIECE is not supported whenever WIRED_HEADSET or BLUETOOTH device is connected