Mail MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Mail MCP Serversend an email to john@example.com saying the report is ready"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Mail MCP Server
基于 FastMCP 的邮件发送能力,以 MCP Streamable HTTP 传输启动,供支持该协议的客户端通过 HTTP 连接(无需 stdio 子进程)。
Features
传输:
streamable-http(FastMCP 内与http/sse并列的 transport)MCP 工具:
send_email、send_template_email监听:
MCP_HOST/MCP_PORT(默认0.0.0.0:8000)Docker 镜像非 root 运行,依赖层与代码层分离缓存
Prerequisites
Project Structure
mail-mcp-server
├── src
│ ├── mcp_server.py # MCP 入口(streamable-http)
│ ├── main.py
│ ├── email_service/
│ └── tests/
├── pyproject.toml
├── uv.lock
├── Dockerfile
├── docker-compose.yml
├── .dockerignore
├── .env.example
└── README.md启动
cd mail-mcp-server
cp .env.example .env
uv sync
uv run python src/mcp_server.pyStreamable HTTP 端点:http://<MCP_HOST>:<MCP_PORT>/mcp(例如 http://127.0.0.1:8000/mcp)。
.env 为何未生效?
见 .env 与 load_env 说明:需在项目根放置 .env,修改后重启 MCP 进程。
环境变量
变量 | 说明 | 默认 |
| 监听 |
|
| 发信 | 见 |
| 465 / 587 | 见 |
163 Connection unexpectedly closed
问题 | 处理 |
用户名非完整邮箱 | 使用 |
FROM 写成授权码 | FROM 必须是邮箱;授权码只在 |
587 被断开 | 使用 |
一次性演示(非 MCP)
uv run python src/main.pyDocker
镜像特点
项 | 说明 |
分层 | 先 |
环境 |
|
安全 |
|
布局 |
|
构建
# 默认 bookworm + Python 3.10
docker build -t mail-mcp-server:latest .
# 加快构建(跳过 apt upgrade)
docker build --build-arg SKIP_APT_UPGRADE=1 -t mail-mcp-server:latest .
# 指定 Python 小版本
docker build --build-arg PYTHON_VERSION=3.11 -t mail-mcp-server:py311 .运行
docker run --rm -p 8000:8000 --env-file .env mail-mcp-server:latestCompose
服务名 mail-mcp(原 email-sender 已更名):
docker compose up --build -d端口:宿主机
${MCP_PORT:-8000}→ 容器8000(容器内仍监听 8000,改端口请同时设置环境变量并映射)。healthcheck:对容器内
127.0.0.1:8000做 TCP 探测(Streamable HTTP 未必有 GET/)。重启策略:
unless-stopped。
Development
uv sync --group dev
uv run pytest
uv lockLicense
MIT
This server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/NingNing0111/email-send-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server