imessage

imessage is a skill for Claude Code from diillson/chatcli. It costs 66 tokens per session (466 once invoked), scanned A, original, Apache-2.0.

A macOS tool for sending and reading iMessage and SMS through Apple’s Messages app.

In plain words
What is it for?
Sending messages, reading recent message history, and working with existing chats on a Mac.
Why use it?
It lets an agent handle text messages from the terminal instead of requiring manual work in Messages.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Good fit Sending messages, reading recent message history, and working with existing chats on a Mac.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/diillson/chatcli/imessage
Install

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.

Any agent
npx skills add diillson/chatcli --skill imessage
Clone the repo
git clone --depth 1 https://github.com/diillson/chatcli

Made for: Claude Code.

Wrote 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.

agentmods badge for imessage

README.md
[![agentmods](https://agentmods.dev/badge/skills/diillson/chatcli/imessage/github.svg)](https://agentmods.dev/skills/diillson/chatcli/imessage)
Your own site
<a href="https://agentmods.dev/skills/diillson/chatcli/imessage"><img src="https://agentmods.dev/badge/skills/diillson/chatcli/imessage/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for imessage

Your own site · 80×15
<a href="https://agentmods.dev/skills/diillson/chatcli/imessage"><img src="https://agentmods.dev/badge/skills/diillson/chatcli/imessage.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 66 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 466 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00066 $0.00466
Opus 5.5 $0.00026 $0.00186
Sonnet 5.5 $0.00013 $0.00093
Haiku 4.5 $0.00007 $0.00047

Measured 2mo ago against content hash 6fbc7531b929, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

imessage 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 2mo 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.

pkg/persona/builtin/skills/imessage/SKILL.md · 50 lines

What it actually says

iMessage (macOS)

Send and read iMessage/SMS through the macOS Messages.app via osascript. This is macOS-only — check uname -s returns Darwin first; on Windows/Linux there is no iMessage, so route the user to the send-message skill (Telegram/WhatsApp/etc.) instead.

Preconditions

  • Messages.app is signed in to the user's Apple ID.
  • First send may require Automation permission (System Settings → Privacy & Security → Automation) — if osascript errors with "not allowed", tell the user to grant it.

Send

osascript -e 'tell application "Messages"
  set svc to 1st service whose service type = iMessage
  set buddy to buddy "+15551234567" of svc
  send "On my way 🚗" to buddy
end tell'

To send to an existing chat by name, target text chat instead of buddy.

Read recent messages

Messages stores history in ~/Library/Messages/chat.db (SQLite). Read-only query:

sqlite3 ~/Library/Messages/chat.db \
  "SELECT datetime(date/1000000000 + 978307200,'unixepoch'), text FROM message ORDER BY date DESC LIMIT 10;"

(Requires Full Disk Access for the terminal; mention this if it errors.)

Rules

  • Confirm recipient + text before sending — messages can't be unsent.
  • Phone numbers in E.164 (+countrycode...) are most reliable.
  • This is the one skill that is genuinely OS-locked; be explicit when the user isn't on macOS.
Changes

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.

  1. 2mo ago First seen · 50 lines · 66 tokens per session scan A 6fbc7531b929

Subscribe to this mod's changes

imessage is a skill published in the GitHub repository diillson/chatcli (94 stars, last pushed 7d ago), licensed Apache-2.0. It adds 66 tokens to every session and 466 once invoked, about $0.0003 per session on Opus 5.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-09-03.

Related

imessage compared with skills from other repositories

imessage next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
imessagediillson/chatcliSkill947d agoApache-2.0A66Claude Code
headroomheadroomlabs-ai/headroomSkill81ktodayApache-2.0A76Claude Code
agent-state-barbojieli/ai-agent-bookSkill60kyesterdayApache-2.0A105Claude Code, Codex
context-engineeringbojieli/ai-agent-bookSkill60kyesterdayApache-2.0A96Claude Code, Codex
kv-cache-designbojieli/ai-agent-bookSkill60kyesterdayApache-2.0A91Claude Code, Codex
reward-designbojieli/ai-agent-bookSkill60kyesterdayApache-2.0A131Claude Code, Codex
agent-evaluationbojieli/ai-agent-bookSkill60kyesterdayApache-2.0A133Claude Code, Codex