Skip to main content

Overview

Server configurations define how the testing framework connects to your MCP servers. Each server configuration specifies:
  • Server URL for HTTP connections
  • Authentication settings (if required)
  • Server identification for test reporting

Server Configuration Format

Basic Configuration:
{
  "name": "Your Server Name",
  "url": "https://your-server.com/mcp"
}

Required Fields

  • name (string) - Server identifier used in test reporting and CLI commands
  • url (string) - Full HTTP/HTTPS URL to your MCP server endpoint

Optional Fields

  • authorization_token (string | null) - Bearer token for API authentication (default: null)
  • oauth (boolean) - Enable OAuth 2.0 authentication flow (default: false)

Authentication Configuration

No Authentication

For public MCP servers that don’t require authentication:
{
  "name": "Public MCP Server",
  "url": "https://public-mcp-server.com/mcp"
}

Bearer Token Authentication

For servers requiring API keys or bearer tokens:
{
  "name": "Authenticated MCP Server",
  "url": "https://secure-server.com/mcp",
  "authorization_token": "your-api-key-here"
}

OAuth 2.0 Authentication

For servers requiring OAuth authentication:
{
  "name": "OAuth MCP Server",
  "url": "https://oauth-server.com/mcp",
  "oauth": true
}
OAuth Implementation Details:
  • Framework automatically handles OAuth authorization code flow
  • Opens browser for user authentication
  • Manages token storage (per test run)
  • Supports PRM discovery

Configuration Storage

Store server configs in your project directory:
./configs/servers/
├── my-server.json
├── staging-server.json
└── production-server.json

Global Configuration

Store configs system-wide for reuse across projects: Linux/macOS: ~/.config/mcp-t/servers/ Windows: %APPDATA%/mcp-t/servers/

Configuration Precedence

  1. Local configs (./configs/servers/) - highest priority
  2. Global configs (~/.config/mcp-t/servers/) - fallback
Environment variables are substituted automatically when loading configurations.

CLI Commands for Server Management

Create Server Configuration

mcp-t create server
Interactive wizard for creating new server configurations with templates.

List Servers

mcp-t list
# or
mcp-t list servers
Display all available server configurations.

Show Server Details

mcp-t show server <server-id>
Display detailed configuration for a specific server.

Run Tests Against Server

mcp-t run <suite-id> <server-id>
Execute test suites against a specific server configuration.

Example Configurations

HackerNews Server (No Auth)

{
  "name": "hackernews_mcp_server",
  "url": "https://hackernews-mcp-server.example.com/mcp"
}

Authenticated API Server

{
  "name": "secured_api_server",
  "url": "https://api.example.com/mcp",
  "authorization_token": "sk-1234567890abcdef"
}

OAuth-Protected Server

{
  "name": "oauth_protected_server",
  "url": "https://oauth.example.com/mcp",
  "oauth": true
}

Next Steps

Now that you understand server configuration:
  1. Test config - How to structure tests for your servers
  2. CLI Reference - All available CLI commands
  3. Security testing - Authentication and security test capabilities
I