TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/docker/docker-agent/llms.txt
Use this file to discover all available pages before exploring further.
docker agent serve mcp command makes your agents available to any application that supports the Model Context Protocol. This lets you:
- Use custom agents directly within Claude Desktop or Claude Code
- Share specialized agents across different applications
- Build reusable agent teams consumable from any MCP client
- Integrate domain-specific agents into existing workflows
Usage
Flags
| Flag | Default | Description |
|---|---|---|
-a, --agent <name> | (all agents) | Name of the agent to expose |
--http | false | Use streaming HTTP transport instead of stdio |
-l, --listen <addr> | 127.0.0.1:8081 | Address to listen on (HTTP transport only) |
--working-dir <path> | (current dir) | Working directory for the session |
How it works
By default,serve mcp uses stdio transport: the MCP client spawns the docker agent serve mcp process as a subprocess and communicates via stdin/stdout. This requires no network configuration.
With --http, it starts a streaming HTTP server that MCP clients can connect to over the network.
Each agent in your config file becomes a separate tool in the MCP client. For multi-agent configs, all agents are exposed.
Setting up Claude Desktop
Add a server entry to your Claude Desktop MCP configuration file:- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Setting up Claude Code
Multi-agent configs
When you expose a multi-agent configuration, each agent becomes a separate tool:root, designer, engineer) appear as separate tools in the MCP client.
Troubleshooting
| Problem | Solution |
|---|---|
| Agents not appearing | Verify the docker binary path and restart the MCP client |
| Permission errors | Ensure the docker binary has execute permissions |
| Missing API keys | Pass all required keys in the env section |
| Working directory issues | Verify the --working-dir path exists |