Drip MCP Server
Enables AI assistants to manage Drip email marketing automation, including subscriber management, campaigns, workflows, tags, event tracking, and e-commerce integration.
README
Drip MCP Server
A Model Context Protocol (MCP) server that provides seamless integration with the Drip email marketing automation platform. This server enables AI assistants like Claude to interact with Drip's API for subscriber management, campaign automation, and analytics tracking.
🌟 Features
Core Capabilities
- 🧑🤝🧑 Subscriber Management - Create, update, delete, and search subscribers with full custom field support
- 🏷️ Tag Operations - Apply and remove tags for segmentation and automation
- 📧 Campaign Management - List campaigns and manage subscriber enrollments
- 🔄 Workflow Automation - Control workflows and subscriber participation
- 📊 Event Tracking - Track custom events for behavioral automation
- 💰 E-commerce Integration - Record purchases and conversions
- 📝 Form & Broadcast Access - Retrieve forms and broadcast information
- ⚡ Batch Operations - Efficiently handle bulk subscriber operations
- 🔍 Advanced Search - Find subscribers using complex filter criteria
Technical Features
- 🛡️ Automatic Rate Limiting - Handles Drip's API limits with exponential backoff
- 🔧 Smart Field Mapping - Automatically organizes standard and custom fields
- 🎯 Error Handling - Detailed error messages for debugging
- 🧪 Comprehensive Testing - Unit and integration test suites included
- 🔍 MCP Inspector Support - Built-in debugging interface for development
📦 Installation
Prerequisites
- Node.js 20.0.0 or higher
- npm or yarn package manager
- Drip account with API access
- MCP-compatible client (e.g., Claude Desktop)
Package Installation
# Using npm
npm install @gravitykit/drip-mcp-server
# Using yarn
yarn add @gravitykit/drip-mcp-server
# For global installation
npm install -g @gravitykit/drip-mcp-server
From Source
# Clone the repository
git clone https://github.com/GravityKit/drip-mcp-server.git
cd drip-mcp-server
# Install dependencies
npm install
# Set up environment variables
cp .env.example .env
# Edit .env with your credentials
🔑 Configuration
Getting Your API Credentials
-
API Key:
- Log in to your Drip account
- Navigate to Settings → My User Settings → API
- Copy your API Key
- Direct link: https://www.getdrip.com/user/edit
-
Account ID:
- Found in Settings → General Info
- Also visible in your Drip dashboard URL
- Format: Numeric ID (e.g.,
12345678)
Environment Variables
Create a .env file in the project root:
DRIP_API_KEY=your_api_key_here
DRIP_ACCOUNT_ID=your_account_id_here
Claude Desktop Configuration
Add to your claude_desktop_config.json:
{
"mcpServers": {
"drip": {
"command": "npx",
"args": ["@gravitykit/drip-mcp-server"],
"env": {
"DRIP_API_KEY": "your_api_key_here",
"DRIP_ACCOUNT_ID": "your_account_id_here"
}
}
}
}
Alternative: Using Local Installation
{
"mcpServers": {
"drip": {
"command": "node",
"args": ["/path/to/drip-mcp-server/src/index.js"],
"env": {
"DRIP_API_KEY": "your_api_key_here",
"DRIP_ACCOUNT_ID": "your_account_id_here"
}
}
}
}
🚀 Usage
Quick Start
Once configured, the MCP server exposes Drip functionality through standardized tools. Your AI assistant can use natural language to interact with these tools.
Example Prompts for AI Assistants
"Add john@example.com to my Drip subscribers with the tag 'customer'"
"Find all subscribers tagged as 'vip' who joined this month"
"Track a 'Product Viewed' event for user@example.com with product_id ABC123"
"Start the 'Welcome Series' workflow for new@subscriber.com"
"Show me the last 10 unsubscribes and their reasons"
Available Tools
Subscriber Management
| Tool | Description |
|---|---|
drip_create_subscriber |
Create or update a subscriber |
drip_list_subscribers |
List all subscribers with pagination |
drip_get_subscriber |
Get a specific subscriber by ID or email |
drip_delete_subscriber |
Permanently delete a subscriber |
drip_search_subscribers |
Advanced search with filters |
drip_batch_create_subscribers |
Bulk create/update (up to 1000) |
Tags & Segmentation
| Tool | Description |
|---|---|
drip_tag_subscriber |
Apply tags to a subscriber |
drip_remove_tag |
Remove a tag from a subscriber |
Campaigns & Workflows
| Tool | Description |
|---|---|
drip_list_campaigns |
List all campaigns |
drip_subscribe_to_campaign |
Add subscriber to campaign |
drip_list_workflows |
List all workflows |
drip_activate_workflow |
Activate a workflow |
drip_pause_workflow |
Pause a workflow |
drip_start_workflow |
Start workflow for subscriber |
drip_remove_from_workflow |
Remove subscriber from workflow |
Analytics & Tracking
| Tool | Description |
|---|---|
drip_track_event |
Track custom events |
drip_record_conversion |
Record a conversion |
drip_record_purchase |
Record a purchase |
drip_recent_unsubscribes |
Get recent unsubscribes |
drip_unsubscribe_stats |
Get unsubscribe statistics |
Forms & Broadcasts
| Tool | Description |
|---|---|
drip_list_forms |
List all forms |
drip_get_form |
Get specific form details |
drip_list_broadcasts |
List all broadcasts |
drip_get_broadcast |
Get specific broadcast details |
Code Examples
Creating a Subscriber
{
"email": "user@example.com",
"first_name": "John",
"last_name": "Doe",
"tags": ["customer", "newsletter"],
"custom_fields": {
"company": "Acme Corp",
"plan": "premium"
},
"time_zone": "America/New_York",
"eu_consent": "granted"
}
Tracking an Event
{
"email": "user@example.com",
"action": "Viewed Product",
"properties": {
"product_id": "SKU-12345",
"product_name": "Premium Widget",
"price": 99.99,
"category": "Widgets"
},
"occurred_at": "2024-01-15T10:30:00Z"
}
Advanced Search
{
"tags": ["vip", "customer"],
"created_after": "2024-01-01T00:00:00Z",
"custom_field_filters": {
"lifetime_value": { "greater_than": 1000 },
"plan": "premium"
},
"status": "active",
"per_page": 100
}
🧪 Development
Running in Development Mode
# Watch mode with auto-restart
npm run dev
# Standard mode
npm start
Using the MCP Inspector
The MCP Inspector provides a web-based UI for testing and debugging:
# Launch the inspector
npm run inspect
Features:
- Interactive tool testing
- Real-time message monitoring
- Schema validation
- Request/response inspection
Access the inspector at http://localhost:5173 after running the command.
Testing
# Run all tests
npm run test:all
# Run specific test suites
npm test # Core functionality
npm run test:unit # Unit tests (no network)
npm run test:validation # Input validation
npm run test:names # Field handling
npm run test:unsubscribes # Unsubscribe tracking
Project Structure
drip-mcp-server/
├── src/
│ ├── index.js # MCP server implementation
│ ├── drip-client.js # Drip API client wrapper
│ └── tests/ # Test suites
│ ├── run.js # Test runner
│ ├── drip-client.test.js
│ ├── server-tools.test.js
│ └── server-e2e.test.js
├── package.json
├── mcp.json # MCP Inspector config
├── .env.example # Environment template
├── LICENSE # MIT license
└── README.md # Documentation
🔒 Security Best Practices
-
API Key Management
- Never commit API keys to version control
- Use environment variables or secure key management
- Rotate API keys regularly
- Use least-privilege API keys when possible
-
Data Protection
- Handle subscriber data according to privacy regulations (GDPR, CCPA)
- Implement proper consent management
- Use secure connections (HTTPS) only
-
Rate Limiting
- Respect Drip's API limits (3,600 requests/hour)
- Implement exponential backoff for retries
- Monitor API usage to avoid limit violations
🐛 Troubleshooting
Common Issues
Authentication Errors (401)
- Cause: Invalid API key or account ID
- Solution: Verify credentials in Drip settings and environment variables
Permission Errors (403)
- Cause: API key lacks required permissions
- Solution: Check API key permissions in Drip account settings
Rate Limiting (429)
- Cause: Exceeding API rate limits
- Solution: Server automatically retries with backoff; reduce request frequency if persistent
Field Mapping Issues
- Cause: Incorrect field placement (standard vs. custom)
- Solution: Server handles automatically; check field names match Drip configuration
Debug Mode
Enable detailed logging:
DEBUG=* npm start
📚 API Documentation
Field Types
Standard Fields (Root Level)
email(required)first_namelast_nameuser_idtime_zoneeu_consenteu_consent_message
Custom Fields (Nested)
All other fields are automatically placed in custom_fields:
companyphoneaddress1,address2city,state,zip,country- Any custom data fields
Rate Limits
| Operation Type | Limit | Window |
|---|---|---|
| Individual Requests | 3,600 | Per hour |
| Batch Operations | 50,000 | Per hour |
| Concurrent Requests | 50 | Simultaneous |
Error Responses
| Status Code | Description | Action Required |
|---|---|---|
| 401 | Unauthorized | Check API credentials |
| 403 | Forbidden | Verify permissions |
| 422 | Validation Error | Fix request parameters |
| 429 | Rate Limited | Wait and retry |
| 500 | Server Error | Contact support if persistent |
❓ Frequently Asked Questions
Can I create broadcasts through the API?
No, the Drip API provides read-only access to broadcasts. Use the Drip web interface to create broadcasts.
How do I handle EU consent?
Use the eu_consent field with values: granted, denied, or pending. Include eu_consent_message for audit trails.
What's the difference between campaigns and workflows?
- Campaigns: Email series with fixed timing
- Workflows: Automated sequences triggered by events or conditions
Can I bulk delete subscribers?
No, Drip requires individual deletion for data safety. Use drip_delete_subscriber for each subscriber.
How do I track revenue?
Use drip_record_purchase with the value field in cents (e.g., 9999 for $99.99).
🤝 Contributing
We welcome contributions! Please follow these guidelines:
- Fork the repository and create a feature branch
- Write tests for new functionality
- Follow the code style (ESM, async/await, clear naming)
- Update documentation for API changes
- Submit a pull request with a clear description
Development Guidelines
- Use Node.js 20+ with ES modules
- Maintain test coverage above 80%
- Follow semantic versioning
- Write descriptive commit messages
- Keep dependencies minimal
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🆘 Support
For This MCP Server
- 📧 Email: support@gravitykit.com
- 🐛 Issues: GitHub Issues
- 💬 Discussions: GitHub Discussions
For Drip API
For MCP Protocol
🙏 Acknowledgments
- Built with the Model Context Protocol SDK
- Powered by Drip email marketing platform
- Developed by GravityKit
Made with ❤️ by GravityKit
推荐服务器
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 模型以安全和受控的方式获取实时的网络信息。