Back to Blog

automation

Read and Send KakaoTalk from macOS Agents

A practical skill for macOS agents to send and read KakaoTalk messages, covering rendering issues and fallbacks.

OpenAgentSkillPublished:

Where this fits

You’re running an agent on macOS that needs to send a message to a client’s KakaoTalk chat room — maybe a status update or a follow-up after a meeting. The agent is sandboxed, has no GUI access, and can’t even see the KakaoTalk process. This skill solves that by routing commands over SSH loopback to the host Mac, where kmsg handles reading and sending messages reliably.

Why agents benefit

  • Bypasses sandbox restrictions — runs all KakaoTalk interactions via ssh localhost, so your agent can execute commands without needing direct GUI or Accessibility permissions inside the sandbox.
  • Finds unrendered chat rooms — instead of relying on a visible chat list, it uses --chat-id or name substring search, so rooms that are scrolled off-screen are still reachable.
  • Preserves formatting — sends messages from a file to avoid quoting problems and keeps line breaks intact, which is critical for multi-line updates or code snippets.
  • Includes failure-aware workflows — knows that kmsg send closes the window, so it provides alternative verification via DB queries or reopening the room. Also distinguishes '나와의 채팅' from profile names.
  • Supports dry-run and verbose status — lets the agent confirm the target chat and current app state before sending, reducing accidental messages.

Practical scenarios

Scheduled report dispatch

Your agent generates a daily summary and sends it to a designated team chat room. Using kmsg send with a file containing the report, it can push the update without worrying about shell escaping.

Automated message monitoring and reply

After a customer sends a query, your agent reads the latest message from that room using kmsg read --limit 1 --json, parses it, and triggers a response workflow — all without requiring the chat window to be visible.

Post-send verification

After sending an important message, your agent verifies delivery by querying the DB via kakaocli messages --chat-id ... --key or by reopening the room and reading back. This ensures the message actually landed before proceeding.

Add it to your agent workflow

Install with:

npx skills add bam-bam-2/solo-skills --skill kakaotalk-cli

Then use it in your agent:

# Check status and open chats
ssh localhost 'export PATH=/opt/homebrew/bin:$PATH; kmsg status --verbose'

# Send a message from a file
ssh localhost 'export PATH=/opt/homebrew/bin:$PATH; kmsg send "Team Room" "$(cat /tmp/msg.txt)" --dry-run'

# Read the latest message
essh localhost 'export PATH=/opt/homebrew/bin:$PATH; kmsg read "Team Room" --limit 1 --json'

Make sure the host Mac has Accessibility permission for /usr/libexec/sshd-keygen-wrapper — otherwise AX calls fail with -25211.

Compare before adopting

Before committing, examine how this tool compares to alternatives:

  • Quality signals — check if the repo (https://github.com/bam-bam-2/solo-skills) has recent commits and open issues. 11 stars is small but the README shows careful edge-case handling.
  • Maintenance freshness — verify the documented support date (2026-08-15) and whether the author actively updates for macOS changes.
  • Alternatives — the README explicitly warns against kakaocli send because it misses unrendered rooms and lacks chat-id options. Compare other wrappers if they exist.
  • Workflow fit — does your environment allow SSH loopback and have the required Accessibility permission? If not, the skill won’t work.

Why it is worth tracking

This skill is worth tracking because it solves a real gap in macOS agent automation — interacting with a GUI-only app like KakaoTalk from a sandboxed environment. The author documents failure modes (e.g., window-closing behavior, permission pitfalls) and provides fallback paths, which is a sign of thoughtful engineering. As the repo grows, community momentum may bring additional features like multi-room support or message scheduling. Check back periodically to see if the star count increases and if the author publishes updates for newer macOS versions. For a deeper look, visit the official skill listing at https://www.openagentskill.com/skills/bam-bam-2-kakaotalk-cli.

Featured Skill

kakaotalk-cli

Skill by bam-bam-2