Skip to main content

MCP Configuration

omx supports Model Context Protocol (MCP) for connecting external tools and data sources.

Configuration File

Create ~/.omx/mcp.json (global) or .omx/mcp.json (project) with your server definitions:

{
"mcpServers": {
"my-server": {
"type": "stdio",
"command": "npx",
"args": ["-y", "my-mcp-server"]
}
}
}

omx also reads Claude's MCP configuration from ~/.claude/claude_desktop_config.json and .claude/mcp.json automatically.

Server Types

Stdio (Local Process)

Launches a local process and communicates over stdin/stdout:

{
"mcpServers": {
"filesystem": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/dir"]
}
}
}

HTTP (Remote Server)

Connects to an HTTP-based MCP server:

{
"mcpServers": {
"remote-tools": {
"type": "http",
"url": "http://localhost:8080/mcp"
}
}
}

Tool Naming

MCP tools appear with a Mcp_ prefix followed by the server name and tool name: Mcp_servername_toolname. This prevents naming conflicts with built-in tools.

Environment Variables

Pass environment variables to stdio servers using the env field:

{
"mcpServers": {
"my-server": {
"type": "stdio",
"command": "node",
"args": ["server.js"],
"env": {
"API_KEY": "your-key-here"
}
}
}
}