From mcp-tooling
Use this skill when working with philschmid/mcp-cli — a lightweight Bun-based CLI for interacting with MCP servers from the shell. Use when the user asks about discovering MCP tools, calling MCP tools from the command line, reducing token consumption with dynamic tool discovery, or integrating MCP servers into shell scripts and AI agent workflows. Also use when encountering questions about mcp_servers.json configuration for CLI-based MCP access.
npx claudepluginhub nsheaps/ai-mktpl --plugin mcp-toolingThis skill uses the workspace's default tool permissions.
**Repository**: https://github.com/philschmid/mcp-cli
Compares coding agents like Claude Code and Aider on custom YAML-defined codebase tasks using git worktrees, measuring pass rate, cost, time, and consistency.
Designs and optimizes AI agent action spaces, tool definitions, observation formats, error recovery, and context for higher task completion rates.
Designs, implements, and audits WCAG 2.2 AA accessible UIs for Web (ARIA/HTML5), iOS (SwiftUI traits), and Android (Compose semantics). Audits code for compliance gaps.
Repository: https://github.com/philschmid/mcp-cli
A lightweight, Bun-based CLI for interacting with MCP servers from the shell. Designed for AI coding agents (Gemini CLI, Claude Code, etc.) and shell scripting workflows.
Traditional MCP integration loads entire tool schemas into the AI context window, consuming thousands of tokens. mcp-cli enables dynamic, on-demand discovery — the agent only fetches schemas for tools it actually needs.
Key advantages:
jq for chaining# Via install script
curl -fsSL https://raw.githubusercontent.com/philschmid/mcp-cli/main/install.sh | bash
# Via Bun
bun install -g https://github.com/philschmid/mcp-cli
| Command | Purpose |
|---|---|
mcp-cli | List all servers and tools |
mcp-cli -d | List all servers and tools with descriptions |
mcp-cli info <server> | Show all tools available in a server |
mcp-cli info <server> <tool> | Display complete tool JSON schema |
mcp-cli grep "<pattern>" | Search tools by name using glob pattern |
mcp-cli call <server> <tool> <json> | Execute a tool with JSON arguments |
# 1. Discover — list all servers and available tools
mcp-cli
mcp-cli -d # with descriptions
# 2. Explore — view tools for a specific server
mcp-cli info filesystem
# 3. Inspect — examine a specific tool's schema
mcp-cli info filesystem read_file
# 4. Execute — call the tool with arguments
mcp-cli call filesystem read_file '{"path": "./README.md"}'
Create mcp_servers.json in one of these locations (searched in order):
$MCP_CONFIG environment variable-c <path> command-line argument~/.config/mcp/{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "."]
},
"web": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-web"]
}
}
}
Control which tools are exposed per server:
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "."],
"allowedTools": ["read_file", "list_directory"],
"disabledTools": ["write_file"]
}
}
}
{
"mcpServers": {
"api": {
"command": "node",
"args": ["api-server.js"],
"env": {
"API_KEY": "${API_KEY}"
}
}
}
}
Missing variables cause errors unless MCP_STRICT_ENV=false.
# Pipe JSON from stdin
echo '{"path": "./file"}' | mcp-cli call filesystem read_file
# Chain with jq
mcp-cli call filesystem list_directory '{"path": "."}' | jq '.[] | .name'
# Search for tools matching a pattern
mcp-cli grep "read*"
| Code | Meaning |
|---|---|
0 | Success |
1 | Client error |
2 | Server error |
3 | Network issue |
| Scenario | Recommendation |
|---|---|
| AI agent needs a few specific tools | mcp-cli (discover on demand, save tokens) |
| Shell scripts calling MCP tools | mcp-cli (native shell integration) |
| Debugging MCP server issues | mcp-cli (inspect schemas, test calls) |
| Full IDE integration with many tools | Native MCP (persistent connection, all tools available) |
| CI/CD pipelines | mcp-cli (scriptable, JSON output) |