这是一个全面的企业级潜在客户培育系统,通过MCP(模型上下文协议)服务器实现Gmail外展活动的自动化,具备智能跟进、回复跟踪功能,可实现全天候运行。
git clone https://github.com/brandononchain/GMAIL-MCP-Agent.git
cd GMAIL-MCP-Agent
pip install -r requirements.txt
credentials.json
。nurturing_config.json
中更新发件人邮箱。# 使用Docker部署(推荐)
./deploy.sh
# 或手动部署
docker-compose up -d
# 使用MCP客户端
python mcp_client.py start 4
# 或直接执行
python run_nurturing.py
# 一键部署
./deploy.sh
# 手动部署
docker-compose up -d
# 安装依赖
pip install -r requirements.txt
# 运行培育系统
python run_nurturing.py
# Systemd服务
sudo cp lead-nurturing.service /etc/systemd/system/
sudo systemctl enable lead-nurturing
sudo systemctl start lead-nurturing
# 启动培育系统(每4小时一次)
python mcp_client.py start 4
# 检查系统状态
python mcp_client.py status
# 获取潜在客户报告
python mcp_client.py report
# 发送测试邮件
python mcp_client.py test your-email@example.com
# 查看最近的日志
python mcp_client.py logs 100
# 停止系统
python mcp_client.py stop
# 运行单次培育周期
python lead_nurturer.py
# 查看潜在客户仪表盘
python lead_dashboard.py
# 从CSV文件发送邮件
python send_from_csv.py contacts.csv --body_file body.txt
├── send_from_csv.py # 主要的Gmail发送脚本
├── lead_nurturer.py # 自动化培育系统
├── mcp_server.py # 24/7运行的MCP服务器
├── mcp_client.py # 控制接口
├── lead_dashboard.py # 监控仪表盘
├── run_nurturing.py # 自动化运行器
├── contacts.csv # 潜在客户数据库(96家牙科诊所)
├── body.txt # 电子邮件模板
├── credentials.json # Gmail API凭证
├── nurturing_config.json # 系统配置
├── gmail_sync_state.json # Gmail增量同步状态(自动创建)
├── requirements.txt # Python依赖项
├── Dockerfile # 容器配置
├── docker-compose.yml # 部署设置
├── deploy.sh # 一键部署脚本
└── DEPLOYMENT_GUIDE.md # 完整的设置指南
Hi {{first_name}},
Did you know many dental practices lose 20–30% of new patient inquiries because follow-ups slip through the cracks?
We've built an AI agent that automatically follows up with every lead via SMS/email and books them straight into your calendar.
Clients typically see 5–9 extra appointments in the first 30 days.
Have time for 10-min demo call this week?
Thank you,
Brandon
Quantra Labs
# Gmail API配置
CREDENTIALS_FILE=credentials.json
TOKEN_FILE=token.json
# 培育设置
PER_MINUTE=12
RESUME=false
LOG_FILE=send_log.csv
# MCP服务器设置
MCP_SERVER_PORT=8000
LOG_LEVEL=INFO
{
"sender_email": "your-email@domain.com",
"follow_up_schedule": {
"followup_1_days": 3,
"followup_2_days": 7
},
"automation": {
"check_responses_interval_hours": 4,
"auto_respond_to_interest": true
}
}
┌─────────────────┐ ┌──────────────────┐ ┌─────────────────┐
│ MCP Client │◄──►│ MCP Server │◄──►│ Lead Nurturer │
│ (Control) │ │ (24/7 Service) │ │ (Automation) │
└─────────────────┘ └──────────────────┘ └─────────────────┘
│
▼
┌──────────────────┐
│ Gmail API │
│ (Email System) │
└──────────────────┘
该系统基于Python构建,利用Gmail API实现电子邮件的发送和接收。通过MCP协议,系统可以实现远程控制和实时监控。使用Docker容器化技术,确保系统能够在不同环境下稳定运行。同时,系统还具备智能跟进、潜在客户评分和自动回复等功能,提高潜在客户培育的效率和效果。
本项目采用MIT许可证 - 详情请参阅LICENSE文件。
欢迎贡献代码!请随时提交拉取请求。