Mux

com.muxPublished by mux.comOfficial publisherv12.8.0Updated Oct 27, 2026

The official MCP Server for the Mux API

VerifiedStreamable HTTPWeb executableDeveloper ToolsMedia & Design

Overview

AI-generated overview

Official Mux MCP server that lets an assistant query Mux API docs and run TypeScript SDK code in a sandbox to manage video assets and playback.

What you can do
  • Search Mux API and SDK documentation
  • Write and execute TypeScript SDK code in an isolated sandbox to call the Mux API
  • Return whatever the sandboxed code prints or returns as the tool result
  • Run locally over stdio or as a remote Streamable HTTP server
When to use it
Useful when you want an assistant to work with a Mux account — inspecting or changing video assets, live streams and playback settings — through the official API rather than manual dashboard clicks, or to look up Mux SDK usage while writing code.
Requirements
Either the remote endpoint or the npm package run via npx (Node.js). Mux access token ID and secret (MUX_TOKEN_ID, MUX_TOKEN_SECRET) are required; OAuth or an Authorization header can be used instead. Optional MUX_SIGNING_KEY and MUX_PRIVATE_KEY for signed playback IDs. Local code execution needs Deno, installed automatically or pointed to via DENO_PATH; remote sandbox mode needs CODE_SANDBOX_URL and CODE_SANDBOX_API_KEY.
Before you install
The server holds Mux API credentials and can act on your Mux account, so code it runs may create, change or delete assets and other resources. The private key (MUX_PRIVATE_KEY) and signing key are sensitive secrets. By default HTTP callers can override client environment values and code tool permissions through request headers; disable that with --no-client-header-overrides on public deployments. Remote sandbox mode sends your code to a third-party service.

Installation

In SourceWeft

  1. Open Mux in the dashboard and add it to a workspace.
  2. Connect the required credentials. They are stored privately and never shown on public pages.
  3. Enable the server for the chats that should use its tools.

Web executable via Streamable HTTP. Remote servers run from the web runtime once configured in a workspace.

Use with an agent

Paste this prompt into Claude Code, Codex, Cursor or another agent — or into SourceWeft chat. The agent reads this server's install guide, shows you its publisher, endpoint and sign-in, and adds it to your client once you agree. Keys never go into a command.

Read https://sourceweft.com/mcp/com.mux%2Fmcp/install.md and connect the MCP server it describes to my client. Before changing any config, show me its publisher, endpoint and sign-in method and wait for my OK. Never put an API key in a command or in a file I would commit; ask me where it should come from.

Read the install guide the agent follows

Other MCP clients

Add this to your client's mcpServers config. The client completes OAuth sign-in on first connect.

{
  "mcpServers": {
    "mux": {
      "type": "http",
      "url": "https://mcp.mux.com/"
    }
  }
}

README

Mux TypeScript MCP Server

Installation

Direct invocation

You can run the MCP Server directly via npx:

sh
export MUX_TOKEN_ID="my token id"export MUX_TOKEN_SECRET="my secret"export MUX_WEBHOOK_SECRET="My Webhook Secret"export MUX_SIGNING_KEY="My Jwt Signing Key"export MUX_PRIVATE_KEY="My Jwt Private Key"export MUX_AUTHORIZATION_TOKEN="my authorization token"npx -y @mux/mcp@latest

Via MCP Client

There is a partial list of existing clients at modelcontextprotocol.io. If you already have a client, consult their documentation to install the MCP server.

For clients with a configuration JSON, it might look something like this:

json
{  "mcpServers": {    "mux": {      "command": "npx",      "args": ["-y", "@mux/mcp"],      "env": {        "MUX_TOKEN_ID": "my token id",        "MUX_TOKEN_SECRET": "my secret",        "MUX_WEBHOOK_SECRET": "My Webhook Secret",        "MUX_SIGNING_KEY": "My Jwt Signing Key",        "MUX_PRIVATE_KEY": "My Jwt Private Key",        "MUX_AUTHORIZATION_TOKEN": "my authorization token"      }    }  }}

Cursor

If you use Cursor, you can install the MCP server by using the button below. You will need to set your environment variables in Cursor's mcp.json, which can be found in Cursor Settings > Tools & MCP > New MCP Server.

[Add to Cursor]

VS Code

If you use MCP, you can install the MCP server by clicking the link below. You will need to set your environment variables in VS Code's mcp.json, which can be found via Command Palette > MCP: Open User Configuration.

Open VS Code

Claude Code

If you use Claude Code, you can install the MCP server by running the command below in your terminal. You will need to set your environment variables in Claude Code's .claude.json, which can be found in your home directory.

claude mcp add mux_mcp_api --env MUX_TOKEN_ID="my token id" MUX_TOKEN_SECRET="my secret" MUX_WEBHOOK_SECRET="My Webhook Secret" MUX_SIGNING_KEY="My Jwt Signing Key" MUX_PRIVATE_KEY="My Jwt Private Key" MUX_AUTHORIZATION_TOKEN="my authorization token" -- npx -y @mux/mcp

Code Mode

This MCP server is built on the "Code Mode" tool scheme. In this MCP Server, your agent will write code against the TypeScript SDK, which will then be executed in an isolated sandbox. To accomplish this, the server will expose two tools to your agent:

  • The first tool is a docs search tool, which can be used to generically query for documentation about your API/SDK.

  • The second tool is a code tool, where the agent can write code against the TypeScript SDK. The code will be executed in a sandbox environment without web or filesystem access. Then, anything the code returns or prints will be returned to the agent as the result of the tool call.

Using this scheme, agents are capable of performing very complex tasks deterministically and repeatably.

Execution modes

By default (--code-execution-mode=local), code runs on the MCP server machine in an isolated Deno sandbox. Setting --code-execution-mode=remote (or the MCP_SERVER_CODE_EXECUTION_MODE environment variable) sends code to a remote code sandbox service instead, configured with:

  • --code-sandbox-url / CODE_SANDBOX_URL: URL of the sandbox service. Required in remote mode.
  • --code-sandbox-api-key / CODE_SANDBOX_API_KEY: API key for the sandbox service, sent as a Bearer token. Required in remote mode.

Local mode runs the code under Deno, which the package installs for itself through its optional deno dependency. Where that cannot install — a blocked binary download, npm install --omit=optional, or a platform Deno does not ship an npm build for, such as Alpine — set DENO_PATH to a Deno 2.9 or newer executable. The same variable applies to mcp-code-runner below. The desktop bundle (.mcpb) never includes Deno; its settings expose DENO_PATH for the same purpose.

Request headers a caller may send

Over the HTTP transport, x-stainless-mcp-client-envs lets a caller supply client environment values (for example credentials) and x-stainless-mcp-client-permissions lets it adjust code tool permissions. Both are honored by default so a trusted proxy in front of the server can use them. A public deployment whose callers must not do either should start the server with --no-client-header-overrides (or pass clientHeaderOverrides: false in mcpOptions when embedding streamableHTTPApp).

Running code outside the server

The package also installs a mcp-code-runner bin for sandbox services that execute caller code in their own VM. It runs one request through the same Deno worker as local execution mode: feed it {"code": ..., "client_opts": ...} as JSON on stdin or as a file argument; it writes one {is_error, result, log_lines, err_lines} JSON line to stdout and Deno's own output to stderr. The network grant is the set of hosts the SDK calls (the client's base URL plus the media hosts some endpoints use), as in local execution mode.

Running remotely

Launching the client with --transport=http launches the server as a remote server using Streamable HTTP transport. The --port setting can choose the port it will run on, and the --socket setting allows it to run on a Unix socket.

Authorization can be provided via the Authorization header using the Basic or Bearer scheme.

Additionally, authorization can be provided via the following headers:

HeaderEquivalent client optionSecurity scheme
x-mux-token-idtokenIdaccessToken
x-mux-token-secrettokenSecretaccessToken
x-mux-authorization-tokenauthorizationTokenauthorizationToken

A configuration JSON for this server might look like this, assuming the server is hosted at http://localhost:3000:

json
{  "mcpServers": {    "mux": {      "url": "http://localhost:3000",      "headers": {        "Authorization": "Basic <auth value>"      }    }  }}

Source: packages/mcp-server/README.md at commit 59af362

Tools

0
This server asks you to sign in, so SourceWeft could not read its tools without an account and has not indexed them. What a connected account sees can depend on that account and its permissions.

Version history

1
  1. v12.8.0LatestSep 16, 2026

Score

85% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 daysRequired25 pts
  • Auth declaredRequired10 pts
  • Tools listed15 pts

    Answer tools/list without a credential, or ship a package that starts in a sandbox without one.

  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts