MCP Servers
Model Context Protocol (MCP) servers extend your agent with standardized tools from a 13,000+ server ecosystem. Connect to filesystems, APIs, databases, and more.
What is MCP?#
The Model Context Protocol (MCP) is an open standard originally developed by Anthropic for connecting AI agents to external tools and data sources. It was donated to the Linux Foundation's Agentic AI Foundation in late 2025 and is co-governed by Anthropic, OpenAI, and Block.
MCP servers are lightweight programs that expose tools (functions the AI can invoke), resources (data for context), and prompts (templates). They communicate via JSON-RPC 2.0 over stdio or HTTP.
Portable
MCP servers work with any MCP-compatible host: OpenClaw, Claude Code, Cursor, VS Code, and more.
Standardized
JSON-RPC 2.0 protocol with typed schemas. No custom integration code needed.
Ecosystem
13,000+ community servers on registries like npm, PyPI, and mcp.run.
Available MCP Servers#
Lobstack pre-configures these MCP servers. Enable them from Dashboard → Skills → MCP.
| Server | Package | Category | Description |
|---|---|---|---|
| Filesystem | @modelcontextprotocol/server-filesystem | Filesystem | Read, write, search files in the agent workspace |
| Web Fetch | @modelcontextprotocol/server-fetch | Search | Fetch and extract content from URLs |
| GitHub | @modelcontextprotocol/server-github | Development | Interact with repos, issues, PRs, and actions |
| Memory | @modelcontextprotocol/server-memory | Data | Persistent key-value memory across conversations |
| Slack | @modelcontextprotocol/server-slack | Communication | Read and send Slack messages, manage channels |
How It Works#
When an MCP server is enabled, OpenClaw spawns it as a child process and discovers its available tools. The AI model can then call those tools naturally during conversation, just like built-in tools.
1. Agent starts -> OpenClaw reads openclaw.json
2. For each mcpServers entry:
a. Spawn process (npx/node/python command)
b. Initialize JSON-RPC 2.0 connection
c. Discover available tools via "tools/list"
d. Register tools in agent's tool inventory
3. During conversation:
a. AI model decides to call an MCP tool
b. OpenClaw forwards the call to the server
c. Server executes and returns results
d. Results passed back to the AI modelConfiguration#
MCP servers are configured in the mcpServers section of openclaw.json:
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/root/.openclaw/workspace"]
},
"github": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": {
"GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_your_token_here"
}
}
}
}Configuration Fields#
| Field | Type | Description |
|---|---|---|
| command | string | Command to spawn the server (npx, node, python, uvx) |
| args | string[] | Arguments passed to the command |
| env | object | Environment variables for the server process |
MCP vs Skills#
| Aspect | MCP Servers | OpenClaw Skills |
|---|---|---|
| Protocol | JSON-RPC 2.0 (standardized) | Markdown + YAML frontmatter |
| Runtime | External process (child process) | Runs inside OpenClaw gateway |
| Portability | Works with any MCP host | OpenClaw-specific |
| Ecosystem | 13,000+ servers | 5,700+ on ClawHub |
| Use Case | Structured tool access | Natural language task guidance |
| Best For | APIs, databases, file systems | Workflows, specialized tasks |
Use both
Security#
MCP servers run on the agent VM with these security measures:
- Process isolation — Each MCP server runs as a separate child process
- Workspace scoping — Filesystem server restricted to /root/.openclaw/workspace
- Credential management — API keys stored via Lobstack's encrypted credential system
- Audit logging — MCP server enable/disable actions are logged
Community servers
API Reference#
List MCP Servers#
curl -b "sb-access-token=YOUR_TOKEN" \
"https://lobstack.ai/api/agent/mcp"Enable/Disable MCP Server#
curl -X POST -H "Content-Type: application/json" \
-b "sb-access-token=YOUR_TOKEN" \
-d '{"serverId": "github", "enabled": true, "env": {"GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_..."}}' \
"https://lobstack.ai/api/agent/mcp"