MCP Servers

模型上下文协议服务器、框架、SDK 和模板的综合目录。

MCP client CLI that starts an MCP server, performs the protocol handshake, and calls a tool by JSON input.

创建于 4/11/2026
更新于 about 8 hours ago
Repository documentation and setup instructions

mcp-caller

mcp-caller is a small MCP client CLI that starts an MCP server, performs the protocol handshake, and calls a tool by JSON input.

Install

npm install -g mcp-caller

Usage

Call a stdio MCP server:

npx -y mcp-caller \
  --server-json '{"type":"stdio","command":"uvx","args":["--from","git+https://github.com/macsymwang/hello-mcp-server.git","hello-mcp-server"]}' \
  --call-json '{"tool":"say_hello","params":{"name":"world"}}'

PowerShell:

npx -y mcp-caller `
  --server-json '{"type":"stdio","command":"uvx","args":["--from","git+https://github.com/macsymwang/hello-mcp-server.git","hello-mcp-server"]}' `
  --call-json '{"tool":"say_hello","params":{"name":"world"}}'

Call a remote streamable HTTP MCP server:

npx -y mcp-caller \
  --server-json '{"type":"streamable-http","url":"https://gitmcp.io/idosal/git-mcp"}' \
  --call-json '{"tool":"fetch_git_mcp_documentation","params":{}}'

PowerShell:

npx -y mcp-caller `
  --server-json '{"type":"streamable-http","url":"https://gitmcp.io/idosal/git-mcp"}' `
  --call-json '{"tool":"fetch_git_mcp_documentation","params":{}}'

Read JSON from files instead of inline values:

npx -y mcp-caller --server-file server.json --call-file call.json

Short call form:

npx -y mcp-caller --server-file server.json --tool say_hello --params-json '{"name":"world"}'

List callable tools:

npx -y mcp-caller --server-file server.json --list-tools

Inspect tools, prompts, and resources:

npx -y mcp-caller --server-file server.json --inspect --pretty

JSON Shapes

Server JSON:

{
  "mcpServers": {
    "name": {
      "type": "stdio",
      "command": "node",
      "args": ["server.js"]
    }
  }
}

Or a single server object:

{
  "type": "streamable-http",
  "url": "https://example.com/mcp",
  "headers": {}
}

Call JSON:

{
  "tool": "tool-name",
  "params": {}
}

Notes

  • The CLI prints text content when the tool result contains text.
  • Use --pretty to format non-text JSON output.
  • The example probes are covered by test/cli.examples.test.js.