> For the complete documentation index, see [llms.txt](https://docs.whereby.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.whereby.com/reference/camera-effects-reference-1.md).

# Audio Denoiser Reference

The **Whereby Audio Denoiser SDK** is the low-level foundation for applying real-time noise suppression to a microphone stream within the Whereby ecosystem. It removes background noise — keyboard typing, fans, street noise — from the local participant's audio before it is sent to the room. It's meant to be used alongside Whereby's other SDKs, like the React Hooks browser SDK, or Whereby Core.

#### Use Case

Adding microphone noise suppression for use with either `@whereby.com/core` or `@whereby.com/browser-sdk/react`.

#### Requirements

The Audio Denoiser SDK is intended for browser environments and requires access to modern browser APIs, specifically `AudioContext` and `AudioWorkletNode`. Use the `isAudioDenoiserSupported()` helper to check support before exposing the feature in your UI.

{% hint style="info" %}
**You don't need to install `@whereby.com/audio-denoiser` separately.** As of `@whereby.com/core` v1.13 and `@whereby.com/browser-sdk` v3.24 it is bundled as a dependency of both packages. The denoiser code (and its WebAssembly assets) is loaded on demand the first time noise suppression is enabled, so it has no impact on your initial bundle size if you don't use it.
{% endhint %}

### Getting started

#### Installation

The audio denoiser ships with `@whereby.com/core` and `@whereby.com/browser-sdk`, so installing either of those is all you need:

{% tabs %}
{% tab title="npm" %}

```bash
npm install @whereby.com/browser-sdk
# or, for the low-level core SDK
npm install @whereby.com/core
```

{% endtab %}

{% tab title="yarn" %}

```bash
yarn add @whereby.com/browser-sdk
# or, for the low-level core SDK
yarn add @whereby.com/core
```

{% endtab %}

{% tab title="pnpm" %}

```bash
pnpm add @whereby.com/browser-sdk
# or, for the low-level core SDK
pnpm add @whereby.com/core
```

{% endtab %}
{% endtabs %}

#### Usage

Use the `isAudioDenoiserSupported()` helper to check browser support, then toggle noise suppression with the `enableAudioDenoiser` / `disableAudioDenoiser` actions. Both the helper and the actions are exposed by `@whereby.com/core` and `@whereby.com/browser-sdk/react`, so you never import `@whereby.com/audio-denoiser` directly. Once enabled, the denoiser is automatically re-applied if the microphone device is later switched.

{% tabs %}
{% tab title="React (browser-sdk)" %}

```tsx
import { useEffect, useState } from "react";
import { useRoomConnection, isAudioDenoiserSupported } from "@whereby.com/browser-sdk/react";

function NoiseSuppression({ roomUrl }) {
    const { actions } = useRoomConnection(roomUrl, { localMediaOptions: { audio: true, video: true } });
    const { enableAudioDenoiser, disableAudioDenoiser } = actions;

    const [supported, setSupported] = useState(false);
    const [enabled, setEnabled] = useState(false);

    // Loaded on demand; the denoiser code is only fetched when this runs.
    useEffect(() => {
        isAudioDenoiserSupported().then(setSupported);
    }, []);

    if (!supported) return null;

    return (
        <button
            onClick={async () => {
                if (enabled) {
                    await disableAudioDenoiser();
                } else {
                    await enableAudioDenoiser();
                }
                setEnabled(!enabled);
            }}
        >
            {enabled ? "Turn off noise suppression" : "Turn on noise suppression"}
        </button>
    );
}
```

{% endtab %}

{% tab title="Core" %}

```javascript
import { WherebyClient, isAudioDenoiserSupported } from "@whereby.com/core";

const client = new WherebyClient();
const roomConnection = client.getRoomConnection();

// Join the room as usual

// Check browser support (loaded on demand)
if (await isAudioDenoiserSupported()) {
    // Enable noise suppression on the local microphone
    await roomConnection.enableAudioDenoiser();

    // ...later
    await roomConnection.disableAudioDenoiser();
}
```

{% endtab %}
{% endtabs %}

{% hint style="info" %}
`@whereby.com/audio-denoiser` is still published as a standalone package and can be installed and imported directly for advanced use cases. For most integrations the helpers above are the recommended path.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.whereby.com/reference/camera-effects-reference-1.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
