esinecan

MCP Inspector as MCP Server

Community esinecan
Updated

A lean MCP server that enables LLMs to inspect and test other MCP servers

MCP Inspector as MCP Server

A lean MCP server that enables LLMs to inspect and test other MCP servers. This is a self-contained implementation that uses the MCP SDK directly, without shelling out to external CLIs.

Features

  • Direct SDK integration: Uses @modelcontextprotocol/sdk directly for both server and client operations
  • All transport types: Supports stdio, SSE, and HTTP (streamable) transports
  • Minimal footprint: Single dependency (@modelcontextprotocol/sdk), ~300 lines of code
  • Full MCP inspection: List tools, call tools, list resources, read resources, list prompts, get prompts

Installation

npm install
npm run build

Usage

As an MCP Server

Add to your MCP config. While there are slight variances between different harnesses, the general format is the same:

{
  "mcpServers": {
    "mcp-inspector": {
      "command": "node",
      "args": ["/path/to/mcp-inspector-as-mcp-server/dist/server.js"]
    }
  }
}

Available Tools

Tool Description
insp_tools_list List all tools exposed by an MCP server
insp_tools_call Call a tool on an MCP server
insp_resources_list List all resources exposed by an MCP server
insp_resources_read Read a specific resource
insp_resources_templates List resource templates
insp_prompts_list List all prompts
insp_prompts_get Get a specific prompt

Connection Parameters

All tools accept the following connection parameters:

For stdio transport (local commands):

  • command: Command to run (e.g., "node", "python")
  • args: Array of arguments (e.g., ["path/to/server.js"])

For SSE/HTTP transport (remote servers):

  • url: Server URL (e.g., "http://localhost:3000/sse")
  • headers: Optional HTTP headers object

Common:

  • transport: Force transport type ("stdio", "sse", or "http"). Auto-detected if not specified.

Examples

List tools from a local MCP server:

{
  "command": "node",
  "args": ["/path/to/some-mcp-server/dist/server.js"]
}

Call a tool on a remote server:

{
  "url": "http://localhost:3000/sse",
  "tool_name": "search",
  "tool_args": {"query": "hello"}
}

Architecture

src/
├── server.ts     # MCP server exposing inspector tools
├── client.ts     # Client wrapper for inspecting other servers
└── transport.ts  # Transport factory (stdio, SSE, HTTP)

Why This Exists

The original MCP Inspector is a web-based UI + CLI combo spread across multiple projects. This consolidates the core functionality into a single, lean MCP server that an LLM can use to:

  1. Develop and debug MCP servers iteratively
  2. Test MCP server functionality without leaving the conversation
  3. Explore what tools/resources/prompts an MCP server exposes

License

MIT

MCP Server · Populars

MCP Server · New

    bibinprathap

    veritasgraph

    VeritasGraph — open-source Knowledge Graph & GraphRAG framework on GitHub. Build multi-hop reasoning, ontology-aware retrieval, and verifiable attribution over your own data. Nodes, edges, RDF, linked-data — runs locally or in the cloud.

    Community bibinprathap
    sher1096

    KLinePic MCP Server and Agent API Examples

    MCP server and OpenAPI examples for AI agents that turn broker and exchange fills into annotated KLinePic trade-review charts

    Community sher1096
    zerx-lab

    FluxDown

    Rust 驱动的多协议下载管理器,支持 HTTP/FTP/BitTorrent 磁力链接及 HLS/DASH 流媒体,智能多线程加速与浏览器无缝集成。精美界面,极致性能,永久免费,零广告。

    Community zerx-lab
    MasihMoafi

    Project Elpis:

    You put an agent into an Elpis, and it becomes Elpis; Be Elpis my friend.

    Community MasihMoafi
    ROCTUP

    1C Metacode MCP Server

    MCP сервер с встроенным AI агентом для поиска по графу метаданных и кода конфигураций 1С

    Community ROCTUP