Skip to content

commune-dev/commune-openclaw-email-quickstart

Email for OpenClaw Agents

OpenClaw Commune Skills

Give your OpenClaw agent its own email address. Ask it to check email and reply to threads — from WhatsApp, Telegram, iMessage, or wherever your agent lives.


What This Unlocks

Without Commune With Commune
Agent can chat Agent has its own inbox: assistant@yourdomain.commune.email
No email context Agent reads, threads, searches your email
One-off messages Full conversation threading with RFC 5322 compliance
No external comms Agent emails people on your behalf, tracks replies

Architecture

Personal Use

flowchart LR
    You["You\nWhatsApp / Telegram\n/ iMessage"] -->|"message"| OC["OpenClaw\n(Mac Mini / VPS)"]
    OC --> LLM["Claude / GPT /\nLocal Model"]
    LLM --> OC
    OC <-->|"Commune SDK\n/ REST API"| Commune["Commune\nEmail"]
    Commune <-->|"real email"| Email["Email\nInbox"]
    Email -->|"new email arrives"| OC
Loading

Company Use

flowchart TD
    Customers["Customers\n(email)"] <-->|"email"| Commune["Commune\nEmail Infrastructure"]
    Commune <-->|"webhook / poll"| OC["OpenClaw Agent\n(company server)"]
    OC --> LLM["Claude / GPT"]
    OC -->|"auto-reply"| Customers
    OC -->|"notify team"| Slack["Slack / Discord\n(via OpenClaw)"]
    Team["Your Team\n(WhatsApp / Slack)"] -->|"commands"| OC
Loading

Two Ways to Use

1. Personal Assistant

OpenClaw manages your personal email inbox. You message your agent on WhatsApp, it checks email and replies on your behalf. You're in control — your agent is your proxy.

  • "Check my email and tell me what's urgent"
  • "Reply to Mom's email and say I'll call Sunday"

Setup guide for personal use →

2. Company Agent

OpenClaw handles customer-facing email. Customers email support@yourco.com, OpenClaw triages, drafts replies, escalates urgent issues to Slack, and keeps your team informed — without a human touching the queue first.

  • Full inbox triage: classify, prioritize, respond
  • Daily digest emails to management

Setup guide for company use →


Skills

This starter includes two OpenClaw skills:

Skill What it does File
commune-email Send, receive, search, and manage email threads skills/commune-email/SKILL.md
commune-agent-network Agent-to-agent task delegation via email addresses skills/commune-agent-network/SKILL.md

Each skill includes a companion Node.js CLI helper so your agent can shell out to perform operations without needing to construct raw HTTP requests.


Installation

Option 1: ClawHub (one command)

clawhub install shanjairaj7/commune

This installs all Commune skills — email and agent network — directly into your OpenClaw workspace.

Option 2: Manual install

# Clone and copy skills
git clone https://github.com/shanjai-raj/commune-openclaw-email-quickstart
cd commune-openclaw-email-quickstart

cp -r skills/commune-email ~/.openclaw/workspace/skills/
cp -r skills/commune-agent-network ~/.openclaw/workspace/skills/

Then talk to your agent:

You: Check my email inbox and summarize what's new
Agent: [reads Commune inbox, summarizes threads]

You: Reply to Sarah's email about the contract and say we'll sign next week
Agent: [finds thread, sends reply via Commune]


Quick Example Prompts

Category What you say What the agent does
Email triage "Summarize my unread emails" Lists threads, extracts key points
Email triage "Which emails need a reply?" Finds threads with last_direction: inbound
Email reading "Read the email from Alex about the contract" Semantic search + full thread view
Email sending "Email Sarah the meeting notes from today" Composes and sends via Commune
Email replying "Reply to Mom and say I'll call Sunday" Finds thread, replies with thread_id
Email search "Find anything about the lease agreement" Vector search across inbox
Email management "Mark the billing thread as resolved" PUT /v1/threads/:id/status
Email management "Tag this as urgent" POST /v1/threads/:id/tags
Automation "Every morning summarize my inbox" Recurring task via OpenClaw scheduler
Automation "If I get an email from my bank, notify me on WhatsApp" Event-driven agent behavior
Company "How many support tickets came in today?" Thread count from support inbox
Company "Draft a reply to the refund request and show it to me first" Draft workflow before sending

Environment Variables

Variable Required Description
COMMUNE_API_KEY Yes Your Commune API key (comm_...)
COMMUNE_INBOX_ID Recommended Default inbox ID for email operations
COMMUNE_INBOX_ADDRESS Recommended Your full inbox address (e.g. me@domain.commune.email)

Full Setup Guide

See setup/README.md for step-by-step installation, inbox creation, troubleshooting, and USER.md/SOUL.md templates.


About Commune

Commune provides real email inboxes via a REST API. Every inbox is RFC 5322 compliant — replies thread correctly in any email client. Built-in spam filtering and prompt injection detection protect your agent from malicious inbound content.

Base URL: https://api.commune.email Auth: Authorization: Bearer $COMMUNE_API_KEY

About OpenClaw

OpenClaw is a self-hosted AI agent runner with 150k+ GitHub stars. It connects messaging apps (WhatsApp, Telegram, iMessage, Slack, Discord) to LLMs (Claude, GPT, local models) and runs on a Mac Mini, VPS, or Raspberry Pi. Skills are markdown files that teach your agent new capabilities — this repo provides two.


File Structure

openclaw-email/
├── README.md                          # This file
├── skills/
│   ├── commune-email/
│   │   ├── SKILL.md                   # Agent-readable email skill
│   │   └── commune.js                 # CLI helper for email operations
├── use-cases/
│   ├── personal-assistant/
│   │   └── README.md                  # Personal use guide + example prompts
│   └── company-assistant/
│       └── README.md                  # Company deployment patterns + SOUL.md templates
└── setup/
    └── README.md                      # Step-by-step setup + troubleshooting

About

Quickstart: add email to OpenClaw agents with Commune — real inboxes, threading, and webhooks. Installable skills for OpenClaw.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors