AgentBox
Supports Google (Gmail/Google Workspace) through IMAP TLS polling and SMTP sending, giving AI agents the ability to read, send, and process verification emails in their own mailboxes.
Supports Hostinger email hosting through IMAP TLS polling and SMTP sending, enabling AI agents to receive and respond to email from Hostinger mailboxes.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@AgentBoxcheck my inbox for the latest OTP verification code"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
⚡ AgentBox
The Sovereign Autonomous Mailbox & Identity Layer for AI Agents
AgentBox gives autonomous AI coding agents (Claude Code, Cursor, Antigravity, OpenAI Swarm) persistent machine-native email identities, object-level authorization, and sovereign communication infrastructure. Receive emails, capture 2FA verification codes in <0.14ms, verify activation magic links with anti-phishing protection, and dispatch outbound replies with zero third-party cloud lock-in.
Quick Start • Agent Identity & Security • Benchmarks • MCP Tools • Link Safety • Architecture
💡 Why AgentBox?
When autonomous AI agents build software, register accounts on developer platforms, or run automated QA pipelines, they inevitably hit Email Verification, 2FA, and Identity Gates.
Problem with Traditional Approaches | The AgentBox Sovereign Solution |
❌ Paid SaaS email APIs charge per-email and require credit cards | ✅ 100% Free & Self-Hosted on local SQLite ( |
❌ Webhook services require public URLs / tunneling (Ngrok) | ✅ Built-in IMAP TLS Poller & Raw Inbound SMTP Server (Hostinger, Titan, Google, Stalwart) |
❌ Polling REST APIs takes 5–30 seconds with rate limit bottlenecks | ✅ Event-Driven Async Wake-up (<0.001ms) via Tokio broadcast channels |
❌ Cross-agent data leaks with unauthenticated tools | ✅ Mandatory Scoped Capabilities & Object-Level Resource Ownership |
❌ Agents lack security and fall for phishing / open-redirect links | ✅ Deep URL Safety Engine (Punycode, Raw IP & Open-Redirect Defense) |
❌ Manual MCP setup requiring complex JSON edits in IDE configs | ✅ |
Related MCP server: Mailgent MCP Server
🧑🚀 First-Class Agent Identity & Object-Level Security
AgentBox moves beyond generic mailboxes by introducing First-Class Agent Identities with strict object-level resource ownership:
# Provision a scoped identity for an autonomous browser QA agent
npx agentbox-mail agent create browser-qa --capabilities "inbox.read,otp.read,links.read"╔══════════════════════════════════════════════════════════════════╗
║ 🧑🚀 AGENT IDENTITY PROVISIONED ║
╠══════════════════════════════════════════════════════════════════╣
║ Agent ID : agent_browser-qa_7f92a1 ║
║ Name : browser-qa ║
║ Email : browser-qa-7f92a1@apocalypto.in ║
║ Auth Token : agb_92d7e8f1c3a04b12 ║
║ Capabilities : ["inbox.read", "otp.read", "links.read"] ║
║ Status : active ║
╚══════════════════════════════════════════════════════════════════╝
⚠️ NOTE: Store this auth_token securely. It is only displayed once upon creation and cannot be retrieved again.🔐 Multi-Tier Security Enforcement:
Incoming Tool / API Request
│
▼
┌───────────────────────────┐
│ 1. Validate Auth Token │ ➔ Reject if invalid or revoked
└─────────────┬─────────────┘
│
▼
┌───────────────────────────┐
│ 2. Check Capability Scope │ ➔ E.g. Require "otp.read"
└─────────────┬─────────────┘
│
▼
┌───────────────────────────┐
│ 3. Object-Level Ownership │ ➔ Agent A CANNOT read Agent B's mailbox
└─────────────┬─────────────┘
│
▼
┌───────────────────────────┐
│ 4. Execute Protected Tool │
└───────────────────────────┘Credential Hygiene: Tokens are displayed only once upon creation. Read endpoints (
get_agent_identity,list_agent_identities) use safe public structs that never leak authentication secrets.Cross-Agent Isolation: An agent possessing
otp.readis strictly restricted to mailboxes it owns (owner_agent_id). Attempting cross-mailbox access returns a structuredAccessDeniederror.
📊 Reproducible Performance Benchmarks
AgentBox includes a complete benchmark test suite (tests/benchmark.rs) measuring the entire pipeline from raw bytes to full JSON-RPC output:
cargo test --release --test benchmark -- --nocapture⚡ Verified Full End-to-End MCP Pipeline (1,000 Cycles):
Tested Pipeline: Raw MIME Ingestion ➔ mail-parser ➔ SafeLink Analysis ➔ Regex OTP ➔ SQLite INSERT ➔ Broadcast Dispatch ➔ Authenticated MCP Tool Call (tools/call) ➔ JSON-RPC Result Output
Pipeline Metric | Measured Latency | Throughput |
Average (Mean) |
| 1,468 complete MCP cycles/sec |
p50 Median |
| — |
p95 |
| — |
p99 |
| — |
⚡ Sub-Component Microsecond Latencies (10,000 Iterations):
Event Bus Channel Dispatch:
0.216 µs(0.0002 ms) — 4.62 Million events/secLink Safety & Anti-Redirect:
0.652 µs(0.0007 ms) — 1.53 Million checks/secOTP Regex Extraction:
138.2 µs(0.138 ms) — 7,230 extractions/sec
Note: External email arrival latency depends on upstream mail delivery; once bytes hit AgentBox (SMTP/IMAP/HTTP), end-to-end parsing, DB persistence, capability authorization, and JSON-RPC response completes in <0.7ms.
🛡️ Link Safety & Anti-Phishing Engine
To protect autonomous agents from credential harvesting and malicious open redirects, AgentBox parses all inbound links through a deep safety analyzer:
🚫 Open-Redirect Detection: Inspects parameters like
?redirect=,?url=,?next=,?dest=,?to=.🚫 Raw IP Address Defense: Blocks URLs targeting raw IPv4 addresses instead of reputable hostnames.
🚫 Punycode Homograph Defense: Flags Unicode/Punycode domain spoofing (
xn--).🔒 Protocol Validation: Distinguishes secure HTTPS endpoints from insecure HTTP.
{
"url": "https://signin.aws.amazon.com/verify?token=abc_123",
"domain": "signin.aws.amazon.com",
"is_safe": true,
"has_open_redirect": false,
"confidence": 0.98
}🛠️ MCP Tools Reference
AgentBox implements the Model Context Protocol (MCP) specification over stdio:
Category | Tool | Parameters | Description |
Identity |
|
| Creates a persistent identity and returns a one-time secret auth token. |
Identity |
|
| Retrieves public agent capabilities, status, and metadata (token sanitized). |
Identity |
| — | Lists all registered public agent identities. |
Identity |
|
| Revokes an agent identity and invalidates its auth token immediately. |
Mailbox |
|
| Creates a new virtual mailbox linked to the calling agent identity. |
Mailbox |
|
| Extracts the newest 4–8 digit verification code with ownership validation. |
Mailbox |
|
| Event-Driven Hook: Async Tokio broadcast channel wakes the agent in <0.001ms. |
Mailbox |
|
| Returns parsed activation links with Link Safety & Anti-Redirect Analysis. |
Mailbox |
|
| Retrieves recent messages, full body text, HTML, and sender metadata. |
Mailbox |
|
| Dispatches outbound emails via SMTP relay with capability check. |
Mailbox |
|
| Deletes a temporary mailbox and purges stored messages. |
🚀 Quick Start
1. Headless NPM CLI (Zero Setup)
Instantly auto-configure your AI tools in 1 second:
# 1-Click Auto-Install MCP Server & AI Skill into Claude Code, Cursor, Antigravity
npx agentbox-mail init
# Start MCP stdio server
npx agentbox-mail mcp
# Create an Agent Identity with scoped capabilities
npx agentbox-mail agent create coder --capabilities "inbox.read,otp.read,links.read"
# Retrieve latest OTP code
npx agentbox-mail otp agent@yourdomain.com
# Launch Web Dashboard
npx agentbox-mail ui2. Native Electron Desktop App
For a complete standalone desktop experience with system tray and OS notifications:
# Clone the repository
git clone https://github.com/RABNEER/AgentBox.git
cd AgentBox
# Install dependencies and start Desktop App
npm install
npm run app3. High-Speed Rust Core Daemon
# Build the optimized production binary
cargo build --release
# Start all-in-one daemon (HTTP Port 3000 + SMTP Port 2525)
./target/release/agentbox-mail server --port 3000🏗️ Architecture
┌───────────────────────────┐
│ Incoming Mail Sources │
└─────────────┬─────────────┘
│
┌──────────────────────────────┼──────────────────────────────┐
│ │ │
▼ ▼ ▼
┌───────────────────────┐ ┌───────────────────────┐ ┌───────────────────────┐
│ Hostinger / Titan / │ │ Raw SMTP Listener │ │ Inbound HTTP Webhook │
│ Google IMAP TLS (993) │ │ (0.0.0.0:2525) │ │ (POST /v1/inbound) │
└───────────┬───────────┘ └───────────┬───────────┘ └───────────┬───────────┘
│ │ │
└──────────────────────────────┼──────────────────────────────┘
│
▼
┌─────────────────────────────┐
│ High-Speed Regex Parser │
│ • 4–8 Digit OTP Isolator │
│ • Link Safety Engine │
└──────────────┬──────────────┘
│
▼
┌─────────────────────────────┐
│ Embedded SQLite Storage │
│ (`agentbox.db`) │
│ • Accounts • Identities │
│ • Messages • Capabilities │
│ • Resource Ownership Graph │
└──────────────┬──────────────┘
│
┌──────────────────────────────┼──────────────────────────────┐
│ │ │
▼ ▼ ▼
┌───────────────────────┐ ┌───────────────────────┐ ┌───────────────────────┐
│ Realtime SSE Bus │ │ MCP Server (stdio) │ │ Native Desktop App / │
│ (`GET /v1/events`) │ │ Scoped Capabilities │ │ Web Dashboard (:3000) │
│ │ │ Object-Level Auth │ │ │
└───────────────────────┘ └───────────────────────┘ └───────────────────────┘📄 License
Distributed under the MIT License. See LICENSE for more information.
Built with 🖤 by RABNEER & The AgentBox Open Source Community
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseBqualityCmaintenanceDisposable email MCP server for autonomous AI agents. Create labeled temporary inboxes, wait for verification emails, extract OTP codes and confirmation links — zero human intervention required.6MIT
- Alicense-qualityFmaintenanceProvides identity infrastructure for AI agents to manage email communications, including sending, replying, and organizing messages. It also includes a secure vault for managing credentials and generating TOTP codes.22MIT
- Alicense-qualityBmaintenanceAn MCP server that provides AI agents with a persistent, agent-native email mailbox for sending, receiving, and managing emails through bounded-context retrieval, idempotent operations, and explicit acknowledgement.MIT
- AlicenseAqualityAmaintenanceProvides disposable email inboxes for AI agents to automatically receive and extract OTPs and magic links, enabling seamless email verification during autonomous workflows.396MIT
Related MCP Connectors
Hosted email MCP for AI agents with inboxes, send/receive, memory, recovery, and credits.
Authenticated email gateway for AI agents — per-agent inboxes, HITL approval, SPF/DKIM verified.
Authenticated email gateway for AI agents — per-agent inboxes, HITL approval, SPF/DKIM verified.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/RABNEER/AgentBox'
If you have feedback or need assistance with the MCP directory API, please join our Discord server