Skip to navigation

MediaOptions

View as MarkdownOpen in Claude

Options controlling which media tracks to send and receive.

Extended by

Properties

audio
boolean

Enable audio input. Defaults to true when not specified.

fallbackToReceiveOnly
booleanDefaults to true

When local media can’t be acquired (permission denied or device unavailable), continue the call in receive-only mode instead of failing. Ignored when the call is not set to receive any media — with nothing to receive there is no call left to fall back to, so the failure is fatal.

inputAudioDeviceConstraints
MediaTrackConstraints

Custom constraints for the audio input track. See MediaTrackConstraints.

inputAudioStream
MediaStream

Pre-existing audio stream to use instead of getUserMedia. See MediaStream.

inputVideoDeviceConstraints
MediaTrackConstraints

Custom constraints for the video input track. See MediaTrackConstraints.

inputVideoStream
MediaStream

Pre-existing video stream to use instead of getUserMedia. See MediaStream.

receiveAudio
boolean

Whether to receive remote audio.

receiveVideo
boolean

Whether to receive remote video.

video
boolean

Enable video input. Defaults to false when not specified.