The Real Cost of the Gmail API for Agents (CASA)
**Using the Gmail API to let an agent read or receive a person's mail is expensive in time and money, because those actions use Google's *restricted* OAuth scopes - which require brand verification, a documented justification, a demo video, and a third-party security assessment (CASA) that must be re-passed every 12 months. Public reports put the recurring audit somewhere in the low-to-mid five figures per year, though the exact figure varies by vendor and tier and should be confirmed for your case.** The headline cost is not a license fee - it's the annual compliance treadmill attached to reading mail.
Last updated June 30, 2026
This piece separates what is firmly documented from what is reported-but-variable, so you can size the decision honestly.
Sensitive vs. restricted: the distinction that drives the bill
Not all Gmail scopes are equal, and conflating them is the most common mistake.
- Sending uses
gmail.send, which Google classifies as a sensitive scope. Sensitive scopes need app verification but no third-party security audit. Sending alone is comparatively cheap. - Reading or receiving a person's mail uses restricted scopes - including
https://mail.google.com/, which also covers IMAP, SMTP, and POP. Restricted scopes are what trigger the CASA security assessment (Google Cloud, restricted scopes & verification, updated 2026-06-09; scope levels).
For an agent, the whole value is usually in *receiving* - reading the verification code, catching the reply, triaging the inbound message. That means almost every useful agent use of Gmail lands squarely in the restricted-scope, audited tier.
What the CASA assessment actually is
CASA stands for the Cloud Application Security Assessment, run against the OWASP Application Security Verification Standard (ASVS). To ship an app using restricted Gmail scopes, Google requires you to:
- Verify your brand and OAuth consent screen.
- Justify each restricted scope and show why a narrower one won't do.
- Provide a demo video of the OAuth flow and data use.
- Pass a CASA assessment by an authorized third-party lab, producing a Letter of Validation.
- Re-do the validation every 12 months to keep access (Google Cloud, OAuth verification FAQ, updated 2026-06-09).
The recurring annual step is the part that hurts. It isn't a one-time launch gate; it's a standing obligation for as long as your agent reads mail.
What it costs - verified vs. reported
Here is where to be careful, because cost figures circulate that deserve qualification.
- Firmly documented (by Google): restricted scopes require the CASA assessment and annual re-verification. That is the load-bearing fact, and it is free of dispute.
- Reported / estimated (treat as directional): industry write-ups commonly cite an annual CASA cost in roughly the $15,000-$75,000 per year range depending on tier (self-scan vs. full assisted assessment) and provider. We have seen this range widely repeated, but it is *aggregator- and vendor-sourced, not an official Google price list* - so confirm a current quote before you put it in a budget.
- Always true regardless of price: the *time* cost - weeks of verification work, plus engineering to manage tokens, "Testing" mode's 100-user cap and 7-day refresh-token expiry, and the eventual move to a paid Workspace with domain-wide delegation for any real multi-user setup.
So the honest framing is: the *existence* of an annual audit is certain; the *dollar amount* is variable and should be quoted, not quoted-from-a-blog.
The hidden costs beyond the audit
Even after you pass CASA, the Gmail path keeps charging you:
- Token and consent management - refresh tokens expire, consent can be revoked, and "Testing" mode forces a 7-day refresh cycle until you're fully verified.
- The paid-Workspace tax for scale - service accounts with domain-wide delegation, the only clean way to run many inboxes, require a paid Workspace and a super-admin; free
@gmail.comaccounts can't do it. - Ongoing scope risk - Google periodically tightens scope policy, and a policy change can put your app back in the verification queue.
The alternative: skip the audited path entirely
The reason this matters for agent builders is that none of it buys you anything an agent actually wants. You are paying - in audits, tokens, and Workspace seats - to borrow a *human's* inbox. An agent doesn't need a human's inbox; it needs its own.
A provider built for programmatic use gives the agent a dedicated mailbox reached with a scoped API key - no OAuth consent screen, no restricted-scope justification, no annual CASA validation. The compliance treadmill simply isn't part of the model, because software owning a mailbox is the *intended* use, not an exception to be audited.
How Sairaph Mail compares
With Sairaph Mail there is no CASA assessment, no yearly re-verification, and no paid-Workspace requirement to run more than one inbox. You provision a mailbox, get a scoped, dashboard-issued key, and the agent sends and reads over REST (/api/v1) or a native MCP server (/mcp/v1/mcp) - EU-resident by default on every plan. The cost is a transparent plan price, not an annual audit. See the 2026 guide to email for AI agents for the full picture, or why you can't cleanly open a Google account for an agent for the upstream problem.
Related
You Can't Cleanly Open a Google Account for Your AI Agent - What to Do Instead
From the blog.
Learn more
Give your agent a real mailbox
Two-way email over REST and a native MCP server, EU-resident by default.
EU data residencyPer-customer encryptionNative MCP