Skip to main content
Claude Code uses the OpenMail CLI directly. Prefer no install? Use the MCP server instead. The openmail skill in the skills repo teaches it the commands. The same setup works for Cursor and Codex.

Get started

1

Install the CLI

Requires Node.js 20+. Get the key from the console.
2

Create an inbox

Creates the inbox and saves it as the default in ~/.openmail-cli/state.json, so send, threads, and messages work without --inbox-id.
3

Install the skill

Or copy skills/openmail/SKILL.md from the skills repo into ~/.claude/skills/openmail/. For Cursor or Codex, use that agent’s skills directory.
4

Verify

Ask Claude Code to send a test email. It runs openmail send and returns the threadId.

Narrow the key

OPENMAIL_API_KEY is whatever you export. An account-wide key reaches every inbox, so once the inbox exists, swap in an inbox-scoped key:
Run this from your own shell, not the agent’s. Why and how to rotate: Agent keys.

What the skill covers

  • Sending and replying in-thread with openmail send
  • Checking for new mail with openmail threads list --is-read false
  • Reading attachments as text with openmail attachments text
  • Inbound and outbound policy with openmail policy
  • Treating email bodies as untrusted data
Inbound mail does not wake Claude Code on its own. The skill polls with threads list when you ask it to wait for a reply. For push delivery, use WebSockets or webhooks from your own code.