SimpleUser Media Do Not Request or Use Local Audio Source

169 views
Skip to first unread message

David Plappert

unread,
Jul 2, 2021, 4:08:25 PM7/2/21
to SIP.js
I am trying to only listen to a remote call. I do not want the local user's microphone or webcam to be used or requested. This is my code so far, but it does not function as I intend. I can remove the line "exact:null" and my code works for calling, but it still asks permission for my mic.

const options = {
  media: {
    remote: {
      audio: this.$refs.remoteAudio,
    },
    constraints:{
      audio:{
        deviceId: {
          exact: null,
        }
      },
      video:false
    }
  },
  userAgentOptions: {
    authorizationPassword: pass,
    authorizationUsername: user,
  }
};

const server = "wss://" + domain;

// this sets up the main object
this.sip_SimpleUser = new this.$Sip.SimpleUser(server, options);
Reply all
Reply to author
Forward
0 new messages