Capsule CRM MCP Server
Enables AI assistants to access and query Capsule CRM data (contacts, opportunities, support cases, tasks, projects, products) through natural language, with read-only security.
README
Capsule CRM MCP Server
Connect your Capsule CRM data to AI assistants — Access contacts, opportunities, support cases, and more through natural language queries, with complete read-only security.
🚨 Disclaimer: This project is created by Fuzzy Labs with good vibes and is not officially supported by Capsule CRM. Use at your own discretion.
What This Does
Transform how you work with your Capsule CRM data by asking AI assistants natural language questions like:
- "Show me my recent contacts"
- "What opportunities are closing this month?"
- "Find all support cases from last week"
- "List tasks assigned to Sarah"
- "What products do we sell in the UK?"
🔒 Read-Only & Secure — No write access to your CRM data
🚀 Instant Setup — Works with any MCP-compatible AI assistant
📊 Complete Coverage — Access contacts, sales, support, tasks, projects & more
Quick Start
1. Get Your Capsule API Token
- Log into your Capsule CRM account
- Go to My Preferences → API Authentication
- Create a new API token and copy it
2. Install & Configure
macOS Setup
# Install uv (Python package manager)
curl -LsSf https://astral.sh/uv/install.sh | sh
# Clone and install
git clone https://github.com/fuzzylabs/capsule-mcp.git
cd capsule-mcp
uv sync
Linux/Windows Setup
# Install uv
curl -LsSf https://astral.sh/uv/install.sh | sh # Linux/macOS
# OR for Windows: powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
# Clone and install
git clone https://github.com/fuzzylabs/capsule-mcp.git
cd capsule-mcp
uv sync
3. Connect to Your AI Assistant
Claude Desktop
Add this to your Claude Desktop config file:
Config Location:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%/Claude/claude_desktop_config.json
{
"mcpServers": {
"capsule-crm": {
"command": "uv",
"args": [
"run",
"--directory",
"/path/to/your/capsule-mcp",
"python",
"capsule_mcp/server.py"
],
"env": {
"CAPSULE_API_TOKEN": "your_capsule_api_token_here"
}
}
}
}
Cursor
📋 Quick Setup:
Copy this Cursor deeplink and paste it in your browser address bar:
cursor://anysphere.cursor-deeplink/mcp/install?name=capsule-crm&config=eyJjYXBzdWxlLWNybSI6eyJjb21tYW5kIjoidXYiLCJhcmdzIjpbInJ1biIsIi0tZGlyZWN0b3J5IiwiL3BhdGgvdG8veW91ci9jYXBzdWxlLW1jcCIsInB5dGhvbiIsImNhcHN1bGVfbWNwL3NlcnZlci5weSJdLCJlbnYiOnsiQ0FQU1VMRV9BUElfVE9LRU4iOiJ5b3VyX2NhcHN1bGVfYXBpX3Rva2VuX2hlcmUifX19
**💡 How to use:**
1. Copy the entire `cursor://` URL above
2. Paste it into your browser's address bar
3. Press Enter - this will open Cursor and prompt to install the MCP server
**Note:** After clicking the button, you'll need to:
1. Update the path `/path/to/your/capsule-mcp` to your actual installation directory
2. Replace `your_capsule_api_token_here` with your actual Capsule CRM API token
Or manually add this to your Cursor MCP settings:
```json
{
"capsule-crm": {
"command": "uv",
"args": [
"run",
"--directory",
"/path/to/your/capsule-mcp",
"python",
"capsule_mcp/server.py"
],
"env": {
"CAPSULE_API_TOKEN": "your_capsule_api_token_here"
}
}
}
Other MCP Clients
This server is compatible with any MCP client. Refer to your client's documentation for MCP server configuration.
💡 Setup Help:
- Using uv (recommended): Use
uv runcommand as shown above - no Python path needed! - uv path for Claude Desktop: Use full path
~/.local/bin/uv(find yours withwhich uv) - Manual Python paths (if not using uv):
- macOS (Homebrew):
/opt/homebrew/bin/python3(Apple Silicon) or/usr/local/bin/python3(Intel) - macOS (System):
/usr/bin/python3(if available) - Find your Python: Run
which python3in terminal - Windows: Try
C:\Python311\python.exe
- macOS (Homebrew):
4. Start Using
- Restart your AI assistant
- Start asking questions!
Try these example queries:
"List my Capsule contacts"
"Show me open opportunities closing this month"
"What support cases need attention?"
"Find contacts from @example.com"
What You Can Access
This MCP server provides complete read-only access to your Capsule CRM:
| Data Type | What You Can Do |
|---|---|
| 👥 Contacts | List, search, view details, find recent activity |
| 💼 Sales | View opportunities, pipeline stages, sales forecasts |
| 🎫 Support | Access cases, search issues, track resolution |
| ✅ Tasks | View task lists, assignments, deadlines |
| 📝 Timeline | Read notes, emails, calls, meeting records |
| 📋 Projects | Access project data and status |
| 🏷️ Organization | View tags, users, custom fields, configuration |
| 🛍️ Products | Browse product catalog and categories |
➡️ View Complete Tool Reference
Troubleshooting
Common Issues
"No module named 'capsule_mcp'"
- Using uv: Make sure you're using the absolute directory path with
uv run --directory - Manual setup: Verify Python can find the installed packages:
pip list | grep fastmcp
"spawn uv ENOENT" or "command not found: uv"
- Install uv first:
curl -LsSf https://astral.sh/uv/install.sh | sh - Restart your terminal after installation
- Verify installation:
uv --version
"spawn python ENOENT" (if not using uv)
- Switch to uv setup (recommended) or use full Python path in config
- Check your Python path:
which python3 - Try different common paths:
/usr/bin/python3,/usr/local/bin/python3,/opt/homebrew/bin/python3
"Authentication failed"
- Verify your Capsule API token is correct
- Check the token has appropriate permissions in Capsule CRM
MCP tools not showing in your AI assistant
- Restart your AI assistant after config changes
- Check the config file syntax is valid JSON
- Verify file paths are absolute, not relative
Getting Help
- Issues & Bugs: GitHub Issues
- Capsule API Docs: developer.capsulecrm.com
- MCP Protocol: modelcontextprotocol.io
Render Deployment (Secure Remote HTTP Access)
Want to deploy the MCP server remotely so multiple users can access it via HTTP? Deploy to Render for easy cloud hosting with API key authentication.
Quick Deploy
Manual Deployment
-
Fork this repository to your GitHub account
-
Create a Render account at render.com
-
Create a new Web Service and connect your GitHub fork
-
Configure the service:
- Build Command:
pip install -r requirements.txt - Start Command:
uvicorn capsule_mcp.server:app --host 0.0.0.0 --port $PORT - Plan: Free (or choose a paid plan for better performance)
- Build Command:
-
Set environment variables in Render dashboard:
CAPSULE_API_TOKEN: Your Capsule CRM API tokenMCP_API_KEY: A secure random API key for authentication (see generation instructions below)
-
Deploy - Render will automatically build and deploy your service
Generating a Secure API Key
Generate a secure random API key for the MCP_API_KEY environment variable:
# Using Python
python -c "import secrets; print(secrets.token_urlsafe(32))"
# Using OpenSSL
openssl rand -base64 32
# Using Node.js
node -e "console.log(require('crypto').randomBytes(32).toString('base64'))"
⚠️ Important: Store this API key securely - you'll need it to configure your MCP clients.
Using Your Deployed Server
Once deployed, you'll get a URL like https://your-service.onrender.com. Configure your MCP clients to use:
Claude Desktop:
{
"mcpServers": {
"capsule-crm": {
"command": "curl",
"args": [
"-X", "POST",
"https://your-service.onrender.com/mcp/",
"-H", "Content-Type: application/json",
"-H", "Authorization: Bearer YOUR_MCP_API_KEY_HERE",
"-d", "@-"
]
}
}
}
Replace YOUR_MCP_API_KEY_HERE with the API key you generated and set in Render.
🔒 Security Note: The API key authentication is only enforced when the MCP_API_KEY environment variable is set. If no API key is configured, the server will accept unauthenticated requests (useful for local development).
Direct HTTP Access:
# List available tools
curl -X POST https://your-service.onrender.com/mcp/ \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_MCP_API_KEY_HERE" \
-d '{"jsonrpc": "2.0", "method": "tools/list", "id": 1}'
# List contacts
curl -X POST https://your-service.onrender.com/mcp/ \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_MCP_API_KEY_HERE" \
-d '{
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"name": "list_contacts",
"arguments": {"page": 1, "per_page": 10}
},
"id": 1
}'
⚠️ Note on Free Tier: Render's free tier spins down services after inactivity. First requests may take 30-60 seconds to wake up the service.
For Developers
Development Setup
Environment Variables (for development):
cp .env.example .env
# Edit .env and set CAPSULE_API_TOKEN=your_token_here
Run Tests:
uv run pytest
HTTP Server (for testing):
uv run uvicorn capsule_mcp.server:app --reload
# Server available at http://localhost:8000/mcp/
API Testing
Test the schema endpoint:
curl -X POST http://localhost:8000/mcp/ \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{
"jsonrpc": "2.0",
"method": "tools/list",
"id": 1
}'
Test listing contacts:
curl -X POST http://localhost:8000/mcp/ \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"name": "list_contacts",
"arguments": {"page": 1, "per_page": 10}
},
"id": 1
}'
Architecture
- Server: FastMCP framework with FastAPI backend
- Protocol: Model Context Protocol (MCP) via stdio
- API: Capsule CRM API v2 with read-only access
- Authentication: Bearer token (OAuth2)
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。