Suggestions

close search

Add Messaging, Voice, and Authentication to your apps with Vonage Communications APIs

Visit the Vonage API Developer Portal

VideoExpress.getActiveAudioOutputDevice

This method is a wrapper around the OT.getActiveAudioOutputDevice method.

The following code gets the current audio output device:

const device = await VideoExpress.getActiveAudioOutputDevice();

Methods

Name Description
(Promise<AudioOutputDevice>) VideoExpress.getActiveAudioOutputDevice ()

Returns a Promise that resolves the current audio output device.

The method returns a Promise which resolves an object that has two properties: deviceId and label, each of which are strings.

The deviceId property is a unique ID for the device. You can pass the deviceId as the parameter of the VideoExpress.setAudioOutputDevice() method. The deviceId property is set to undefined if the user has not previously granted access to a camera and microphone.

The label property identifies the device. The label property is set to an empty string if the user has not previously granted access to a camera and microphone.