sota-agw-mcp
Integrates with Gmail mailboxes via IMAP/SMTP, enabling read-only inbox access, email triage, attachment text extraction, reply drafting, and sending only after explicit user confirmation.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
SOTA Agentic Gateway — MCP server & Claude plugin
Thử nghiệm nội bộ — CHƯA phát hành lên PyPI. Cài từ GitHub như bên dưới. Đừng dùng
uvx sota-agw-mcp(không--from): tên đó chưa đăng ký trên PyPI, lệnh sẽ tra PyPI và có thể cài gói của người khác.
MCP server cho việc tiếp nhận & phản hồi email / tin nhắn trong logistics, chuỗi cung ứng, thương mại: phân loại hộp thư (luật quảng cáo / lừa đảo), trích chữ file đính kèm, điền template DOCX / XLSX tô vàng, tra thư mục tri thức, soạn nháp — và chỉ gửi sau khi bạn xác nhận. Tuỳ chọn nối workspace SaaS SOTA Agentic Gateway (gửi = tạo yêu cầu duyệt).
Không có công cụ nào tự gửi hay tự duyệt. Gửi email cục bộ cần bạn bấm xác nhận trong hộp thoại của client (MCP elicitation); client không có hộp thoại → server trả lệnh terminal (
… -m agw_mcp send <draft_id>) để bạn tự chạy.IMAP chỉ đọc. File chỉ đọc / ghi trong thư mục làm việc
AGW_WORKDIR.Nội dung email / file được coi là dữ liệu bên ngoài — không phải lệnh.
Cài & chạy
Cần uv. Client gọi uvx --from git+https://github.com/thanhtrung665/gateway-agent-mcp sota-agw-mcp (stdio) — uv tự tải từ GitHub.
Muốn cố định phiên bản: thêm @<commit> hoặc @<tag> sau URL.
Claude Code
claude mcp add sota-agw -e AGW_WORKDIR=$HOME/SOTA-Agentic-Gateway -- uvx --from git+https://github.com/thanhtrung665/gateway-agent-mcp sota-agw-mcp
# hoặc cài plugin (có thêm skill + ô cấu hình) — marketplace có 2 plugin, chọn theo chế độ:
claude plugin marketplace add thanhtrung665/gateway-agent-mcp
claude plugin install sota-agentic-gateway@sota-agentic-gateway # cục bộ: IMAP, file, template trên máy (cần uv)
claude plugin install sota-agentic-gateway-remote@sota-agentic-gateway # remote: workspace SaaS qua OAuth, không cài gìPlugin | Chạy ở đâu | Công cụ | Đăng nhập |
| máy bạn ( | 11 công cụ cục bộ (+ | IMAP App Password / API key |
| API SaaS | 14 công cụ | OAuth trong |
Cài cả hai được (vd hộp thư cục bộ + workspace); khi đó để trống api_url / api_key của plugin cục bộ để khỏi trùng
công cụ saas_*.
Prompts (client không có skill vẫn đi đúng quy trình duyệt): cục bộ triage_local, reply_local,
fill_template_local; workspace inbox_saas, reply_saas — trong Claude Code gõ / để thấy.
Claude Desktop (claude_desktop_config.json) · Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"sota-agw": {
"command": "uvx",
"args": ["--from", "git+https://github.com/thanhtrung665/gateway-agent-mcp", "sota-agw-mcp"],
"env": {
"AGW_WORKDIR": "/Users/ban/SOTA-Agentic-Gateway",
"AGW_IMAP_HOST": "imap.gmail.com",
"AGW_IMAP_USER": "ban@congty.vn",
"AGW_IMAP_PASSWORD": "<app password>",
"AGW_SMTP_HOST": "smtp.gmail.com"
}
}
}
}VS Code (.vscode/mcp.json)
{
"servers": {
"sota-agw": { "type": "stdio", "command": "uvx", "args": ["--from", "git+https://github.com/thanhtrung665/gateway-agent-mcp", "sota-agw-mcp"], "env": { "AGW_WORKDIR": "${userHome}/SOTA-Agentic-Gateway" } }
}
}Kiểm cấu hình: uvx --from git+https://github.com/thanhtrung665/gateway-agent-mcp sota-agw-mcp check (in thư mục làm việc, thử đăng nhập IMAP / SaaS — không in mật khẩu).
Related MCP server: Gmail MCP Server
Cấu hình (biến môi trường)
Biến | Ý nghĩa |
| Thư mục làm việc ( |
| Hộp thư (IMAP SSL, mặc định cổng 993). Dùng App Password, không dùng mật khẩu chính |
| Gửi (mặc định 587 STARTTLS; user / mật khẩu mặc định = IMAP) |
| Domain nội bộ (phân cách dấu phẩy) — dùng cho cảnh báo giả mạo |
|
|
| Nối workspace SaaS (API key |
Mật khẩu nằm trong file cấu hình của client dưới dạng chữ thường — dùng App Password riêng, thu hồi được. Bản plugin
Claude Code lưu các ô bí mật an toàn hơn (userConfig sensitive).
Remote MCP (workspace SaaS — không cần cài gì)
Dán https://<api-saas>/mcp vào client hỗ trợ MCP từ xa: client mở trang đăng nhập + đồng ý (OAuth 2.1), hoặc gửi
header Authorization: Bearer agw_…. Mã endpoint là gói agw_remote_mcp trong gói này; máy chủ uỷ quyền nằm ở API SaaS.
claude mcp add --transport http sota-agw-remote https://<api-saas>/mcpTrong gói
Gói | Nội dung |
| MCP server cục bộ (stdio) — lệnh |
| Lõi thuần Python: tách email RFC 822, luật quảng cáo / an ninh, BM25 + RRF, trích chữ PDF / DOCX / XLSX / EML, template tô vàng, định nghĩa công cụ SaaS dùng chung |
| Remote MCP (ASGI, Streamable HTTP stateless) cho API SaaS |
Mã nguồn, Claude plugin và skill: https://github.com/thanhtrung665/gateway-agent-mcp
Phát triển
uv sync
uv run pytest -q # plugin + gói + remote MCP (không cần SaaS, không ra mạng)
uv run ruff check .
python -X utf8 scripts/sync_plugin_core.py # sau khi sửa agw_core/ hoặc agw_mcp/server.py → chép vào plugin
uv build && uv run python scripts/smoke_stdio.py uvx --isolated --from dist/<wheel> sota-agw-mcp
claude plugin validate plugin/sota-agentic-gateway && claude plugin validate plugin/sota-agentic-gateway-remote && claude plugin validate .plugin/sota-agentic-gateway/server/agw_mcp.py là bản chép y hệt agw_mcp/server.py (plugin chạy bằng
uv run --script, phụ thuộc khai ở khối # /// script đầu file — test kiểm khớp pyproject.toml). Repo SaaS cài gói
này qua git dependency ghim commit (sota-agw-mcp[remote] @ git+https://github.com/thanhtrung665/gateway-agent-mcp@<commit>).
Phát hành PyPI (chưa làm — quyết định 2026-11-07: chỉ nội bộ): khi được chốt, tạo pending publisher trên pypi.org /
test.pypi.org rồi tag test-vX.Y.Z (TestPyPI) → vX.Y.Z (PyPI) — workflow publish.yml (Trusted Publishing).
Giấy phép
Thương mại — xem LICENSE.
This server cannot be deployed
Maintenance
Related MCP Connectors
Search and triage all your mailboxes; draft replies and campaigns; send only as you allow.
Email inboxes for recurring agent work. Read, search, reply, draft and organize correspondence.
Connect inboxes to your AI, with built-in progress and optional owner-confirmed outgoing email.
Governed email for AI agents: a sandbox inbox to read and send from, human approval to go external.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to manage multiple email accounts with secure credentials, local full-text search, thread-aware replies, and automation.4 npmMIT
- FlicenseNot gradedqualityDmaintenanceEnables AI-powered email management through Gmail, including search, send, drafts, labels, and an intelligent agent with human approval workflow and optional customer database integration.-
- AlicenseAqualityCmaintenanceGives AI agents their own email address with inbound parsing, classification, extraction, and prompt injection screening, plus tools to manage mailboxes, send/receive emails, and handle draft approval workflows.1466 npmMIT
- FlicenseNot gradedqualityNot gradedmaintenanceEnables autonomous triage of personal communications and email through deterministic multi-factor urgency scoring, VIP filtering, and context-aware executive auto-drafting. It plugs into any MCP-compliant client to resolve routine communication workflows instantly without frontier LLM round-trips.-