For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Log inSign up
Support
ReferenceGuidesClick-to-Call
ReferenceGuidesClick-to-Call
  • Core
    • Overview
  • SignalWire Client
    • Overview
    • Notifications
    • Client
    • Utility functions
  • Video
    • Overview
    • LocalOverlay
    • RoomSession
    • RoomSessionDevice
    • RoomSessionPlayback
    • RoomSessionRecording
    • RoomSessionScreenShare
    • RoomSessionStream
    • RoomDevice
    • RoomScreenShare
  • Chat
    • Overview
    • Client
    • ChatMember
    • ChatMemberEntity
    • ChatMessage
    • ChatMessageEntity
  • PubSub
    • Overview
    • Client
    • PubSubMessage
  • WebRTC
    • Overview
LogoLogoSignalWire Docs
Log inSign up
Support
On this page
  • Properties
  • active
  • cameraId
  • cameraLabel
  • localAudioTrack
  • localStream
  • localVideoTrack
  • memberId
  • microphoneId
  • microphoneLabel
  • remoteStream
  • roomId
  • roomSessionId
  • Methods
  • audioMute
  • audioUnmute
  • join
  • leave
  • setInputSensitivity
  • setInputVolume
  • setMicrophoneVolume
  • updateCamera
  • updateMicrophone
  • videoMute
  • videoUnmute
Video

RoomDevice

Deprecated
|View as Markdown|Open in Claude|
Was this page helpful?
Edit this page
Previous

RoomScreenShare

Next
Built with
Deprecated

Use RoomSessionDevice instead.

Properties

active

• Readonly active: boolean

Whether the connection is currently active.


cameraId

• Readonly cameraId: null | string

The id of the video device, or null if not available.


cameraLabel

• Readonly cameraLabel: null | string

The label of the video device, or null if not available.


localAudioTrack

• Readonly localAudioTrack: null | MediaStreamTrack

Provides access to the local audio MediaStreamTrack.


localStream

• Readonly localStream: undefined | MediaStream

Provides access to the local MediaStream.


localVideoTrack

• Readonly localVideoTrack: null | MediaStreamTrack

Provides access to the local video MediaStreamTrack.


memberId

• Readonly memberId: string

The id of the current member within the room.


microphoneId

• Readonly microphoneId: null | string

The id of the audio input device, or null if not available.


microphoneLabel

• Readonly microphoneLabel: null | string

The label of the audio input device, or null if not available.


remoteStream

• Readonly remoteStream: undefined | MediaStream

Provides access to the remote MediaStream.


roomId

• Readonly roomId: string

The unique identifier for the room.


roomSessionId

• Readonly roomSessionId: string

The unique identifier for the room session.

Methods

audioMute

▸ audioMute(): Promise<void>

Puts the microphone on mute. The other participants will not hear audio from the muted device anymore.

Returns

Promise<void>

Permissions

  • room.self.audio_mute

You need to specify the permissions when creating the Video Room Token on the server side.

Example

Muting the microphone:

1await roomdevice.audioMute();

audioUnmute

▸ audioUnmute(): Promise<void>

Unmutes the microphone if it had been previously muted.

Returns

Promise<void>

Permissions

  • room.self.audio_unmute

You need to specify the permissions when creating the Video Room Token on the server side.

Example

Unmuting the microphone:

1await roomdevice.audioUnmute();

join

▸ join(): Promise<void>

Joins this device to the room session.

Returns

Promise<void>


leave

▸ leave(): Promise<void>

Detaches this device from the room session.

Returns

Promise<void>


setInputSensitivity

▸ setInputSensitivity(params): Promise<void>

Sets the input level at which the participant is identified as currently speaking.

Parameters

NameTypeDescription
paramsObject
params.valuenumberDesired sensitivity from 0 (lowest sensitivity, essentially muted) to 100 (highest sensitivity). The default value is 30.

Returns

Promise<void>

Permissions

  • room.self.set_input_sensitivity

You need to specify the permissions when creating the Video Room Token on the server side.

Example

1await roomdevice.setInputSensitivity({ value: 80 });

setInputVolume

▸ setInputVolume(params): Promise<void>

Sets the input volume level (e.g. for the microphone).

Parameters

NameTypeDescription
paramsObject-
params.volumenumberDesired volume. Values range from -50 to 50, with a default of 0.

Returns

Promise<void>

Permissions

  • room.self.set_input_volume

You need to specify the permissions when creating the Video Room Token on the server side.

Example

1await roomdevice.setMicrophoneVolume({ volume: -10 });

setMicrophoneVolume

▸ setMicrophoneVolume(params): Promise<void>

Deprecated. Use setInputVolume instead.

Parameters

NameType
paramsObject
params.volumenumber

Returns

Promise<void>


updateCamera

▸ updateCamera(constraints): Promise<void>

Replaces the current camera stream with the one coming from a different device.

Parameters

NameTypeDescription
constraintsMediaTrackConstraintsSpecify the constraints that the device should satisfy. See MediaTrackConstraints.

Returns

Promise<void>

Example

Replaces the current camera stream with the one coming from the specified deviceId:

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

updateMicrophone

▸ updateMicrophone(constraints): Promise<void>

Replaces the current microphone stream with the one coming from a different device.

Parameters

NameTypeDescription
constraintsMediaTrackConstraintsSpecify the constraints that the device should satisfy. See MediaTrackConstraints.

Returns

Promise<void>

Example

Replaces the current microphone stream with the one coming from the specified deviceId:

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

videoMute

▸ videoMute(): Promise<void>

Puts the video on mute. Participants will see a mute image instead of the video stream.

Returns

Promise<void>

Permissions

  • room.self.video_mute

You need to specify the permissions when creating the Video Room Token on the server side.

Example

Muting the camera:

1await roomdevice.videoMute();

videoUnmute

▸ videoUnmute(): Promise<void>

Unmutes the video if it had been previously muted. Participants will start seeing the video stream again.

Returns

Promise<void>

Permissions

  • room.self.video_unmute

You need to specify the permissions when creating the Video Room Token on the server side.

Example

Unmuting the camera:

1await roomdevice.videoUnmute();