AgentStack
MCP verified MIT Self-run

Cmcp

mcp-russellluo-cmcp · by RussellLuo

A command-line utility for interacting with MCP servers.

No reviews yet
0 installs
14 views
0.0% view→install

Install

$ agentstack add mcp-russellluo-cmcp

✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access Used
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

Are you the author of Cmcp? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

cMCP

cmcp is a command-line utility that helps you interact with [MCP][1] servers. It's basically curl for MCP servers.

Installation

pip install cmcp

Usage

STDIO

Interact with the STDIO server:

cmcp COMMAND METHOD

Add required parameters:

cmcp COMMAND METHOD param1=value param2:='{"arg1": "value"}'

Add required environment variables:

cmcp COMMAND METHOD ENV_VAR1:value ENV_VAR2:value param1=value param2:='{"arg1": "value"}'

HTTP (or SSE)

Interact with the HTTP (or SSE) server:

cmcp URL METHOD

Add required parameters:

cmcp URL METHOD param1=value param2:='{"arg1": "value"}'

Add required HTTP headers:

cmcp URL METHOD Header1:value Header2:value param1=value param2:='{"arg1": "value"}'

Verbose mode

Enable verbose mode to show JSON-RPC request and response:

cmcp -v COMMAND_or_URL METHOD

Quick Start

Given the following MCP Server (see [here][2]):

# server.py
from mcp.server.fastmcp import FastMCP

# Create an MCP server
mcp = FastMCP("Demo")

# Add a prompt
@mcp.prompt()
def review_code(code: str) -> str:
    return f"Please review this code:\n\n{code}"

# Add a static config resource
@mcp.resource("config://app")
def get_config() -> str:
    """Static configuration data"""
    return "App configuration here"

# Add a dynamic greeting resource
@mcp.resource("greeting://{name}")
def get_greeting(name: str) -> str:
    """Get a personalized greeting"""
    return f"Hello, {name}!"

# Add an addition tool
@mcp.tool()
def add(a: int, b: int) -> int:
    """Add two numbers"""
    return a + b

STDIO transport

List prompts:

cmcp 'mcp run server.py' prompts/list

Get a prompt:

cmcp 'mcp run server.py' prompts/get name=review_code arguments:='{"code": "def greet(): pass"}'

List resources:

cmcp 'mcp run server.py' resources/list

Read a resource:

cmcp 'mcp run server.py' resources/read uri=config://app

List resource templates:

cmcp 'mcp run server.py' resources/templates/list

List tools:

cmcp 'mcp run server.py' tools/list

Call a tool:

cmcp 'mcp run server.py' tools/call name=add arguments:='{"a": 1, "b": 2}'

HTTP transport

Run the above MCP server with HTTP transport:

mcp run server.py -t streamable-http

List prompts:

cmcp http://localhost:8000 prompts/list
# or `cmcp http://localhost:8000/mcp prompts/list`

Get a prompt:

cmcp http://localhost:8000 prompts/get name=review_code arguments:='{"code": "def greet(): pass"}'

List resources:

cmcp http://localhost:8000 resources/list

Read a resource:

cmcp http://localhost:8000 resources/read uri=config://app

List resource templates:

cmcp http://localhost:8000 resources/templates/list

List tools:

cmcp http://localhost:8000 tools/list

Call a tool:

cmcp http://localhost:8000 tools/call name=add arguments:='{"a": 1, "b": 2}'

SSE transport (Deprecated)

Run the above MCP server with SSE transport:

mcp run server.py -t sse

List prompts:

cmcp http://localhost:8000/sse prompts/list

Get a prompt:

cmcp http://localhost:8000/sse prompts/get name=review_code arguments:='{"code": "def greet(): pass"}'

List resources:

cmcp http://localhost:8000/sse resources/list

Read a resource:

cmcp http://localhost:8000/sse resources/read uri=config://app

List resource templates:

cmcp http://localhost:8000/sse resources/templates/list

List tools:

cmcp http://localhost:8000/sse tools/list

Call a tool:

cmcp http://localhost:8000/sse tools/call name=add arguments:='{"a": 1, "b": 2}'

Using mcp.json (Advanced)

For convenience, you can use a configuration file to manage your MCP servers instead of typing the full command or URL each time. By default, cmcp looks for .cmcp/mcp.json (in the current directory) or ~/.cmcp/mcp.json (in your home directory).

The configuration follows the standard MCP JSON format, which is also used by Cursor, Claude Code, FastMCP, and other MCP clients.

Example configuration file:

{
  "mcpServers": {
    "local-server": {
      "command": "python",
      "args": ["mcp-server.py"],
      "env": {
        "API_KEY": "value"
      }
    },
    "remote-server": {
      "url": "http://localhost:3000/mcp",
      "headers": {
        "API_KEY": "value"
      }
    }
  }
}

Use a configured server by prefixing its name with ::

# Use the local-server from config
cmcp :local-server tools/list

# Use the remote-server from config
cmcp :remote-server tools/call name=add arguments:='{"a": 1, "b": 2}'

# Use a custom config file
cmcp --config /path/to/config.json :local-server tools/list

Related Projects

[cA2A][3]: A command-line utility for interacting with A2A agents.

License

[MIT][4]

[1]: https://modelcontextprotocol.io [2]: https://github.com/modelcontextprotocol/python-sdk#quickstart [3]: https://github.com/RussellLuo/ca2a [4]: http://opensource.org/licenses/MIT

Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet — be the first.

Versions

  • v0.1.0 Imported from the upstream source.