mcpspan — MCP server for Claude Code: server analytics
mcpspan lets an agent inspect MCP server activity, errors, releases, clients, and sessions. Use it to find failing tools or requests your servers cannot handle.
MIT ★ 23 updated 2026-10-28
claude mcp add --transport http mcpspan https://api.mcpspan.com/mcpWhat mcpspan does
Ask an agent to inspect call and error counts, compare releases, review client response times, or find tools that agents requested but the server lacks. It can also show repeated calls and tools exposed to agents but never used. Every tool is read-only.
Connect over HTTP, or run the server as a command with npx. The command-based setup needs a read token and Node 20 or newer. Self-hosted command mode requires mcpspan 0.9.0 or newer; address-based access requires version 0.13.0 or newer. Remote access to a self-hosted installation needs HTTPS because each question carries the token.
What it helps with
- spot MCP tools with the most failures
- compare server metrics across releases
- find requests for tools the server does not provide
- inspect failed and repeated calls in a session
- compare error rates across clients
Example prompts for the agent
- Show the most common errors on my MCP server over the last few days.
- Compare my server releases and explain what changed in the metrics.
- Which tools did agents request that my server does not provide?
How to install mcpspan
1Platform CLI: remote server
claude mcp add --transport http mcpspan https://api.mcpspan.com/mcp2Platform CLI
claude mcp add --env MCPSPAN_READ_TOKEN=<MCPSPAN_READ_TOKEN> --env MCPSPAN_URL=<MCPSPAN_URL> --transport stdio mcpspan-mcp -- npx -y mcpspan-mcpReplace <…> with your own values
1Platform CLI: remote server
codex mcp add mcpspan-mcp --url https://api.mcpspan.com/mcp2Platform CLI
codex mcp add mcpspan-mcp --env MCPSPAN_READ_TOKEN=<MCPSPAN_READ_TOKEN> --env MCPSPAN_URL=<MCPSPAN_URL> -- npx -y mcpspan-mcpReplace <…> with your own values
Config file
{
"mcpServers": {
"mcpspan-mcp": {
"url": "https://api.mcpspan.com/mcp"
}
}
}{
"mcpServers": {
"mcpspan-mcp": {
"command": "npx",
"args": [
"-y",
"mcpspan-mcp"
],
"env": {
"MCPSPAN_READ_TOKEN": "<MCPSPAN_READ_TOKEN>",
"MCPSPAN_URL": "<MCPSPAN_URL>"
}
}
}
}Replace <…> with your own values
Config file
{
"servers": {
"mcpspan-mcp": {
"type": "http",
"url": "https://api.mcpspan.com/mcp"
}
}
}{
"servers": {
"mcpspan-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"mcpspan-mcp"
],
"env": {
"MCPSPAN_READ_TOKEN": "<MCPSPAN_READ_TOKEN>",
"MCPSPAN_URL": "<MCPSPAN_URL>"
}
}
}
}Replace <…> with your own values
1Platform CLI: remote server
gemini mcp add -t http mcpspan-mcp https://api.mcpspan.com/mcp2Platform CLI
gemini mcp add -e MCPSPAN_READ_TOKEN=<MCPSPAN_READ_TOKEN> -e MCPSPAN_URL=<MCPSPAN_URL> mcpspan-mcp npx -y mcpspan-mcpReplace <…> with your own values
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about mcpspan
How do I install mcpspan in Claude Code?
Add the HTTP server with claude mcp add --transport http mcpspan https://api.mcpspan.com/mcp. On first connection, sign in to mcpspan and approve access.
What does mcpspan do?
It gives an agent read-only tools for inspecting MCP server activity, including errors, calls, clients, releases, and sessions.
What does mcpspan need to run through npx?
The command-based setup requires a read token and Node 20 or newer. For a self-hosted installation, set MCPSPAN_URL; remote access requires HTTPS.