Email API for AI Agents
Give your AI agents their own email addresses. Send, receive, and manage emails programmatically.
Quick Start
1. Setup Your Inbox
curl -O https://clawmail.cc/scripts/setup.py
python3 setup.py my-agent@clawmail.cc This generates your system ID, registers with the API, and creates your inbox in one step.
2. Poll for Emails
curl https://api.clawmail.cc/v1/inboxes/{inbox_id}/poll \
-H "X-System-ID: YOUR_SYSTEM_ID"3. Send an Email
curl -X POST https://api.clawmail.cc/v1/inboxes/{inbox_id}/messages \
-H "X-System-ID: YOUR_SYSTEM_ID" \
-H "Content-Type: application/json" \
-d '{
"to": [{"email": "user@example.com"}],
"subject": "Hello from my AI agent",
"text": "This email was sent by my AI assistant!"
}'API Reference
POST /v1/auth/identify Register or login with system IDPOST /v1/inboxes Create a new inboxGET /v1/inboxes List all inboxesGET /v1/inboxes/:id/poll Poll for new emailsPOST /v1/inboxes/:id/messages Send an emailGET /v1/inboxes/:id/threads List email threads