when i have used on prem livekit for Enhanced nois...
# ask-ai
n
when i have used on prem livekit for Enhanced noise cancellation it is giving me error like not authenticated
t
Thanks for reaching out, Darshak. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Thank you for reaching out! The "not authenticated" error happens because the enhanced noise cancellation feature is exclusive to LiveKit Cloud and isn’t available in on-prem deployments. This feature uses advanced models licensed from Krisp, which are integrated into LiveKit Cloud and require authentication to work. For your on-prem setup, you can still use the default WebRTC-based noise and echo cancellation features by configuring
AudioCaptureOptions
during connection setup. These options include
echoCancellation
and
noiseSuppression
, and the great news is they don’t need cloud authentication. If having advanced noise cancellation is really important for your use case, you might consider looking into third-party libraries or custom server-side processing. While LiveKit doesn’t provide these directly, I’m here to help you explore the best options for your needs! Sources: Enhanced noise cancellation | LiveKit Docs | Noise & echo cancellation | LiveKit Docs
n
How can i integrate
AudioCaptureOptions
in BE or FE and How?
t
To help you integrate
AudioCaptureOptions
, you’ll want to set them up on the frontend when creating local audio tracks or connecting to a room. Here’s a friendly guide on how you can do it: JavaScript/TypeScript SDK:
Copy code
import { createLocalAudioTrack } from 'livekit-client';

const audioTrack = await createLocalAudioTrack({
  echoCancellation: true,
  noiseSuppression: true,
  autoGainControl: true,
});
Or, if you prefer, when connecting to a room:
Copy code
await room.connect(url, token, {
  audioCaptureDefaults: {
    echoCancellation: true,
    noiseSuppression: true,
  },
});
Swift SDK:
Copy code
let audioOptions = AudioCaptureOptions(
  echoCancellation: true,
  noiseSuppression: true,
  autoGainControl: true
)
Flutter SDK:
Copy code
final audioOptions = AudioCaptureOptions(
  echoCancellation: true,
  noiseSuppression: true,
  autoGainControl: true,
);
Unity Web SDK:
Copy code
var audioOptions = new AudioCaptureOptions {
    AutoGainControl = true
};
Just a quick note: these options are applied on the client side and aren’t processed on the backend. If you have any questions or want to explore this further, feel free to reach out—I’m here to help! Sources: lib/src/track/options.dart | Runtime/Scripts/Room/Track/Options.cs | Noise & echo cancellation | LiveKit Docs | Operational Guidance & Best Practices | livekit/livekit_composite | DeepWik... | src/room/track/options.ts