MCP Server Studio
MCP server bridging Claude.ai/Desktop with self-hosted OpenClaw via OAuth 2.1.
Registry name: io.github.freema/openclaw-mcp
Add to claude_desktop_config.json:
{
"mcpServers": {
"openclaw-mcp": {
"command": "npx",
"args": [
"-y",
"[email protected]"
],
"env": {
"OPENCLAW_URL": "<OPENCLAW_URL>",
"OPENCLAW_GATEWAY_TOKEN": "<OPENCLAW_GATEWAY_TOKEN>",
"OPENCLAW_MODEL": "<OPENCLAW_MODEL>",
"OPENCLAW_TIMEOUT_MS": "<OPENCLAW_TIMEOUT_MS>"
}
}
}
}Run in your terminal:
claude mcp add openclaw-mcp -e OPENCLAW_URL='<OPENCLAW_URL>' -e OPENCLAW_GATEWAY_TOKEN='<OPENCLAW_GATEWAY_TOKEN>' -e OPENCLAW_MODEL='<OPENCLAW_MODEL>' -e OPENCLAW_TIMEOUT_MS='<OPENCLAW_TIMEOUT_MS>' -- npx -y [email protected]Add to .cursor/mcp.json:
{
"mcpServers": {
"openclaw-mcp": {
"command": "npx",
"args": [
"-y",
"[email protected]"
],
"env": {
"OPENCLAW_URL": "<OPENCLAW_URL>",
"OPENCLAW_GATEWAY_TOKEN": "<OPENCLAW_GATEWAY_TOKEN>",
"OPENCLAW_MODEL": "<OPENCLAW_MODEL>",
"OPENCLAW_TIMEOUT_MS": "<OPENCLAW_TIMEOUT_MS>"
}
}
}
}Add to .vscode/mcp.json:
{
"servers": {
"openclaw-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"[email protected]"
],
"env": {
"OPENCLAW_URL": "<OPENCLAW_URL>",
"OPENCLAW_GATEWAY_TOKEN": "<OPENCLAW_GATEWAY_TOKEN>",
"OPENCLAW_MODEL": "<OPENCLAW_MODEL>",
"OPENCLAW_TIMEOUT_MS": "<OPENCLAW_TIMEOUT_MS>"
}
}
}
}Add to ~/.codeium/windsurf/mcp_config.json:
{
"mcpServers": {
"openclaw-mcp": {
"command": "npx",
"args": [
"-y",
"[email protected]"
],
"env": {
"OPENCLAW_URL": "<OPENCLAW_URL>",
"OPENCLAW_GATEWAY_TOKEN": "<OPENCLAW_GATEWAY_TOKEN>",
"OPENCLAW_MODEL": "<OPENCLAW_MODEL>",
"OPENCLAW_TIMEOUT_MS": "<OPENCLAW_TIMEOUT_MS>"
}
}
}
}| Name | Required | What it is |
|---|---|---|
OPENCLAW_URL | Yes | URL of your OpenClaw gateway |
OPENCLAW_GATEWAY_TOKEN | Yes | Bearer token for OpenClaw gateway authentication |
OPENCLAW_MODEL | No | Model name for chat completions (e.g. 'openclaw' or 'openclaw/<agentId>') |
OPENCLAW_TIMEOUT_MS | No | Gateway request timeout in milliseconds (idle timeout for streamed async tasks) |
OPENCLAW_URL | Yes | URL of your OpenClaw gateway |
OPENCLAW_GATEWAY_TOKEN | Yes | Bearer token for OpenClaw gateway authentication |
OPENCLAW_MODEL | No | Model name for chat completions |