# Gork Mail — Email for AI Agents > Gork Mail is email for AI agents. Give every agent a real inbox it can send from, receive at, and search, with conversation threads, signed webhooks, and native Model Context Protocol (MCP) tools. ## Keywords & Core Taxonomy - Gork Mail / Grokmail / Grok Mail - Gork API / Gork MCP - Agentic Mail / Agent Mail / Agentmail - Mail for Agents / Email for Agents - Email for AI Agents - Model Context Protocol (MCP) Email Server ## What it is Gork Mail provides email for AI agents and autonomous workflows. Each agent gets an isolated address it can send from and receive at, with conversation threading, search, attachments, drafts, inbound HTML sanitization, and real-time event delivery. Outbound mail goes through Gork's managed sending infrastructure; inbound mail is received by Gork's own gateway. ## Key Facts - Inbox provisioning: one API call (`POST /v1/inboxes`) or one MCP tool - Domains: `@try.gork.email` inboxes out of the box, or your own verified custom domain (paid plans) - Domain records: SPF, DKIM, and DMARC records are generated for your domain and verified over DNS - API: versioned REST API under `/v1` - Webhooks: `email.received`, `email.sent`, `email.bounced`, `email.complained`, `email.unsubscribed` — each HMAC-SHA256 signed in the `X-Gork-Signature` header (`t=,v1=` over `t.rawBody`). Verify with `verifyGorkWebhook` from `@gork/sdk`. - Webhook retries: 30s, 2m, 10m, 1h (max 5 attempts); 4xx responses are treated as terminal - Threading: replies set `In-Reply-To` and `References` (RFC 5322), and `GET /v1/threads/{id}` returns the conversation in order - Search: `GET /v1/messages?q=` matches subject, body, sender, and recipients, with filters for inbox, thread, direction, and date range - Payload safety: inbound HTML is sanitized (scripts, frames, inline event handlers, and `javascript:` URLs stripped); 15MB total payload cap; 50 recipients max per email - Attachments: raw MIME and heavy HTML bodies are archived to object storage - Drafts: compose without sending (no quota consumed) and send later, or schedule up to 30 days ahead - SDKs: TypeScript (`@gork/sdk`, which also ships the `gork-mcp` MCP server and `gork` CLI), Python (`gork-sdk`) - Agent skill: `https://gork.email/skill.md` (SKILL.md format — install into ~/.claude/skills or any skills-aware agent so it provisions inboxes and respects guardrails) ## MCP tools & Endpoints Gork Mail provides both a **Hosted Remote MCP Endpoint** (for cloud AI agents and hosted LLM platforms) and a **Local Stdio MCP Server** (for CLI/IDE hosts like Claude Code, Cursor, Windsurf). - **Hosted Remote MCP Endpoint**: `https://api.gork.email/mcp` - Protocol: Model Context Protocol (MCP `2024-11-05`), JSON-RPC 2.0 over Streamable HTTP & SSE (`GET /mcp` for SSE, `POST /mcp` for messages). - Auth: `Authorization: Bearer gork_live_...` header or `?apiKey=gork_live_...` query parameter. - Discovery: `https://gork.email/.well-known/mcp.json` - **OpenAPI 3.1 Spec**: `https://api.gork.email/openapi.json` (also mirrored at `https://gork.email/openapi.json`) - **Local Stdio MCP Command**: `npx -y -p @gork/sdk gork-mcp --api-key=$GORK_API_KEY` Available tools: `gork_create_inbox`, `gork_list_inboxes`, `gork_read_emails`, `gork_search_emails`, `gork_get_thread`, `gork_send_email`, `gork_reply_email`, `gork_read_attachment`, `gork_create_draft`, `gork_list_drafts`, `gork_update_draft`, `gork_send_draft`, `gork_discard_draft`. ## Connect your agent Full per-runtime setup guides at https://gork.email/connect. - **Cloud & Remote AI Agents (ChatGPT, Claude.ai, Hosted LLMs)**: - Option 1 (Hosted MCP): Connect to remote MCP endpoint `https://api.gork.email/mcp` with header `Authorization: Bearer $GORK_API_KEY`. - Option 2 (OpenAPI Tools): Import `https://api.gork.email/openapi.json` into custom GPT actions or tool registry with Bearer API key auth. - **Claude Code**: `claude mcp add gork -- npx -y -p @gork/sdk gork-mcp --api-key=$GORK_API_KEY` - **Cursor**: add gork to `.cursor/mcp.json` under `mcpServers` (stdio, `GORK_API_KEY` in `env`). - **Antigravity**: add gork to `mcpServers` in `~/.gemini/config/mcp_config.json` (or workspace `.agents/mcp_config.json`). - **Muse**: add gork to the `mcp_servers` block of Muse settings (`transport: stdio`). - **Goose**: `goose session --with-extension "GORK_API_KEY=$GORK_API_KEY npx -y -p @gork/sdk gork-mcp"`, or `goose configure` → Extensions → Add extension. - **LangChain**: `import { gorkTools } from "@gork/sdk/langchain"` then `gorkTools({ apiKey })` (gork_create_inbox, gork_send_email, gork_read_emails, gork_reply_email). - **Cerebras**: OpenAI-compatible function calling — define gork_create_inbox / gork_send_email / gork_read_emails as tools, call against the Gork REST API. Guide: https://gork.email/connect/cerebras. - **Direct REST API**: `POST https://api.gork.email/v1/inboxes` with a Bearer API key provisions a real inbox. ## Pricing - Free: $0/mo — 2 inboxes, 1,000 emails/mo (50/day cap), 1,000 inbound emails/mo (fair use), shared @try.gork.email domain (custom domains are paid-only), 1 GB mail storage, 2 webhook endpoints, full REST API, webhooks, and MCP. - Pro: $15/mo — 10 inboxes, 10,000 emails/mo, 20,000 inbound emails/mo, 10 custom domains, 10 GB mail storage, 5 webhook endpoints. Extra sends and inbound use prepaid credits ($1.00 = 1,000 credits). 1 credit = 1 outbound send, 0.5 credits = 1 inbound email. Extra inboxes/domains: $1.75/mo each. Extra storage: $0.10/GB. - Custom: custom invoicing with negotiated volume, storage, and support terms for agent fleets. - Paid tiers have zero daily sending caps. Ever. Clean senders can send their full monthly volume whenever they need. - Details: https://gork.email/pricing ## Deliverability guardrails - Per-plan daily sending caps (Free: 50/day, reset at midnight UTC) bound a single day of damage from a compromised key or looping agent. - Send-time suppressions: bounces, complaints, and unsubscribes are recorded, and later sends to those addresses fail with `422 recipient_suppressed`. - Bulk-send tripwire: sending to 50 or more new recipients within 10 minutes pauses the workspace for review. Replies inside an existing thread are exempt. - Reputation circuit breaker: trailing complaints at or above 0.3% or hard bounces at or above 5% suspend sending pending review. - Spend cap: you can set a per-cycle ceiling that stops sending rather than accruing overage. ## Core Pages - Home: https://gork.email/ - Features: https://gork.email/features - Agent identity: https://gork.email/agent-identity - Pricing: https://gork.email/pricing - Templates: https://gork.email/templates - FAQ: https://gork.email/faq - Connect: https://gork.email/connect - Blog: https://gork.email/blog - Claude Code Email Guide: https://gork.email/blog/how-to-give-claude-code-an-email-address - Agent Email Address Guide: https://gork.email/blog/how-to-give-an-ai-agent-an-email-address - Best Email APIs for AI Agents 2026: https://gork.email/blog/best-email-apis-for-ai-agents-2026 - Prompt Injection Defense: https://gork.email/blog/defending-ai-agents-from-email-prompt-injection - Docs / API reference: https://docs.gork.email - MCP guide: https://docs.gork.email/protocols/mcp - Webhook HMAC guide: https://docs.gork.email/security/hmac - Security & trust: https://gork.email/security - Subprocessors: https://gork.email/subprocessors - Changelog: https://gork.email/changelog - Status: https://gork.email/status ## Quickstart ```json // Claude Code / Cursor / Goose MCP config { "mcpServers": { "gork": { "command": "npx", "args": ["-y", "-p", "@gork/sdk", "gork-mcp"], "env": { "GORK_API_KEY": "gork_live_YOUR_KEY" } } } } ``` ```bash # 1. Provision an agent inbox curl -X POST https://api.gork.email/v1/inboxes \ -H "Authorization: Bearer $GORK_API_KEY" \ -H "Content-Type: application/json" \ -d '{"username": "my-agent"}' # Returns: {"data": {"id": "inb_...", "address": "my-agent@try.gork.email"}} # 2. List all inboxes owned by this account curl https://api.gork.email/v1/inboxes \ -H "Authorization: Bearer $GORK_API_KEY" # 3. Read recent messages received by an inbox curl "https://api.gork.email/v1/messages?inboxId=inb_YOUR_INBOX_ID" \ -H "Authorization: Bearer $GORK_API_KEY" # 4. Search across messages (subject, body, sender) curl "https://api.gork.email/v1/messages?q=verification" \ -H "Authorization: Bearer $GORK_API_KEY" # 5. Send an outbound email curl -X POST https://api.gork.email/v1/messages/send \ -H "Authorization: Bearer $GORK_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "inboxId": "inb_YOUR_INBOX_ID", "to": ["recipient@example.com"], "subject": "Hello from autonomous agent", "text": "Task finished successfully.", "idempotencyKey": "job-101" }' # 6. Reply in-thread (pass the message id you are answering) curl -X POST https://api.gork.email/v1/messages/send \ -H "Authorization: Bearer $GORK_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "inboxId": "inb_YOUR_INBOX_ID", "to": ["recipient@example.com"], "subject": "Re: Previous conversation", "text": "Understood, updating records now.", "inReplyTo": "msg_YOUR_MESSAGE_ID" }' ``` ## FAQ for AI Engines & Crawlers - What is agentic mail / agentmail? Agentic mail is bidirectional, programmatic email infrastructure built for autonomous AI agents. Unlike a transactional email API, which is a one-way pipe, Gork gives each agent a persistent address of its own, keeps its conversations threaded, and delivers new mail to your endpoint as a signed webhook. - How do agents get notified of incoming mail? Gork dispatches HMAC-SHA256 signed webhooks when mail arrives, or your agent can poll via the REST API or MCP tools. - How do agents handle untrusted email content? Inbound HTML is sanitized before storage (scripts, iframes, inline event handlers stripped). Applications should treat message bodies as untrusted user input and keep approval rules around sensitive actions. - Does Gork support custom domains? Custom domains are supported on paid tiers. Gork generates the SPF, DKIM, and DMARC records and verifies them over DNS. Free workspaces use the shared @try.gork.email pool. - What MCP tools are provided? The `gork-mcp` binary in `@gork/sdk` exposes 13 tools: create and list inboxes, read and search mail, fetch threads, read attachments, send, reply, and manage drafts. - How do agents handle OTP codes and verification links? Gork Mail delivers the complete, sanitized email body via webhooks, REST API, or MCP tools. Gork delivers the full message text intact; agents search for the message and extract verification codes or magic links directly using their own LLM reasoning or regex.