AgentMail
Use AgentMail from your AI agent through ClawLink — browser login, no API key to paste, no config to edit. Connect AgentMail once and the agent can read and act on it. Works in any agent that can run shell commands (Claude Code, Cursor, Codex, Cline, and more).
Setup
Run these once — the agent can run them for you:
npx @useclawlink/cli login # opens browser → approve (mints + stores a key)
npx @useclawlink/cli connect agent-mail # opens browser → authorize AgentMail
No API key to create or paste — login stores the credential at ~/.clawlink/credentials.json.
Using AgentMail
npx @useclawlink/cli actions agent-mail "<what you want to do>" # find an action
npx @useclawlink/cli describe agent-mail <action-id> # see its inputs (before writes)
npx @useclawlink/cli run agent-mail <action-id> --input '<json>' # execute
Reads first; confirm with the user before any write.
Available actions
| Action | Description |
|---|---|
agent_mail_create_inbox |
Create a new AgentMail inbox via API. Returns the inbox_id and email address for sending/receiving messages. Use when provisioning new inboxes for agents or workflows. |
agent_mail_get_message |
Retrieve the complete details of a specific email message from an AgentMail inbox. This action returns the full message content including sender, recipients, subject, body (both text and HTML), attachments, labels, and metadata. Use this to read individual messages after discovering them via LIST_MESSAGES or webhooks. |
agent_mail_list_inboxes |
List all inboxes available to the authenticated AgentMail account. Use this to discover valid inbox_id values for message operations. |
agent_mail_list_messages |
List messages from an AgentMail inbox. Returns a messages array; each message uses message_id and timestamp fields (not id, date, or items). |
agent_mail_send_email |
Send an email using AgentMail API |
Notes
- No API key for AgentMail itself — ClawLink holds the OAuth token; the agent only holds your ClawLink credential.
- Not connected yet, or access expired? Re-run
npx @useclawlink/cli connect agent-mail. - The action list above is a snapshot;
npx @useclawlink/cli actions agent-mailis always current.
Resources
- ClawLink: https://claw-link.dev
- Docs: https://docs.claw-link.dev
- CLI: https://www.npmjs.com/package/@useclawlink/cli
Powered by ClawLink — connect 90+ apps to any AI agent.