🔗 MCP Integration

Model Context Protocol for AI interoperability

Expose as Server Load Servers Claude Desktop
🔗

Two-Way MCP

Expose DevDuck as an MCP server for Claude Desktop, or load external MCP servers to extend capabilities. Full bidirectional protocol support.

🔄 Bidirectional Integration

🦆

DevDuck as Server

Expose DevDuck's tools via MCP protocol for Claude Desktop or other clients

🔌

Load MCP Servers

Import tools from external MCP servers into DevDuck's toolset

📤 Expose DevDuck as MCP Server

Run DevDuck as an MCP server so Claude Desktop or other MCP clients can use its tools.

Stdio Mode (for Claude Desktop)

# Start in MCP stdio mode
devduck --mcp

🖥️ Claude Desktop Configuration

Add to your Claude Desktop config file (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "devduck": {
      "command": "uvx",
      "args": ["devduck", "--mcp"]
    }
  }
}

HTTP Mode (for web clients)

# Start MCP HTTP server
mcp_server(action="start", transport="http", port=8000)

# Access at: http://localhost:8000/mcp

Tool API

# Start MCP server with full agent access
mcp_server(
    action="start",
    transport="http",    # or "stdio"
    port=8000,
    expose_agent=True,   # Expose full DevDuck agent
    agent=devduck.agent
)

# Check status
mcp_server(action="status")

# Stop server
mcp_server(action="stop")

📥 Load External MCP Servers

Import tools from external MCP servers to extend DevDuck's capabilities.

Environment Variable Configuration

# Set MCP_SERVERS with JSON configuration
export MCP_SERVERS='{
  "mcpServers": {
    "strands-docs": {
      "command": "uvx",
      "args": ["strands-agents-mcp-server"]
    },
    "github": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-github"],
      "env": {
        "GITHUB_TOKEN": "your-token"
      }
    }
  }
}'

devduck

Supported Transport Types

Transport Config Keys Example
Stdio command, args, env Local CLI tools, uvx packages
SSE url (with /sse) Server-sent events endpoints
HTTP url, headers Streamable HTTP endpoints

Example: Strands Docs MCP

# Load strands-agents documentation
export MCP_SERVERS='{
  "mcpServers": {
    "strands-docs": {
      "command": "uvx",
      "args": ["strands-agents-mcp-server"],
      "prefix": "strands-docs"
    }
  }
}'

devduck

# Now use the tools:
🦆 strands-docs_search_docs(query="how to use bedrock")

✨ Features

🖥️

Claude Desktop

Run DevDuck as an MCP server for Claude Desktop integration.

🔌

Tool Import

Load tools from any MCP-compatible server into DevDuck.

📡

Multiple Transports

Stdio, HTTP, and SSE transports supported.

🏷️

Tool Prefixing

Imported tools get prefixed to avoid naming conflicts.

🔄

Auto-Load

MCP servers auto-load from MCP_SERVERS env var on startup.

🛡️

Managed Lifecycle

Agent handles MCP client lifecycle automatically.

⚙️ Configuration Reference

Environment Variables

Variable Description
MCP_SERVERS JSON config for auto-loading MCP servers
DEVDUCK_ENABLE_MCP Enable MCP HTTP server on startup (default: false)
DEVDUCK_MCP_PORT MCP HTTP server port (default: 8000)

MCP Server Config Schema

{
  "mcpServers": {
    "server-name": {
      // Stdio transport
      "command": "executable",
      "args": ["arg1", "arg2"],
      "env": {"KEY": "value"},
      
      // OR HTTP/SSE transport
      "url": "http://localhost:8000/mcp",
      "headers": {"Authorization": "Bearer token"},
      
      // Optional
      "prefix": "custom-prefix"  // Default: server-name
    }
  }
}

💡 Use Cases

📚

Documentation Access

Load Strands docs MCP for instant framework documentation.

🐙

GitHub Integration

Load GitHub MCP server for repo management tools.

💬

Claude + DevDuck

Use DevDuck's tools from within Claude Desktop.

🔧

Tool Ecosystem

Access the growing MCP tool ecosystem from DevDuck.