Discussions

Ask a Question
Back to All

Mute Microphone Interactive Avatar SDK

Hi Gokce or Support, Please respond to my previous question, Im still waiting.

11 days ago by Marketing
What script can I implement to mute the microphone or that it doesnt respond to spoken text only the typed?

0

0
11 days ago by Gokce
Admin
Are you using Embed or Streaming API/SDK? (if you're using Embed mode, its behavior can't be modified directly)

0

0
10 days ago by Marketing
Stream API / SDK

I tried this:

const toggleMicrophone = () => {

561 | if (avatar.current && avatar.current.mediaStreamAudioSource) {

| ^
562 | const audioTracks = avatar.current.mediaStreamAudioSource.mediaStream.getAudioTracks();
563 | if (audioTracks.length > 0) {
564 | const newStatus = !isMicrophoneEnabled; // Toggle de status

but cant build it

How can I toggle between mute an demute microphone?