Install MCP Server
Configure Router9 as an MCP server for AI harnesses
Router9 Skills are available via the Model Context Protocol (MCP), making them compatible with MCP-enabled AI harnesses like Claude Code, Codex, OpenCode, and omp.
Router9 hosts the MCP server for you — there is nothing to install or run locally. Point any MCP client that supports the Streamable HTTP transport at:
https://api.router9.com/v1/mcpAuthenticate with your Router9 API key in an Authorization: Bearer header.
Prerequisites
- A Router9 API key (
sk-r9k-...). See Authentication to create one.
Claude Code
Add Router9 as a remote HTTP MCP server with one command:
claude mcp add --transport http router9 https://api.router9.com/v1/mcp \
--header "Authorization: Bearer sk-r9k-your-key"By default the server is added to the local scope (this project, your machine only).
Use --scope user to make it available in every project, or --scope project to
share it with your team through a checked-in .mcp.json.
Verify the connection from inside Claude Code with the /mcp command — Router9's
Skills then show up as mcp__router9__* tools.
You can also write the configuration by hand in .mcp.json (project scope) or
~/.claude.json (user scope):
{
"mcpServers": {
"router9": {
"type": "http",
"url": "https://api.router9.com/v1/mcp",
"headers": {
"Authorization": "Bearer sk-r9k-your-key"
}
}
}
}Prefer not to commit your key? Claude Code expands environment variables in
.mcp.json, so"Authorization": "Bearer ${ROUTER9_API_KEY}"works too.
This connects Router9 tools to Claude Code; it does not change which model Claude Code talks to.
Codex
Codex reads MCP servers from ~/.codex/config.toml. Add Router9 as a streamable
HTTP server and let Codex pull the key from your environment:
[mcp_servers.router9]
url = "https://api.router9.com/v1/mcp"
bearer_token_env_var = "ROUTER9_API_KEY"bearer_token_env_var names the environment variable holding your key — Codex sends
it as Authorization: Bearer <token>. To hardcode the header instead, use:
[mcp_servers.router9]
url = "https://api.router9.com/v1/mcp"
http_headers = { Authorization = "Bearer sk-r9k-your-key" }Run codex mcp list to confirm Router9 is registered.
OpenCode
Add Router9 as a remote MCP server in your opencode.json:
{
"mcp": {
"router9": {
"type": "remote",
"url": "https://api.router9.com/v1/mcp",
"enabled": true,
"headers": {
"Authorization": "Bearer sk-r9k-your-key"
}
}
}
}omp
omp discovers MCP servers from .omp/mcp.json (project) or
~/.omp/agent/mcp.json (user):
{
"mcpServers": {
"router9": {
"type": "http",
"url": "https://api.router9.com/v1/mcp",
"headers": {
"Authorization": "Bearer ${ROUTER9_API_KEY}"
}
}
}
}${ROUTER9_API_KEY} expands from your environment at discovery time; a literal
sk-r9k-... works too. You can also add it interactively with /mcp add, then
check it with /mcp test router9.
Generic MCP Client
Any client that speaks the MCP Streamable HTTP transport can connect. Point it at the endpoint and send your key as a Bearer token:
- URL —
https://api.router9.com/v1/mcp - Header —
Authorization: Bearer sk-r9k-your-key
Available Tools
Once connected, the MCP server exposes every Router9 capability as a tool:
audio_transcribe/audio_synthesizeimage_describeimage_generate/image_editimage_upscale/image_background_remove(when a provider that can serve them is configured)project_list
Everything the image and speech tools make is kept in your library, filed into a
project — the same projects Router9 Studio shows under Works. Call
project_list for their ids and pass one as project_id; without one, results
land in your default project.
image_generate takes an enhance_prompt flag: a language model expands the
prompt before drawing, and the text it produced comes back as enhanced_prompt.
It is a second billed call, and it fails open — if the rewrite cannot be produced
your own prompt is drawn and nothing extra is charged.
search_webalso appears when web search is configured on the server.video_generateis on the roadmap and will appear here once available.