shanghaitech-mail-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| mail_list_foldersA | 列出上科大邮箱里所有 IMAP 文件夹(收件箱、已发送、草稿箱、垃圾箱、自定义分类),含每个文件夹的邮件总数与未读数。写检索前先调用它确认文件夹名。 |
| mail_searchA | 在指定文件夹内搜索邮件,返回元数据列表(uid / 主题 / 发件人 / 日期 / 已读状态 / 大小 / 可选摘要),不返回正文全文。支持按发件人、收件人、主题、正文关键词、日期区间、未读、附件存在等条件。用于「这周有哪些通知」「助教发过什么邮件」「找某个附件」这类需求。 |
| mail_readA | 按 uid 读取一封邮件的完整内容:主题、收发件人、时间、正文纯文本、附件清单(附件不会自动下载,需要正文后用 mail_save_attachment 另存)。默认读完即标记为已读;mark_read=false 可保持未读。 |
| mail_save_attachmentA | 把某封邮件的附件落盘到工作区(可用于把助教的 PPT / 作业 PDF 存到本地再解析)。index 来自 mail_read 返回的 attachments 列表。默认存到 _素材/邮箱附件/。 |
| mail_draftA | 把一封邮件写进邮箱的草稿箱(IMAP Drafts),不发送。适合「先拟好,我自己再改改看」的场景。发送请用 mail_send。 |
| mail_sendA | 通过学校 SMTP 直接发送邮件(会真的发出去)。除非用户明确要求发送,否则优先用 mail_draft 存草稿让用户过目。 |
| mail_markB | 给邮件加/去标记:已读、未读、星标。批量操作传 uids 数组。 |
| mail_moveB | 把邮件从一个文件夹移动到另一个(例如归档到自定义分类、移到垃圾箱)。 |
| mail_deleteA | 删除邮件。默认行为是「移入垃圾箱」,可恢复、可再找回;只有 permanent=true 才真正 EXPUNGE 彻底删掉(不可恢复)。批量清理请先用 mail_cleanup_report 出清单、确认后再删。 |
| mail_cleanup_reportA | 扫描文件夹里最近 N 封邮件,按发件人地址聚合成「谁发得最多」的清单,附带每组的未读数、最早/最晚时间、若干封 uid 与主题样例,用来判断哪些是群发通知/订阅资讯(可批量清)、哪些是真人邮件(别删)。纯只读,不删任何东西。 |
| mail_autocleanA | 按预设规则自动把垃圾邮件移入垃圾箱,不动任何正常邮件。默认 dry_run=true 只报告;dry_run=false 才真的移动。规则一:Twitch 直播推送,发出超过 10 小时即清。规则二:掠夺性期刊/期刊约稿与「代写代发」类骚扰(IntechOpen 等),见到即清,不看年龄。规则三:同一发件人在 24 小时内重复推送的直播/提醒类通知,只留最新一封。所有移动都进 Trash(可恢复),不会永久删除。 |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 11 tools
Each tool targets a distinct resource+action: folder listing, search, read, attachment save, draft, send, mark, move, delete, cleanup report and autoclean. Minor overlap exists between mail_delete and mail_move (default delete is a move to Trash) and between mail_cleanup_report and mail_autoclean, but the descriptions explicitly state the difference (read-only report vs. dry-run action) so misselection is unlikely.
All names use the mail_ prefix with snake_case, which is highly consistent. Most follow verb_noun (mail_list_folders, mail_save_attachment, mail_mark), with a few noun-style names (mail_draft, mail_cleanup_report) that break the pattern slightly but remain readable and predictable.
11 tools is squarely within the well-scoped 3-15 range for an email client surface. Every tool covers a meaningful capability (read, send, organize, clean) rather than duplicating functionality.
The surface covers the full email lifecycle: discover folders, search, read, fetch attachments, draft, send, flag, move, delete, plus cleanup reporting and rule-based autoclean. Notable gaps are reply/forward helpers and any way to edit or delete an existing draft, but agents can work around these by composing a new draft or sending directly.