getMediaSourceId

external fun getMediaSourceId(requestWebContents: WebContents): String(source)

The identifier of a WebContents stream. This identifier can be used with navigator.mediaDevices.getUserMedia using a chromeMediaSource of tab. The identifier is restricted to the web contents that it is registered to and is only valid for 10 seconds. The desktop source only accepts screen and window identifiers from desktopCapturer.getSources; to capture a WebContents use this identifier with the tab source, or ses.setDisplayMediaRequestHandler.