updateSpeaker

View as Markdown

updateSpeaker

  • updateSpeaker(opts): Promise<undefined>

Replaces the current speaker with a different one.

📘 Some browsers do not support output device selection. You can check by calling WebRTC.supportsMediaOutput.

Parameters

opts
object

Object containing the parameters of the method.

deviceId
string

Id of the new speaker device.

Returns

Promise<undefined>

Example

Replaces the current speaker:

1await roomSession.updateSpeaker({
2 deviceId: "/o4ZeWzroh+8q0Ds/CFfmn9XpqaHzmW3L/5ZBC22CRg=",
3});