邮件与消息32k · #9170
gws-gmail-reply
它能做什么
这个工具可以对 Gmail 中已有的邮件进行回复。回复时会自动附上原邮件内容,帮你保持对话的完整记录。
适用场景
- ✓当你想回复某一封特定邮件时。
- ✓当你想在回复中添加收件人(收件人或密送人)时。
- ✓当你想先保存回复草稿,而不是立即发送时。
技能链接
https://github.com/googleworkspace/cli/blob/main/skills/gws-gmail-reply/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
请用这个技能帮我:https://github.com/googleworkspace/cli/blob/main/skills/gws-gmail-reply/SKILL.md
阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
npx skills add googleworkspace/cli --skill gws-gmail-reply
下载 SKILL.md,放进智能体的技能文件夹。
curl -L https://raw.githubusercontent.com/googleworkspace/cli/main/skills/gws-gmail-reply/SKILL.md -o SKILL.md
可以这样问 AI
“回复 ID 为 '123abc456def' 的邮件,内容为“Thanks for the information, I received it.””
每周 5 个新技能,1 分钟读完。
工作原理
你需要提供要回复的邮件的 ID,以及你的回复内容。工具会把文字插入回复中并发送,同时保留对话记录。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
gmail +reply
PREREQUISITE: Read
../gws-shared/SKILL.mdfor auth, global flags, and security rules. If missing, rungws generate-skillsto create it.
Reply to a message (handles threading automatically)
Usage
gws gmail +reply --message-id <ID> --body <TEXT>
Flags
| Flag | Required | Default | Description |
|---|---|---|---|
--message-id |
✓ | — | Gmail message ID to reply to |
--body |
✓ | — | Reply body (plain text, or HTML with --html) |
--from |
— | — | Sender address (for send-as/alias; omit to use account default) |
--to |
— | — | Additional To email address(es), comma-separated |
--attach |
— | — | Attach a file (can be specified multiple times) |
--cc |
— | — | CC email address(es), comma-separated |
--bcc |
— | — | BCC email address(es), comma-separated |
--html |
— | — | Treat --body as HTML content (default is plain text) |
--dry-run |
— | — | Show the request that would be sent without executing it |
--draft |
— | — | Save as draft instead of sending |
Examples
gws gmail +reply --message-id 18f1a2b3c4d --body 'Thanks, got it!'
gws gmail +reply --message-id 18f1a2b3c4d --body 'Looping in Carol' --cc carol@example.com
gws gmail +reply --message-id 18f1a2b3c4d --body 'Adding Dave' --to dave@example.com
gws gmail +reply --message-id 18f1a2b3c4d --body '<b>Bold reply</b>' --html
gws gmail +reply --message-id 18f1a2b3c4d --body 'Updated version' -a updated.docx
gws gmail +reply --message-id 18f1a2b3c4d --body 'Draft reply' --draft
Tips
- Automatically sets In-Reply-To, References, and threadId headers.
- Quotes the original message in the reply body.
- --to adds extra recipients to the To field.
- Use -a/--attach to add file attachments. Can be specified multiple times.
- With --html, the quoted block uses Gmail's gmail_quote CSS classes and preserves HTML formatting. Use fragment tags (<p>, <b>, <a>, etc.) — no <html>/<body> wrapper needed.
- With --html, inline images in the quoted message are preserved via cid: references.
- Use --draft to save the reply as a draft instead of sending it immediately.
- For reply-all, use +reply-all instead.
See Also
- gws-shared — Global flags and auth
- gws-gmail — All send, read, and manage email commands
常见问题
工具怎么知道要回复哪封邮件?
你需要提供一个叫做 'message-id' 的唯一代码,它用来标识每一封邮件。
我可以添加附件吗?
可以。使用 '--attach' 选项就可以把文件添加到回复中。
我怎样回复给更多人?
你可以使用 '--to'、'--cc' 或 '--bcc' 选项添加额外的邮箱地址。
详情
热度
- GitHub 星标
- 32k
- 排名
- #9170
- 许可证
- Apache-2.0
- 更新时间
- 2026/10/6
评论
- …