Private beta · Gmail and Google Workspace

Your AI agents don’t need your whole inbox.

comail sits between Gmail and your AI agents. Each agent only sees the threads carrying its label, and nothing else in your inbox. Use rules to label incoming mail automatically, keep replies in Drafts until you hit send, and take any thread back right from Gmail.

Takes a minute to apply. No credit card required.

Label a receipt co:bookkeeping-agent in Gmail and only that agent can read it. It gets notified, reads the invoice, and books the expense.

Full inbox access is the wrong default.

Google’s OAuth scopes are all-or-nothing. Once you grant an agent read access to Gmail, it can search and read everything in your archive: board updates, legal threads, payroll, personal mail, and password resets.

01

Context leaks across tasks

If an agent can search your whole inbox, private threads end up in its context window while it drafts replies to vendors or customers. Scoping each agent to its own label keeps sensitive threads out of unrelated conversations.

02

Every email is untrusted input

Anyone with your address can send a prompt injection into your inbox. When an agent only sees threads you’ve labeled and can’t send mail on its own, an untrusted email has nowhere to go.

03

Take a thread back in one tap

With standard OAuth, revoking access means disconnecting the whole account. With comail, if a thread turns sensitive, just remove the agent’s label in Gmail. Access is gone on its very next request.

How it works

Scope an agent in three steps.

  1. 1

    Connect your mailboxes

    Sign in with Google once from the comail dashboard. comail holds the OAuth grant, so your agents never receive Google credentials or talk to the Gmail API directly. Nothing needs to be installed in Gmail. You can connect work, personal, and shared mailboxes to one account, and disconnect any of them individually.

  2. 2

    Create an agent and label its threads

    Each agent gets a co:agent-name label in Gmail to share threads, plus an optional no:agent-name label to block them. Most agents start with no access and only see threads labeled co:agent-name. You can apply labels manually in Gmail, use standard Gmail filters, or set up comail rules that label mail automatically by address, domain, or existing label.

  3. 3

    Connect your MCP client

    Every agent gets a dedicated MCP URL that works across all the inboxes you’ve assigned to it. Add the URL to your client and sign in through your browser to authorize it. On every request, comail checks the agent’s permissions and labels for that mailbox before calling Gmail.

    mcp.json
    {
      "mcpServers": {
        "inbox-investors": {
          "url": "https://mcp.comail.io/a/7f3a91c2/investor-relations"
        }
      }
    }

    Works with Claude, ChatGPT, Cursor, Codex, OpenClaw, or any custom MCP client. For headless agents without a browser, create a named token for it on the agent’s card and pass it in an Authorization: Bearer header instead.

Live notifications

Wake your agent when new mail arrives.

No Google Cloud Pub/Sub, no public webhook server, and no polling loops. Any agent that can make outbound HTTP requests can listen for new or newly labeled threads, even when running locally on your laptop.

  1. Ask for a notification URL

    The agent calls create_notification_url over its MCP connection for the mailbox it wants to watch.

  2. Listen over SSE or long polling

    It opens that URL with a standard HTTP request. Because the connection is outbound, your agent doesn’t need a public IP or webhook endpoint.

  3. Fetch the message and act on it

    Events carry only opaque mailbox and message IDs, never email bodies. The agent calls get_message through comail, which checks its current label and permissions as usual.

Watch a support or billing inbox

Have an agent follow incoming customer or vendor threads and draft replies in Gmail, with send disabled so nothing goes out until you review and send it.

Hand off a thread in Gmail

Notifications fire not just on new arrivals, but whenever you add an agent’s co: label to an existing thread. Label an email in Gmail and your agent picks it up right away.

Trigger workflows from incoming mail

Book an arriving invoice, prepare a candidate reply, or flag an urgent customer request for your team as soon as it lands.

For developers: streaming, URL renewal, and replay

Call create_notification_url over the agent’s MCP connection for the target mailbox, assign the returned URL to NOTIFICATION_URL, and connect with either SSE or long polling:

Streaming · server-sent events (SSE)
curl -N -H 'Accept: text/event-stream' "$NOTIFICATION_URL"
Long polling · JSON
curl "$NOTIFICATION_URL"

Scoped, one-hour URLs. Each URL is bound to one agent and one mailbox and expires after an hour. To stay connected, the agent requests a fresh URL over MCP before it expires.

Cursor-based replay. If a connection drops, the agent can reconnect with its last cursor to catch up on up to 24 hours of history. Delivery is at-least-once, so clients should deduplicate by message ID.

No email content in events. Payloads contain only opaque mailbox and message IDs, and only fire for threads the agent’s labels currently allow. The agent still calls get_message to read the message.

Near-realtime delivery. Events arrive shortly after Gmail processes the message or label change, though exact delivery latency is not guaranteed.

Features

What an agent can see, and what it can do.

Gmail labels decide which threads each agent can read. Per-agent permissions decide what it can do with them, in every inbox you connect.

Labels

Share a thread by labeling it in Gmail

Add an agent’s co: label to share a thread, or its no: label to block one. Run each agent as an allow-list or a deny-list, and audit what it can read with a Gmail search.

allow-listdeny-list

Permissions

Drafts only, until you say otherwise

Turn attachments, archiving, spam, trash, and sublabels on or off per agent. Sending starts as drafts only; widen it to people you name, or let a reviewer agent send the drafts it approves.

drafts onlyreview

Several inboxes

One agent across all your inboxes

One MCP URL reaches every inbox you assign to an agent, each with its own labels and default policy. Pause the agent in one inbox and it keeps working in the others.

multi-inboxpause per inbox

See all features, including which controls live in Gmail and which in the dashboard.

Use cases

Give each agent only the threads it needs.

Instead of handing one general-purpose bot your entire Gmail archive, give each workflow its own label, permissions, and MCP endpoint.

Client follow-through

Follow up on quiet threads with a single Gmail label

Tag a proposal or client thread when you send it. If they haven’t replied after a few days, your agent drops a context-aware follow-up into Gmail Drafts—without forwarding or splitting the thread.

co:follow-updrafts only

Finance

File every expense without sharing your inbox

Label an invoice in Gmail and your bookkeeping agent pulls the PDF and logs the expense. A separate admin agent adds a rule for the vendor so future invoices are labeled automatically.

co:bookkeeping-agentmanagement MCP

Personal privacy

Keep your personal life out of your job’s LLMs

Wall off medical, payroll, and private threads in your work inbox, and share single flight confirmations or receipts from your personal Gmail without exposing the rest of your archive.

multi-inboxno:work-assistant

Explore all use cases, including how six specialized agents can share a single founder’s inbox.

FAQ

Common questions.

Do agents get my Google credentials?

No. comail holds your Google OAuth grant. Each app you connect to an agent signs in to comail on its own, with OAuth or with a named token you create for it, and comail calls the Gmail API on the agent’s behalf only after checking that agent’s permissions. You can disconnect one app without affecting any other app or agent.

Does comail change my labels?

comail only manages its own co: and no: labels. It can read your existing labels so rules can match them, but it never creates, edits, or deletes your own labels. If you enable an agent’s labels permission, it can create sublabels under co:agent-name/ and apply them to threads it can view, without ever touching your own labels.

Won’t my label list turn into a mess?

No. Gmail lets you hide labels from both the sidebar and the inbox list. comail sets its labels to hidden when it creates them, so ten agents won’t clutter your UI. You can toggle any label visible whenever you want to inspect it, or search label:"co:agent-name" anytime.

Which mailboxes are supported?

Personal Gmail and Google Workspace accounts. We built comail specifically around Gmail’s native label system so you can audit and control agent access directly from the inbox you already use.

Can one agent work across several of my inboxes?

Yes. You can attach multiple connected mailboxes to a single agent, using one MCP URL, and every app connected to that agent reaches all of them. Each mailbox has its own co: and no: labels and its own default policy, and the agent specifies which mailbox it’s querying on each tool call. You can pause an agent in one mailbox while leaving the others active. Each inbox supports up to 10 agents, and an agent connected to multiple inboxes counts toward each inbox’s limit.

Which agents can connect?

Any client that supports MCP over HTTP, including Claude Desktop, Claude Code, ChatGPT, Cursor, Codex, OpenClaw, and custom scripts. Each agent gets a standard MCP server URL, so there is no custom SDK to install.

Can my agent listen for new mail?

Yes. An agent can call create_notification_url over MCP and listen for new or newly labeled threads using standard HTTP streaming (SSE) or long polling. You don’t need to set up a webhook server, a public URL, or Google Cloud Pub/Sub. See how notifications work.

Does a notification let the agent read more mail?

No. Agents only receive events for threads their labels currently allow, and the notification payload contains only opaque mailbox and message IDs. To read the email itself, the agent still has to call get_message, which re-checks its permissions.

Can an agent set comail up for me?

Yes, via the management MCP endpoint. Connect an agent to the setup URL, sign in, and ask it in plain English to create agents, assign inboxes, and configure routing rules. Management access is off by default and can be enabled for a 60-minute window (so an agent can’t later widen its own permissions) or left on until you disable or pause it. A management agent can never send email, and you choose what mailbox data it can inspect during setup — from labels and addresses to subjects, message bodies, or attachments.

Can an agent send mail as me?

Only if you allow it. Each agent can be set to drafts only (the default — it writes drafts in Gmail and you hit send), allowed to send only to specific people, or allowed to send to anyone. You can also have one agent review another’s drafts: the reviewer either sends the draft unchanged or returns it with feedback, and any draft it isn’t permitted to send stays in Gmail Drafts for you.

What happens when I revoke an agent?

Revoking an agent immediately invalidates its credentials and cancels any sends it has scheduled. If you just want a temporary hold, you can deactivate the agent altogether or pause it on a single inbox; its credentials, labels, and rules stay intact for when you’re ready to resume.

Request access

We’re onboarding beta users in small batches. Tell us what you want your agent to handle; specific use cases go to the front of the line.

Clients / harnesses (optional)

Select all that apply.

We’ll only email you about the beta. No card, no newsletter.