mcp-cli

obra/superpowers-lab · updated Apr 8, 2026

MDX-style export adds YAML metadata + attribution linking explainx.ai and this canonical listing URL.

$npx skills add https://github.com/obra/superpowers-lab --skill mcp-cli
0 commentsdiscussion
summary

Use the mcp CLI tool to dynamically discover and invoke MCP server capabilities without pre-configuring them as permanent integrations.

skill.md

MCP CLI: On-Demand MCP Server Usage

Use the mcp CLI tool to dynamically discover and invoke MCP server capabilities without pre-configuring them as permanent integrations.

When to Use This Skill

Use this skill when you need to:

  • Explore an MCP server's capabilities before deciding to use it
  • Make one-off calls to an MCP server without permanent integration
  • Access MCP functionality without polluting the context window
  • Test or debug MCP servers
  • Use MCP servers that aren't pre-configured

Prerequisites

The mcp CLI must be installed at ~/.local/bin/mcp. If not present:

# Clone and build
cd /tmp && git clone --depth 1 https://github.com/f/mcptools.git
cd mcptools && CGO_ENABLED=0 go build -o ~/.local/bin/mcp ./cmd/mcptools

Always ensure PATH includes the binary:

export PATH="$HOME/.local/bin:$PATH"

Discovery Workflow

Step 1: Discover Available Tools

mcp tools <server-command>

Examples:

# Filesystem server
mcp tools npx -y @modelcontextprotocol/server-filesystem /path/to/allow

# Memory/knowledge graph server
mcp tools npx -y @modelcontextprotocol/server-memory

# GitHub server (requires token)
mcp tools docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN ghcr.io/github/github-mcp-server

# HTTP-based server
mcp tools https://example.com/mcp

Step 2: Discover Resources (if supported)

mcp resources <server-command>

Resources are data sources the server exposes (files, database entries, etc.).

Step 3: Discover Prompts (if supported)

mcp prompts <server-command>

Prompts are pre-defined prompt templates the server provides.

Step 4: Get Detailed Info (JSON format)

# For full schema details including parameter types
mcp tools --format json <server-command>
mcp tools --format pretty <server-command>

Making Tool Calls

Basic Syntax

mcp call <tool_name> --params '<json>' <server-command>

Examples

Read a file:

mcp call read_file --params '{"path": "/tmp/example.txt"}' \
  npx -y @modelcontextprotocol/server-filesystem /tmp

Write a file:

mcp call write_file --params '{"path": "/tmp/test.txt", "content": "Hello world"}' \
  npx -y @modelcontextprotocol/server-filesystem /tmp

List directory:

mcp call list_directory --params '{"path": "/tmp"}' \
  npx -y @modelcontextprotocol/server-filesystem /tmp

Create entities (memory server):

mcp call create_entities --params '{"entities": [{"name": "Project", "entityType": "Software", "observations": ["Uses TypeScript"]}]}' \
  npx -y @modelcontextprotocol/server-memory

Search (memory server):

mcp call search_nodes --params '{"query": "TypeScript"}' \
  npx -y @modelcontextprotocol/server-memory

Complex Parameters

For nested objects and arrays, ensure valid JSON:

mcp call edit_file --params '{
  "path": "/tmp/file.txt",
  "edits": [
    {"oldText": "foo", "newText": "bar"},
    {"oldText": "baz", "newText": "qux"}
  ]
}' npx -y @modelcontextprotocol/server-filesystem /tmp

Output Formats

# Table (default, human-readable)
mcp call <tool> --params '{}' <server>

# JSON (for parsing)
mcp call <tool> --params '{}' -f json <server>

# Pretty JSON (readable JSON)
mcp call <tool> --params '{}' -f pretty <server>

Reading Resources

# List available resources
mcp resources <server-command>

# Read a specific resource
mcp read-resource <resource-uri> <server-command>

# Alternative syntax
mcp call resource:<resource-uri> <server-command>

Using Prompts

# List available prompts
mcp prompts <server-command>

# Get a prompt (may require arguments)
mcp get-prompt <prompt-name> <server-command>

# With parameters
mcp get-prompt <prompt-name> --params '{"arg": "value"}' <server-command>

Server Aliases (for repeated use)

If using a server frequently during a session:

# Create alias
mcp alias add fs npx -y @modelcontextprotocol/server-filesystem /home/user

# Use alias
mcp tools fs
mcp call read_file --params '{"path": "README.md"}' fs

# List aliases
mcp alias list

# Remove when done
mcp alias remove fs

Aliases are stored in ~/.mcpt/aliases.json.

Authentication

HTTP Basic Auth

mcp tools --auth-user "username:password" https://api.example.com/mcp

Bearer Token

mcp tools --auth-header "Bearer your-token-here" https://api.example.com/mcp

Environment Variables (for Docker-based servers)

mcp tools docker run -i --rm \
  -e GITHUB_PERSONAL_ACCESS_TOKEN="$GITHUB_TOKEN" \
  ghcr.io/github/github-mcp-server

Transport Types

Stdio (default for npx/node commands)

mcp tools npx -y @modelcontextprotocol/server-filesystem /tmp

HTTP (auto-detected for http/https URLs)

mcp tools https://example.com/mcp

SSE (Server-Sent Events)

mcp tools http://localhost:3001/sse
# Or explicitly:
mcp tools --transport sse http://localhost:3001

Common MCP Servers

Filesystem

# Allow access to specific directory
mcp tools npx -y @modelcontextprotocol/server-filesystem /path/to/allow

Memory (Knowledge Graph)

mcp tools npx -y @modelcontextprotocol/server-memory

GitHub

export GITHUB_PERSONAL_ACCESS_TOKEN="your-token"
mcp tools docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN ghcr.io/github/github-mcp-server

Brave Search

export BRAVE_API_KEY="your-key"
mcp tools npx -y @anthropic/mcp-server-brave-search

Puppeteer (Browser Automation)

mcp tools npx -y @anthropic/mcp-server-puppeteer

Best Practices

1. Always Discover First

Before calling tools, run mcp tools to understand what's available and the exact parameter schema.

2. Use JSON Format for Parsing

When you need to process results programmatically:

mcp call <tool> --params '{}' -f json <server> | jq '.field'

3. Validate Parameters

The table output shows parameter signatures. Match them exactly:

  • param:str = string
  • param:num = number
  • param:bool = boolean
  • param:str[] = array of strings
  • [param:str] = optional parameter

4. Handle Errors Gracefully

Tool calls may fail. Check exit codes and stderr:

if ! result=$(mcp call tool --params '{}' server 2>&1); then
  echo "Error: $result"
fi

5. Use Aliases for Multi-Step Operations

If making several calls to the same server:

mcp alias add tmp-server npx -y @modelcontextprotocol/server-filesystem /tmp
mcp call list_directory --params '{"path": "/tmp"}' tmp-server
mcp call read_file --params '{"path": "/tmp/file.txt"}' tmp-server
mcp alias remove tmp-server

6. Restrict Capabilities with Guard

For safety, limit what tools are accessible:

# Only allow read operations
mcp guard --allow 'tools:read_*,list_*' --deny 'tools:write_*,delete_*' \
  npx -y @modelcontextprotocol/server-filesystem /home

Debugging

View Server Logs

mcp tools --server-logs <server-command>

Check Alias Configuration

cat ~/.mcpt/aliases.json

Verbose Output

Use --format pretty for detailed JSON output to debug parameter issues.

Quick Reference

Action Command
List tools mcp tools <server>
List resources mcp resources <server>
List prompts mcp prompts <server>
Call tool mcp call <tool> --params '<json>' <server>
Read resource mcp read-resource <uri> <server>
Get prompt mcp get-prompt <name> <server>
Add alias mcp alias add <name> <server-command>
Remove alias mcp alias remove <name>
JSON output Add -f json or -f pretty

Example: Complete Workflow

# 1. Discover what's available
mcp tools npx -y @modelcontextprotocol/server-filesystem /home/user/project

# 2. Check for resources
mcp resources npx -y @modelcontextprotocol/server-filesystem /home/user/project

# 3. Create alias for convenience
how to use mcp-cli

How to use mcp-cli on Cursor

AI-first code editor with Composer

1

Prerequisites

Before installing skills in Cursor, ensure your development environment meets these requirements:

  • Cursor installed and configured on your development machine
  • Node.js version 16.0+ with npm package manager (verify with node --version)
  • Active project directory or workspace where you want to add mcp-cli
2

Execute installation command

Execute the skills CLI command in your project's root directory to begin installation:

$npx skills add https://github.com/obra/superpowers-lab --skill mcp-cli

The skills CLI fetches mcp-cli from GitHub repository obra/superpowers-lab and configures it for Cursor.

3

Select Cursor when prompted

The CLI will show a list of available agents. Use arrow keys to navigate and space to select Cursor:

◆ Which agents do you want to install to?
│ ── Universal (.agents/skills) ── always included ────
│ • Amp
│ • Antigravity
│ • Cline
│ • Codex
│ ●Cursor(selected)
│ • Cursor
│ • Windsurf
4

Verify installation

Confirm successful installation by checking the skill directory location:

.cursor/skills/mcp-cli

Reload or restart Cursor to activate mcp-cli. Access the skill through slash commands (e.g., /mcp-cli) or your agent's skill management interface.

Security & Verification Notice

We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.

Skills execute code in your development environment. Always verify the publisher's identity, review recent commits, and test in isolated environments before production deployment.

List & Monetize Your Skill

Submit your Claude Code skill and start earning

GET_STARTED →

Use Cases

User Story & Requirements Generation

Create detailed user stories, acceptance criteria, and feature specs

Example

Generate user stories for 'password reset feature' with acceptance criteria, edge cases, and test scenarios

Reduce spec writing time by 50%, ensure comprehensive coverage

Competitive Analysis

Research competitors, compare features, identify gaps

Example

Analyze 5 competitor products, create feature comparison matrix, suggest differentiation opportunities

Complete competitive research in 2 hours instead of 2 days

Roadmap Prioritization

Evaluate features using frameworks (RICE, ICE, Kano) and create prioritized backlogs

Example

Score 20 feature ideas using RICE framework, generate prioritized roadmap with rationale

Make data-driven prioritization decisions faster

Stakeholder Communication

Draft PRDs, status updates, and stakeholder presentations

Example

Create executive summary of Q3 roadmap, monthly progress report, feature launch announcement

Save 3-5 hours/week on communication overhead

Implementation Guide

Prerequisites

  • Claude Desktop or compatible AI client
  • Access to product documentation and roadmap tools (Jira, Notion, etc.)
  • Understanding of product management frameworks (RICE, Jobs-to-be-Done, etc.)
  • Stakeholder contact information and communication channels

Time Estimate

30-60 minutes to see productivity improvements

Installation Steps

  1. 1.Install product management skill
  2. 2.Start with user story generation for known feature
  3. 3.Progress to competitive analysis: research 2-3 competitors
  4. 4.Use for roadmap prioritization: apply RICE/ICE scoring
  5. 5.Draft stakeholder communications and refine based on feedback
  6. 6.Build template library for recurring PM tasks
  7. 7.Share effective prompts with product team

Common Pitfalls

  • Not validating competitive research—verify facts before sharing
  • Accepting user stories without involving engineering team
  • Over-relying on frameworks without qualitative judgment
  • Not customizing outputs to company culture and communication style
  • Skipping stakeholder validation of generated requirements

Best Practices

✓ Do

  • +Validate research and competitive analysis with real data
  • +Collaborate with engineering when generating technical requirements
  • +Customize frameworks and templates to your company context
  • +Use skill for first drafts, refine with stakeholder input
  • +Document successful prompt patterns for PM tasks
  • +Combine AI efficiency with human judgment and intuition

✗ Don't

  • Don't publish competitive analysis without fact-checking
  • Don't finalize user stories without engineering review
  • Don't make prioritization decisions solely on AI scoring
  • Don't skip customer validation of generated requirements
  • Don't ignore company-specific context and culture

💡 Pro Tips

  • Provide context: company goals, constraints, customer feedback
  • Ask for alternatives: 'Show 3 ways to prioritize this roadmap'
  • Request stakeholder-specific formatting: 'Executive summary vs. engineering spec'
  • Use skill for 70% generation + 30% customization to company needs

When to Use This

✓ Use When

Use for user story writing, competitive research, roadmap prioritization, stakeholder communication, and PRD drafting. Best for reducing repetitive documentation and research work.

✗ Avoid When

Avoid for strategic product vision (requires deep customer empathy), pricing decisions (needs market and financial expertise), or when face-to-face customer discovery is more valuable than speed.

Learning Path

  1. 1Basic: user stories, feature specs, status updates
  2. 2Intermediate: competitive analysis, prioritization frameworks, PRDs
  3. 3Advanced: product strategy, go-to-market planning, OKR setting
  4. 4Expert: product vision, market positioning, business model innovation

Discussion

Product Hunt–style comments (not star reviews)
  • No comments yet — start the thread.
general reviews

Ratings

4.562 reviews
  • Noah Smith· Dec 28, 2024

    mcp-cli reduced setup friction for our internal harness; good balance of opinion and flexibility.

  • Meera Mehta· Dec 24, 2024

    Solid pick for teams standardizing on skills: mcp-cli is focused, and the summary matches what you get after install.

  • Ama Jackson· Dec 20, 2024

    We added mcp-cli from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.

  • Ira Abebe· Dec 20, 2024

    Registry listing for mcp-cli matched our evaluation — installs cleanly and behaves as described in the markdown.

  • Ganesh Mohane· Dec 4, 2024

    Solid pick for teams standardizing on skills: mcp-cli is focused, and the summary matches what you get after install.

  • Kabir Wang· Dec 4, 2024

    mcp-cli is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

  • Maya Anderson· Dec 4, 2024

    mcp-cli fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.

  • Ama White· Nov 23, 2024

    mcp-cli fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.

  • Carlos Thomas· Nov 19, 2024

    I recommend mcp-cli for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.

  • Kabir Iyer· Nov 11, 2024

    Keeps context tight: mcp-cli is the kind of skill you can hand to a new teammate without a long onboarding doc.

showing 1-10 of 62

1 / 7