Loading...
Loading...
Once you have MCPX up and running, the next step is to add your first MCP server. This comprehensive guide will walk you through the entire process, from understanding prerequisites to testing your newly added server tools.
Before adding an MCP server, ensure you have:
Alternatively, you can access servers directly:
/org/{orgId}/workspace/{workspaceSlug}/servers/org/{orgId}/serversThe servers page displays:
Let's start with a simple, reliable MCP server - the calculator server. This server provides basic mathematical operations and is perfect for testing.
The modal opens with this default calculator configuration:
{
"calculator": {
"command": "uvx",
"args": [
"mcp-server-calculator"
]
}
}
In the Description field, add a meaningful description:
Basic calculator server providing mathematical operations like addition, subtraction, multiplication, and division.
The JSON configuration follows this structure:
{
"serverName": {
"command": "executable_command",
"args": ["argument1", "argument2"],
"env": {
"VARIABLE_NAME": "value"
}
}
}
Key Components:
serverName: Unique identifier for your servercommand: Executable command or binaryargs: Array of command-line argumentsenv: Environment variables (optional){
"my-python-server": {
"command": "uvx",
"args": ["package-name"],
"env": {
"PYTHON_PATH": "/usr/local/bin/python3"
}
}
}
{
"my-node-server": {
"command": "npx",
"args": ["-y", "@package/mcp-server"],
"env": {
"NODE_ENV": "production"
}
}
}
{
"custom-server": {
"command": "/path/to/binary",
"args": ["--port", "9000", "--config", "/etc/config.json"]
}
}
Common environment variables for MCP servers:
{
"server-with-env": {
"command": "uvx",
"args": ["mcp-server-example"],
"env": {
"API_KEY": "your-api-key",
"DEBUG": "true",
"TIMEOUT": "30000",
"LOG_LEVEL": "info"
}
}
}
For HTTP-based MCP servers:
{
"http-server": {
"command": "curl",
"args": [
"-X", "POST",
"https://api.example.com/mcp",
"-H", "Content-Type: application/json"
],
"env": {
"HTTP_TIMEOUT": "30",
"RETRY_COUNT": "3"
}
}
}
Some MCP servers require OAuth authentication. MCPX handles this automatically.
When adding a server that requires authentication, MCPX will:
[Server Response: 401 Unauthorized]
↓
[MCPX detects OAuth requirement]
↓
[Authentication Dialog appears]
Option 1: Complete Authentication
Option 2: Skip Authentication
pending-auth status{
"github-server": {
"command": "uvx",
"args": ["mcp-server-github"],
"env": {
"GITHUB_CLIENT_ID": "your-client-id",
"REDIRECT_URI": "https://your-mcpx.com/oauth/callback"
}
}
}
After clicking "Add Server", MCPX performs several checks:
| Status | Indicator | Description |
|---|---|---|
| ✅ Healthy | Green dot | Server running and responsive |
| ⚠️ Warning | Yellow dot | Server running with issues |
| ❌ Error | Red dot | Server failed to start or connect |
| 🔄 Starting | Blue pulse | Server initializing |
| 🔐 Auth Required | Lock icon | Requires authentication |
# View server logs (if you have container access)
docker logs mcpx-server-calculator
# Check container health
docker ps | grep mcpx-server
Navigate to: Servers → [Your Server] → Health Check
In the MCPX interface:
When a server is successfully added, MCPX shows available tools:
For the calculator server, you'll see tools like:
calculator__add: Addition operationcalculator__subtract: Subtraction operationcalculator__multiply: Multiplication operationcalculator__divide: Division operationcalculator__add{
"a": 15,
"b": 25
}
{"result": 40}Navigate to Tools page to see all available tools:
// Addition
{"a": 10, "b": 5} → {"result": 15}
// Division with decimals
{"a": 22, "b": 7} → {"result": 3.142857142857143}
// Error handling
{"a": 10, "b": 0} → {"error": "Division by zero"}
// String concatenation
{"strings": ["Hello", " ", "World"]} → {"result": "Hello World"}
Error: A server named 'calculator' already exists in this organization
Solution:
{
"calculator-v2": {
"command": "uvx",
"args": ["mcp-server-calculator"]
}
}
Error: Configuration validation failed: Invalid JSON syntax
Common Issues:
Solution: Use the "Format JSON" button to auto-format and validate.
Error: Server failed to start: command 'uvx' not found
Solutions:
Example Fix:
{
"calculator": {
"command": "/usr/local/bin/uvx",
"args": ["mcp-server-calculator"]
}
}
Error: Port 9000 already in use
Solution: MCPX automatically assigns available ports, but you can specify:
{
"custom-port-server": {
"command": "uvx",
"args": ["mcp-server-example", "--port", "9001"]
}
}
Error: 401 Unauthorized - Authentication required
Debugging Steps:
Error: Server health check timeout
Solutions:
{
"slow-server": {
"command": "uvx",
"args": ["slow-mcp-server"],
"env": {
"STARTUP_TIMEOUT": "60000"
}
}
}
Error: Container failed to start - insufficient resources
Solutions:
Once comfortable with basic servers, explore adding multiple servers:
{
"calculator": {
"command": "uvx",
"args": ["mcp-server-calculator"]
},
"filesystem": {
"command": "uvx",
"args": ["mcp-server-filesystem"],
"env": {
"ALLOWED_PATHS": "/tmp,/var/data"
}
},
"database": {
"command": "npx",
"args": ["-y", "@mcp/server-database"],
"env": {
"DB_CONNECTION": "postgresql://..."
}
}
}
Organize servers by functionality:
Organization-Level Servers:
Workspace-Level Servers:
{
"optimized-server": {
"command": "uvx",
"args": ["mcp-server-example"],
"env": {
"MAX_MEMORY": "512M",
"MAX_CPU": "0.5",
"TIMEOUT": "15000"
}
}
}
{
"cached-server": {
"command": "uvx",
"args": ["mcp-server-cache"],
"env": {
"CACHE_TTL": "3600",
"CACHE_SIZE": "100MB",
"ENABLE_CACHING": "true"
}
}
}
For advanced users, consider developing custom MCP servers:
{
"github": {
"command": "uvx",
"args": ["mcp-server-github"],
"env": {
"GITHUB_TOKEN": "${GITHUB_TOKEN}",
"GITHUB_API_URL": "https://api.github.com",
"DEFAULT_OWNER": "your-org",
"CACHE_ENABLED": "true"
}
}
}
{
"postgres-db": {
"command": "uvx",
"args": ["mcp-server-postgres"],
"env": {
"DATABASE_URL": "${POSTGRES_CONNECTION}",
"QUERY_TIMEOUT": "30000",
"MAX_CONNECTIONS": "10",
"SSL_MODE": "require"
}
}
}
{
"web-scraper": {
"command": "npx",
"args": ["-y", "@mcp/server-puppeteer"],
"env": {
"BROWSER_TIMEOUT": "30000",
"USER_AGENT": "MCPX-WebScraper/1.0",
"ALLOWED_DOMAINS": "example.com,api.service.com"
}
}
}
You've now successfully added your first MCP server to MCPX! This opens up a world of possibilities for extending your AI workflows with powerful, standardized tools.
Happy server management with MCPX! 🚀