MCP (Model Context Protocol)
DialogBrain exposes all its tools via the Model Context Protocol, making them available to any MCP-compatible AI agent.
Endpoint
https://api.dialogbrain.com/mcp/
Transport: StreamableHTTP (MCP spec 2025-03-26)
Authentication
Two methods are accepted:
| Method | When to use |
|---|---|
| OAuth 2.0 (browser flow) | MCP IDE clients (Claude Code, Cursor, VS Code) |
X-API-Key header | Programmatic access (Python SDK, custom agents) |
IDE Setup
Claude Code:
claude mcp add --transport http dialogbrain https://api.dialogbrain.com/mcp/
VS Code (.vscode/mcp.json):
{ "servers": { "dialogbrain": { "type": "http", "url": "https://api.dialogbrain.com/mcp/" } } }
Cursor (~/.cursor/mcp.json):
{ "mcpServers": { "dialogbrain": { "url": "https://api.dialogbrain.com/mcp/" } } }
Claude Desktop (claude_desktop_config.json):
{ "mcpServers": { "dialogbrain": { "url": "https://api.dialogbrain.com/mcp/" } } }
Available Tools
See All Tools for the complete auto-generated list.
Calling a tool over REST
Every MCP tool can also be called over plain HTTP with the same API key, at POST /api/tools/{tool}/execute. Use the tool's id with a dot (calendar.list_events). The key goes in X-API-Key or Authorization: Bearer. Send X-Workspace-ID to work in another workspace you belong to; without it your key's workspace is used. mode is auto to run the tool, or draft (the default) to get an approval request back for tools that send or change things.
curl -X POST https://api.dialogbrain.com/api/tools/calendar.list_events/execute \
-H "X-API-Key: db_live_..." \
-H "X-Workspace-ID: 123" \
-H "Content-Type: application/json" \
-d '{"tool_id": "calendar.list_events", "params": {}, "mode": "auto"}'
GET /api/tools/catalog lists the tools available to your key.