Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/spillwavesolutions/automating-mac-apps-plugin/automating-mailnpx skills add SpillwaveSolutions/automating-mac-apps-plugin --skill automating-mailgit clone --depth 1 https://github.com/SpillwaveSolutions/automating-mac-apps-pluginWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/spillwavesolutions/automating-mac-apps-plugin/automating-mail)<a href="https://agentmods.dev/skills/spillwavesolutions/automating-mac-apps-plugin/automating-mail"><img src="https://agentmods.dev/badge/skills/spillwavesolutions/automating-mac-apps-plugin/automating-mail.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00062 | $0.00809 |
| Opus 5 | $0.00031 | $0.00404 |
| Sonnet 5 | $0.00012 | $0.00162 |
| Haiku 4.5 | $0.00006 | $0.00081 |
Grade A, and why
automating-mail scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 89 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Automating Apple Mail (JXA-first, AppleScript discovery)
Contents
- Relationship to macOS automation skill
- Core Framing
- Workflow
- Quick Start Examples
- Validation Checklist
- When Not to Use
- What to load
Relationship to the macOS automation skill
- Use
automating-mac-appsfor permissions, shell, and UI scripting guidance. - PyXA Installation: See
automating-mac-appsskill (PyXA Installation section).
Core Framing
- Mail dictionary is AppleScript-first; discover in Script Editor.
- Objects are specifiers: read via method calls (
message.subject()), modify via assignments (message.readStatus = true). - ObjC bridge available for advanced filesystem operations.
Workflow (default)
- Ensure Mail configured and automation permissions enabled.
- Discover terms in Script Editor (Mail dictionary).
- Prototype minimal AppleScript command.
- Port to JXA with defensive checks.
- Use batch reads for performance.
- Use UI scripting for signature and UI-only actions.
Quick Start Examples
Read inbox (JXA):
const Mail = Application('Mail');
const message = Mail.inbox.messages[0];
console.log(message.subject());
Compose message (JXA):
const msg = Mail.OutgoingMessage({
subject: "Status Update",
content: "All systems go."
});
Mail.outgoingMessages.push(msg);
msg.visible = true;
PyXA alternative:
import PyXA
mail = PyXA.Mail()
inbox = mail.inboxes()[0]
message = inbox.messages()[0]
print(f"Subject: {message.subject()}")
Validation Checklist
- Automation permissions granted (System Settings > Privacy > Automation)
- Inbox access works:
Mail.inbox.messages.length - Message property reads return expected values
- Composition creates visible draft
- Batch operations complete without errors
What ships with it
16 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/attachment-extraction.md 583 B
- references/html-data-merge.md 544 B
- references/html-signature-workflow.md 577 B
- references/mail-advanced.md 3.0 KB
- references/mail-basics.md 1.3 KB
- references/mail-dictionary.md 632 B
- references/mail-pyxa-api-reference.md 23 KB
- references/mail-recipes.md 1.9 KB
- references/mail-rules.md 988 B
- references/mailbox-archiver.md 649 B
- scripts/create_email.py 1.1 KB runs code
- scripts/create_mail_rule.py 2.2 KB runs code
- scripts/extract_emails_to_contacts.py 2.4 KB runs code
- scripts/search_and_archive.py 2.5 KB runs code
- scripts/set_up_mail_automation.py 925 B runs code
- scripts/set_up_mail_automation.sh 480 B runs code
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 5d ago First seen · 89 lines · 62 tokens per session scan A fead01817076
automating-mail is a skill published in the GitHub repository SpillwaveSolutions/automating-mac-apps-plugin (40 stars, last pushed 14d ago), licensed MIT. It adds 62 tokens to every session and 809 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
import-audio
Moves audio files to the correct album location with proper path structure. Use when the user has downloaded WAV files from Suno or other sources that need to be organized.
catch
Shape output for a human working through agents. Use on every response, out to and including casual conversation, even when the user did not ask for brevity.
lark-workflow-standup-report
日程待办摘要:编排 calendar +agenda 和 task +get-my-tasks,生成指定日期的日程与未完成任务摘要。适用于了解今天/明天/本周的安排。.
lark-attendance
飞书考勤打卡:查询自己的考勤打卡记录.
lark-im
飞书即时通讯:收发消息和管理群聊。发送和回复消息、搜索聊天记录、管理群聊成员、上传下载图片和文件(支持大文件分片下载)、管理表情回复、发送应用内/短信/电话加急、发送和处理交互卡片(Interactive Card)、监听卡片按钮回调(card.action.trigger)。当用户需要发消息、查看或搜索聊天记录、下载聊天中的文件、查看群成员、搜索群、创建群聊或话题群、管理标记数据、管理 Feed 置顶(添加/移除/查询置顶会话)、管理标签数据、处理卡片回调时使用。.
lark-workflow-meeting-summary
会议纪要整理工作流:汇总指定时间范围内的会议纪要并生成结构化报告。当用户需要整理会议纪要、生成会议周报、回顾一段时间内的会议内容时使用。.