Email MCP Server
An HTTP/SSE wrapper for the IMAP MCP server that enables users to read, search, and send emails across multiple accounts and providers. It supports secure AES-256 encryption and provides remote access through Claude Web using SSE transport.
README
Email MCP Server
HTTP/SSE wrapper для nikolausm/imap-mcp-server, обеспечивающий удалённый доступ через Claude Web и другие HTTP-клиенты MCP.
Возможности
- 📧 Полноценная работа с почтой: чтение, поиск, отправка, ответ, пересылка
- 🔐 Безопасное хранение: AES-256 шифрование учётных данных
- 🌐 Удалённый доступ: HTTP/SSE транспорт для Claude Web
- 📱 15+ провайдеров: Gmail, Outlook, Yahoo, Yandex, Mail.ru и др.
- 🔄 Multi-account: Поддержка нескольких почтовых аккаунтов
Архитектура
┌─────────────────────────────────────────────────────┐
│ HTTP/SSE Wrapper │
│ (Python/aiohttp) │
├─────────────────────────────────────────────────────┤
│ │
│ HTTP/SSE ←→ STDIO Bridge ←→ imap-mcp-server │
│ │
└─────────────────────────────────────────────────────┘
Быстрый старт
Локально для Claude Desktop
# Клонировать репозиторий
git clone https://github.com/nikolausm/imap-mcp-server.git
cd imap-mcp-server
# Установить и собрать
npm install
npm run build
# Настроить аккаунты через web wizard
npm run setup
Добавить в ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"imap-email": {
"command": "node",
"args": ["/path/to/imap-mcp-server/dist/index.js"]
}
}
}
Удалённый сервер (Docker)
# Собрать и запустить
docker-compose up -d
# Проверить здоровье
curl http://localhost:3008/health
Через Gateway (Claude Web)
URL для Custom Connector:
https://mcp.svsfinpro.ru/email/sse
API Endpoints
| Endpoint | Метод | Описание |
|---|---|---|
/ |
GET | Информация о сервере |
/health |
GET | Health check |
/sse |
GET | SSE endpoint для установления соединения |
/mcp |
POST | Streamable HTTP endpoint |
/messages |
POST | Legacy SSE messages endpoint |
MCP Инструменты
Управление аккаунтами
imap_add_account- Добавить почтовый аккаунтimap_list_accounts- Список аккаунтовimap_remove_account- Удалить аккаунтimap_connect- Подключиться к аккаунтуimap_disconnect- Отключиться
Работа с письмами
imap_search_emails- Поиск писемimap_get_email- Получить письмоimap_get_latest_emails- Последние письмаimap_mark_as_read/imap_mark_as_unread- Пометить как прочитанноеimap_delete_email- Удалить письмо
Отправка писем
imap_send_email- Отправить письмоimap_reply_to_email- Ответить на письмоimap_forward_email- Переслать письмо
Папки
imap_list_folders- Список папокimap_folder_status- Статус папкиimap_get_unread_count- Количество непрочитанных
Настройка провайдеров
Gmail
- Включить 2FA
- Создать App Password: https://myaccount.google.com/apppasswords
- IMAP:
imap.gmail.com:993 - SMTP:
smtp.gmail.com:465
Yandex
- Создать пароль приложения
- IMAP:
imap.yandex.ru:993 - SMTP:
smtp.yandex.ru:465
Mail.ru
- IMAP:
imap.mail.ru:993 - SMTP:
smtp.mail.ru:465
Deployment
На сервер 217.199.253.8
./deploy.sh
Добавить в nginx gateway
Скопировать nginx-mcp-email.conf в конфигурацию сервера.
Безопасность
- ⚠️ НИКОГДА не используйте основной пароль - только App Passwords
- 🔐 Учётные данные шифруются AES-256
- 📁 Хранятся в Docker volume
email-mcp-accounts - 🔒 HTTPS через nginx gateway
Переменные окружения
| Переменная | Описание | По умолчанию |
|---|---|---|
HOST |
Адрес сервера | 0.0.0.0 |
PORT |
Порт | 8080 |
IMAP_SERVER_PATH |
Путь к imap-mcp-server | /app/imap-mcp-server/dist/index.js |
LOG_LEVEL |
Уровень логирования | INFO |
Troubleshooting
Контейнер не запускается
docker logs email-mcp-server
Проблемы с подключением к почте
- Проверьте App Password
- Убедитесь что IMAP включен в настройках почты
- Проверьте firewall
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.