mcp-cli-tool

Discover, inspect, and execute MCP server tools from the command line.

7|2|Updated May 16, 2026
One-click install
npx skills add https://github.com/reason-machines/mcp-skills --skill mcp-cli-tool-reason-machines
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: mcp-cli-tool
Source: https://github.com/reason-machines/mcp-skills/tree/main/skills/mcp-cli-tool
Command: npx skills add https://github.com/reason-machines/mcp-skills --skill mcp-cli-tool-reason-machines

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Interacting with Model Context Protocol servers normally requires loading full tool schemas into an AI agent's context, consuming thousands of tokens, or writing custom client code. This Skill provides a lightweight CLI to discover, inspect, and call MCP tools directly from the shell with JSON output. ## Core Features & Use Cases - On-Demand Schema Loading: List servers, grep tools by glob pattern, and fetch individual tool schemas only when needed, saving context tokens. - Shell Composability: JSON output pipes cleanly into jq for filtering, chaining multiple MCP calls, and building automation scripts. - Flexible Configuration: Supports stdio and HTTP servers, environment variable substitution, tool allow/deny filtering, and connection pooling via a lazy-spawn daemon. - Use Case: An AI agent needs to search GitHub repositories through an MCP server. Instead of loading all schemas, it runs mcp-cli info github search_repositories to get one schema, then calls the tool and pipes the result through jq to extract repository URLs. ## Quick Start Install mcp-cli, create an mcp_servers.json config with your MCP servers, then ask the agent to list available tools and call one with JSON arguments.

Frequently Asked Questions about mcp-cli-tool

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I call an MCP server tool from the command line?▼

Use mcp-cli call with the server name, tool name, and JSON arguments, for example: mcp-cli call github search_repositories '{"query": "mcp"}'. For complex JSON, pipe arguments via stdin or a heredoc to avoid shell escaping issues.

How do I list available MCP tools without loading all schemas?▼

Run mcp-cli to list servers and tool names, mcp-cli grep "*pattern*" to search by glob, or mcp-cli info <server> <tool> to fetch a single tool schema. This on-demand approach avoids loading thousands of tokens of schema definitions.

Does mcp-cli support both stdio and HTTP MCP servers?▼

Yes, mcp-cli supports both transports. Stdio servers are configured with command, args, and env fields, while HTTP servers use a url field with optional headers such as Authorization bearer tokens.

Is the mcp-cli config compatible with Claude Desktop?▼

Yes, the mcp_servers.json format is compatible with Claude Desktop, Gemini, and VS Code. It uses the standard mcpServers key and supports ${VAR} environment variable substitution for secrets.

Why does mcp-cli fail with 'Environment variable not found'?▼

By default MCP_STRICT_ENV=true causes an error when a ${VAR} referenced in config is unset. Export the missing variable, or set MCP_STRICT_ENV=false to substitute empty values with a warning, though that is not recommended.

How do I restrict which MCP tools are available?▼

Add allowedTools or disabledTools glob patterns to a server's config entry, such as "allowedTools": ["read_*"] or "disabledTools": ["delete_*"]. Blacklist rules take precedence and filtering applies to info, grep, and call operations.