Skip to content

MCP Client Setup

Once mcp-api-test is installed, configure your MCP client to connect to the server.

OpenCode

Edit opencode.json at your project root:

{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "mcp-api-test": {
      "type": "local",
      "command": ["mcp-api-test"],
      "enabled": true
    }
  }
}

Claude Desktop

Edit claude_desktop_config.json (usually at ~/Library/Application Support/Claude/claude_desktop_config.json on macOS):

{
  "mcpServers": {
    "mcp-api-test": {
      "command": "mcp-api-test"
    }
  }
}

Restart Claude Desktop after saving the configuration.

MCP Inspector

The MCP Inspector provides a browser-based UI to verify your server connects and responds correctly before wiring it into an AI client.

Make sure mcp-api-test is installed on your PATH (see Installation), then run:

npx @modelcontextprotocol/inspector

This launches the inspector and opens http://localhost:5173 in your browser. From the UI:

  1. Set Transport Type to STDIO
  2. Set Command to mcp-api-test
  3. Leave Arguments empty
  4. Click Connect

When the connection succeeds, the status badge changes to Connected and the inspector lists the run_test_api tool under the Tools tab. You can click the tool to open a form and run test calls interactively.

Note

If the status shows "Failed to connect", double-check that which mcp-api-test resolves and that pip install -e . completed without errors.