Inspector CLI
CLI tool to explore MCP servers
Ask AI about Inspector CLI
Powered by Claude Β· Grounded in docs
I know everything about Inspector CLI. Ask me about installation, configuration, usage, or troubleshooting.
0/500
Reviews
Documentation
MCP Inspector CLI
A command-line tool to inspect and interact with MCP (Model Context Protocol) servers.
mcp-inspector-cli connects to any MCP server and allows you to explore:
- Tools
- Resources
- Resource templates
- Prompts
- Query interactions
This tool is useful for debugging, testing, and exploring MCP servers without needing an AI agent.
Installation
You can run it directly using npx:
npx mcp-inspector-cli --server <mcp_server_url>
Example:
npx mcp-inspector-cli --server http://localhost:3000/mcp
Or install globally:
npm install -g mcp-inspector-cli
Then run:
mcp-inspector-cli --server http://localhost:3000/mcp
Usage
Start the CLI and connect to an MCP server.
mcp-inspector-cli --server http://localhost:3000/mcp
Once connected, the interactive menu appears:
What would you like to do?
β― Query
Tools
Resources
Prompts
Exit
Features
Query
Send queries to the MCP server and allow the server to trigger tool calls.
Tools
List available tools and invoke them with custom arguments.
Resources
Browse and read resources exposed by the MCP server.
Supports both:
- static resources
- resource templates
Prompts
List and execute prompts defined by the MCP server.
Example Workflow
- Connect to server
mcp-inspector-cli --server http://localhost:3000/mcp
-
Select Tools
-
Choose a tool
-
Provide input arguments
-
Execute the tool and inspect the response
Development
Clone the repository:
git clone https://github.com/Sandeep-Petwal/mcp-inspector-cli
cd mcp-inspector-cli
Install dependencies:
npm install
Run locally:
npm run dev
Build the CLI:
npm run build
Link locally for testing:
npm link
Then run:
mcp-inspector-cli --server http://localhost:3000/mcp
Project Structure
src/
βββ cli.ts
βββ mcpClient.ts
βββ handlers/
βββ toolHandler.ts
βββ resourceHandler.ts
βββ promptHandler.ts
βββ queryHandler.ts
βββ shutdownHandler.ts
Requirements
- Node.js 18+
- An MCP server endpoint
License
MIT
