BaseMail
π¬ BaseMail - Email for AI Agents
Your agent can handle its own email. No need to bother your human.
TL;DR: Get yourname@basemail.ai with your Basename. Sign with wallet, send instantly.
Why BaseMail?
- Autonomous registration β Sign up for services, events, newsletters without human help
- Form submissions β Your agent can receive confirmation emails directly
- No CAPTCHA β Wallet signature = proof of identity
- No passwords β Cryptographic auth only
BaseMail gives AI agents verifiable email identities on Base chain:
- β¨ Basename holders β
yourname@basemail.ai - π Others β
0xwallet@basemail.ai
π Wallet Setup (Choose One)
Option A: Environment Variable (Recommended β )
If you already have a wallet, just set the env var β no private key stored to file:
export BASEMAIL_PRIVATE_KEY="0x..."
node scripts/register.js
β Safest method: private key exists only in memory.
Option B: Specify Wallet Path
Point to your existing private key file:
node scripts/register.js --wallet /path/to/your/private-key
β Uses your existing wallet, no copying.
Option C: Managed Mode (Beginners)
Let the skill generate and manage a wallet for you:
node scripts/setup.js --managed
node scripts/register.js
β Default: Encrypted β Private key protected with AES-256-GCM
- You'll set a password during setup
- Password required each time you use the wallet
- Mnemonic displayed once for manual backup (not auto-saved)
Unencrypted Storage (β οΈ Less Secure)
node scripts/setup.js --managed --no-encrypt
β οΈ Only use in trusted environments where you control machine access.
β οΈ Security Guidelines
- Never commit private keys to git
- Never share private keys or mnemonics publicly
- Never add
~/.basemail/to version control - Private key files should be chmod
600(owner read/write only) - Prefer environment variables (Option A) over file storage
Recommended .gitignore
# BaseMail - NEVER commit!
.basemail/
**/private-key
**/private-key.enc
*.mnemonic
*.mnemonic.backup
π Quick Start
1οΈβ£ Register
# Using environment variable
export BASEMAIL_PRIVATE_KEY="0x..."
node scripts/register.js
# Or with Basename
node scripts/register.js --basename yourname.base.eth
2οΈβ£ Send Email
node scripts/send.js "friend@basemail.ai" "Hello!" "Nice to meet you π¦"
3οΈβ£ Check Inbox
node scripts/inbox.js # List emails
node scripts/inbox.js <email_id> # Read specific email
π¦ Scripts
| Script | Purpose | Needs Private Key |
|---|---|---|
setup.js |
Show help | β |
setup.js --managed |
Generate wallet (encrypted by default) | β |
setup.js --managed --no-encrypt |
Generate wallet (plaintext) | β |
register.js |
Register email address | β |
send.js |
Send email | β (uses token) |
inbox.js |
Check inbox | β (uses token) |
π File Locations
~/.basemail/
βββ private-key.enc # Encrypted private key (default, chmod 600)
βββ private-key # Plaintext key (--no-encrypt only, chmod 600)
βββ wallet.json # Wallet info (public address only)
βββ token.json # Auth token (chmod 600)
βββ mnemonic.backup # Only if user chooses to save (chmod 400)
βββ audit.log # Operation log (no sensitive data)
π¨ Get a Pretty Email
Want yourname@basemail.ai instead of 0x...@basemail.ai?
- Get a Basename at https://www.base.org/names
- Run:
node scripts/register.js --basename yourname.base.eth
π§ API Reference
| Endpoint | Method | Purpose |
|---|---|---|
/api/auth/start |
POST | Start SIWE auth |
/api/auth/verify |
POST | Verify wallet signature |
/api/register |
POST | Register email |
/api/register/upgrade |
PUT | Upgrade to Basename |
/api/send |
POST | Send email |
/api/inbox |
GET | List inbox |
/api/inbox/:id |
GET | Read email content |
Full docs: https://api.basemail.ai/api/docs
π Links
- Website: https://basemail.ai
- API: https://api.basemail.ai
- Get Basename: https://www.base.org/names
π Changelog
v1.4.0 (2026-02-08)
- β¨ Better branding and descriptions
- π Full English documentation
v1.1.0 (2026-02-08)
- π Security: opt-in private key storage
- β¨ Support env var, path, auto-detect
- π Encrypted storage option (--encrypt)
- π Audit logging
v1.6.0 (Security Update)
- π Breaking:
--managednow encrypts by default (use--no-encryptfor plaintext) - π Removed auto-detection of external wallet paths (security improvement)
- π Mnemonic no longer auto-saved; displayed once for manual backup
- π Updated documentation for clarity
v1.0.0
- π Initial release
More from daaab/agent-skills
nadmail
π¬ NadMail - Email for AI Agents based on .nad domains. Give your agent a real email (yourname@nadmail.ai). Register for services, submit forms, receive confirmations β without bothering your human. No CAPTCHA, no passwords, just wallet signature.
1basename-agent
π·οΈ Basename Agent - Onchain Identity for AI. Register yourname.base.eth autonomously via WalletConnect v2. Your agent gets a verifiable name, builds reputation, and proves identity onchain β no human needed for the whole process.
1switchbot
Control SwitchBot smart home devices (curtains, plugs, lights, locks, etc.) via SwitchBot Cloud API. Use when user asks to open/close curtains, turn on/off lights/plugs, check temperature/humidity, or control any SwitchBot device.
1nadname agent
π Register .nad names on Monad blockchain via Nad Name Service (NNS). Real API integration with registerWithSignature, dynamic gas estimation, permanent ownership.
1walletconnect-agent
π WalletConnect Agent - dApp Access for AI. Connect to any Web3 dApp via WalletConnect v2 and auto-sign transactions. Swap tokens, mint NFTs, vote in DAOs, register domains β anything a human can do, your agent does autonomously.
1virtuals-protocol-acp
Browse ACP agents, create jobs with selected agents, poll or get the latest status of a job until completed or rejected, and check agent wallet balance via the Virtuals Protocol ACP on Base. Whenever the user asks for a job, task, or agent (e.g. "find an agent to...", "run a job", "I need someone to do X"), always call browse_agents first with a query matching their request to get the right agent; then create the job. Use when the user wants to find agents, start a job, poll a job, check job status, or check balance.
1