audio

Edit, measure and convert audio files from an agent with the audiojs library's CLI, no ffmpeg needed

By audio.js TypeScript Local · stdio Media

55 popularity score ★ 330 ↓ 321/wk

Connect your client

Local (npm)

Add in one click

Opens the app, which asks before it adds the server.

Or add it by command or config

Claude CodeTerminal
claude mcp add audio -- npx -y audio --mcp
Claude Desktopclaude_desktop_config.json
{
  "mcpServers": {
    "audio": {
      "command": "npx",
      "args": [
        "-y",
        "audio",
        "--mcp"
      ]
    }
  }
}
Cursor~/.cursor/mcp.json
{
  "mcpServers": {
    "audio": {
      "command": "npx",
      "args": [
        "-y",
        "audio",
        "--mcp"
      ]
    }
  }
}
VS Code.vscode/mcp.json
{
  "servers": {
    "audio": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "audio",
        "--mcp"
      ]
    }
  }
}
Codex~/.codex/config.toml
[mcp_servers.audio]
command = "npx"
args = ["-y", "audio", "--mcp"]
Gemini CLITerminal
gemini mcp add --scope user audio npx -- -y audio --mcp

Settings 2

AUDIO_PLAYGROUND Optional: Bridge address for playground mode (AUDIO_EDITOR, its former name, also works); used only with --playground. Default the running bridge's saved address, else http://127.0.0.1:7777. For playground tools.
AUDIO_BRIDGE_KEY secret Optional: Bridge key for playground mode; read from the running bridge's saved file when unset. For playground tools.

What it does

This is the MCP mode of the audiojs `audio` package, a JavaScript library and command line tool that loads, analyses, edits and encodes sound. Launched with `--mcp` it talks MCP over stdio and exposes a single tool, also called `audio`. The agent hands it the CLI arguments as one string (absolute input paths, then a chain of operations such as trim, normalize to the podcast preset and save to a new file). The server runs the CLI in a child process and sends back whatever it printed. Codecs are WebAssembly builds, so you never install ffmpeg. The operations cover loudness and spectrum stats, delivery spec checks (podcast, Spotify, broadcast, Netflix, ACX), denoise, EQ, dynamics, cuts and fades, plus tempo, key and chord detection.

Start it with `--mcp --playground` and 14 more tools show up that work on the sound open in the project's browser playground at audio.js.org/audio/playground/. They don't touch files directly. Each call is posted over HTTP to a local bridge (`audio --bridge`, on 127.0.0.1:7777 by default) that you start yourself and pair with the page using its key. `measure` runs a JavaScript snippet against the open sound and answers with its last value as JSON. `look` sends back a PNG of the waveform drawn over the spectrogram.

A few things come from the code (bin/mcp.js in the published package) rather than the README. The tool's description is the project's SKILL.md file. Every answer is cut off at 20,000 characters, with a note asking for a narrower range. A `check` that fails comes back as a normal report, not a tool error. Any `-` argument (stdin or stdout piping) is refused, so inputs and outputs have to be file paths. Without `--playground` on the command line the playground tools are not listed at all, even when AUDIO_PLAYGROUND is set.

What it needs

RuntimeNode.js
Runs onmacOS, Windows, Linux
Also
  • For playground tools: `npx audio --bridge` running and the playground page open and connected

Node.js with npx (the library also runs on Bun and Deno). No account or key. Some features rely on optional peer packages that the plain npx command does not install, such as `@audio/neural-separate` for model-based stem separation and dereverb, `@audio/neural-denoise` for neural denoising and `@audio/host` for native plugins. Add them with npm install. The playground tools need the server started with `--mcp --playground`, plus `npx audio --bridge` running and the playground page connected with the bridge key.

Limits

  • Limit Over MCP the CLI cannot read stdin or write stdout: any `-` argument is refused, so pass absolute file paths.
  • Size cap Each tool answer is cut at 20,000 characters; long beat or note lists need a narrower time range or fewer stats.
  • Limit Playground tools appear only with `--playground` and return an error unless a bridge is running and the page is connected.
  • Limit The default mode has one tool, so the agent learns the CLI grammar from its long description.
  • Not covered Neural denoise, stem separation and native plugin hosting need optional peer packages the npx command does not bring.
  • Limit The MCP registry entry still lists version 2.10.0, behind the package on npm.

Over MCP the CLI cannot read from stdin or write to stdout: pass absolute file paths. Tool output is cut at 20,000 characters per call; long beat or note lists need a narrower time range or fewer stats. The default mode has a single tool, so the agent has to learn the CLI grammar from its description. Playground tools return an error unless a bridge is running and the page is connected. The `htdemucs` separation model's weights are for research use only, per the README. The registry entry lags npm (2.10.0 against 2.14.0).

Who it suits

Suits developers and podcasters who want an agent to check loudness against a delivery spec, clean up a recording, cut, convert or analyse tempo and key on local files, without installing ffmpeg or signing up for anything. Everything runs on your machine. Because one tool takes free-form CLI arguments, it fits agents that handle a rich description well; pick the playground mode if you want to see and hear each edit in a browser. It is not a fit for cloud audio services or for streaming audio through pipes, which the MCP mode refuses.

Tools 15

4 only read, 11 change things. A ? marks an optional parameter.

audio changes
Runs the audio CLI with the given arguments on local files and returns its printed outputargs: string
state
Reports the open sound: script, duration, sample rate, channels, selection, edits and levels
script changes
Replaces the playground's whole edit script and renders itcode: string
edit changes
Appends one method call to the end of the edit chain as one undo stepcall: string
measure
Runs a JavaScript snippet on the open sound and returns its last value as JSON, changing nothingcode: string
look
Returns a PNG of the waveform over the spectrogram for a time range or one editat?: numberd?: numberstep?: integertakes?: boolean
select changes
Sets the selection range, or a frequency box on the spectrogramat?: numberd?: numberlow?: numberhigh?: numbercursor?: numbertrack?: string
scrub changes
Moves the user's cursor so the moment under it soundsat: numberto?: numberd?: number
step changes
Turns one edit on or off, removes, moves or rewrites itindex: integeron?: booleanremove?: booleanto?: integercall?: stringat?: numberd?: number
open changes
Opens a local audio or video file in a new playground tabpath: string
play changes
Plays the output, the original or the output up to one edit on the user's speakersat?: numberd?: numberoriginal?: booleanstep?: integertakes?: boolean
stop changes
Stops playback in the page
check
Checks the output against a delivery spec: podcast, spotify, broadcast, netflix or acxspec: string
undo changes
Undoes the last change to the script
redo changes
Redoes the change undo took back

Similar servers