*** id: 6c2258fe-d9ae-4d65-92f3-c51e5d6700d7 title: updateSpeaker slug: /js/reference/video/room-session/update-speaker description: updateSpeaker method for the RoomSession class. max-toc-depth: 3 ---------------- ### updateSpeaker * **updateSpeaker**(`opts`): `Promise` Replaces the current speaker with a different one. > 📘 > Some browsers do not support output device selection. You can check by calling [WebRTC.supportsMediaOutput](/docs/browser-sdk/v3/js/reference/webrtc#supportsmediaoutput). #### Parameters Object containing the parameters of the method. Id of the new speaker device. #### Returns `Promise` #### Example Replaces the current speaker: ```javascript await roomSession.updateSpeaker({ deviceId: "/o4ZeWzroh+8q0Ds/CFfmn9XpqaHzmW3L/5ZBC22CRg=", }); ```