@wppconnect-team/wppconnect - v2.4.0
    Preparing search index...

    The Node.js SDK re-exports the WAJS namespace for TypeScript. This reference describes types from WA-JS 4.8.0. For operations available on a connected Node.js client, see Whatsapp. For functions running inside WhatsApp Web, see the WA-JS browser API.

    Function enableAudioCapture

    • Emit the call audio as call.audio_frame events: 16 kHz mono frames of 60 ms. remote frames are what you hear, local frames what you send.

      Enable it before the call starts: the audio graph of the call is created when the call starts and cannot be tapped afterwards.

      Applies to one call and stops when it ends or is replaced. Re-enable for another call. Pass false to stop early.

      Parameters

      Returns void

      WPP.call.enableAudioCapture({ format: 'int16-base64', source: 'remote' });
      WPP.on('call.audio_frame', (frame) => {
      // frame.samples
      });

      // Stop
      WPP.call.enableAudioCapture(false);