Skip to content

Connectors · Email & messaging

Gmail MCP server for AI agents.

actionlake is an MCP gateway: one remote MCP server that connects Claude and other MCP clients to Gmail and the rest of your systems. It gives your agent 79 Gmail actions (30 reads, 33 writes and 16 that wait for a confirmation) and holds the Gmail credential itself, so the agent never does. It paces Gmail's limits and records every call. Connecting Gmail needs your own Gmail OAuth app and one admin sign-in.

100,000 free calls a month. No card, no email, no password: press Start a free sandbox on the next screen and keep the key it shows you.

claude mcp add --transport http actionlake https://connect.actionlake.com/mcp
the first call
do {  action: "gws_gmail.messages.list",  intent: "check which Gmail account is connected"}# List Gmail messages · read · 1 upstream call
  • 79actionsin one signed file
  • 30readlook, never change
  • 33writecreate and update
  • 16wait for a yesdestructive, confirmed first

Set up

Connect Gmail in three steps.

  1. 01

    Add actionlake to Claude.

    Run the command once in Claude Code; its consent page can create a free sandbox: 100,000 calls a month, no card. In the Claude app, add a custom connector with the URL below and paste your key on the consent page. Creating a new sandbox from the Claude app is not yet tested by us.

    https://connect.actionlake.com/mcp
  2. 02

    Connect Gmail.

    OAuth 2.0, authorization code with PKCE. You register your own OAuth app with Gmail, an admin signs in once, and you paste the app's client id and secret and the tokens from that sign-in; actionlake renews the access token from then on. actionlake stores what you paste write-only, sealed under your tenant's key.

    Before the first sign-in, Gmail needs an OAuth app of your own, registered in its developer portal. actionlake has no Gmail app to lend you.

    • access_tokenAccess token from one sign-in with your own OAuth app
    • refresh_tokenRefresh token from the same sign-in; the access token is renewed from it
    • client_idGoogle OAuth client id
    • client_secretGoogle OAuth client secret
    account { op: "connections.requirements", service: "gws_gmail" }
    # free: exactly what to paste, and what is found for you
  3. 03

    Make the first call. Check before a write.

    Ask in plain words; Claude picks the action. Before anything changes, check validates the call and prices it, for free.

    do    { action: "gws_gmail.messages.list" }# list gmail messages · read · 1 upstream callcheck { action: "gws_gmail.messages.send", input: { … } }# free: inputs, permissions, cost and confirmations, nothing sent

Gmail at a glance

Sign-in
OAuth 2.0, authorization code with PKCE. You register your own OAuth app with Gmail, an admin signs in once, and you paste the app's client id and secret and the tokens from that sign-in; actionlake renews the access token from then on.
You provide
access_tokenrefresh_tokenclient_idclient_secret
Limits we pace to
6,000 calls a minute, per connection
API covered
Gmail API 1gmail.googleapis.com/gmail/v1
Built from
Gmail's documentation, read 8 September 2026developers.google.com
Service file
Version 1.0.0, signed (Ed25519)
Cached reads
28 of 30 reads, for up to an hour; a write clears what it affects
Ready-made plans
6 in the store
Shared entities
4, so ask can line Gmail up with your other systems
Data
Processed and stored in Sydney, Australia. No US region yet

Capabilities

What an AI agent can do in Gmail.

79 actions in 1 area. Every one carries its effect, so a key can allow the reads and hold the rest.

  • 30readlook, never change
  • 33writecreate and update
  • 16destructivewait for a confirmation
  1. Email

    79

    30 read · 33 write · 16 destructive

    Get one Gmail message · Get a Gmail profile · Send a Gmail message · List Gmail messages

Top actions

The Gmail API, shaped for agents.

The ids your agent types, what each does, and the one name it shares with other systems. 54 of Gmail's 59 action names are shared with at least one other connector, so an agent learns them once.

ActionWhat it doesEffectSame name in
gws_gmail.messages.getGet one Gmail messageFetch a single message with its headers and body.readcomm.email.get26 connectors
gws_gmail.users.get_profileGet a Gmail profileFetch the mailbox's email address, message and thread totals, and current history id.readcomm.mailbox.get13 connectors
gws_gmail.messages.sendSend a Gmail messageSend an email composed as a base64url-encoded RFC 2822 message.writecomm.email.send32 connectors
gws_gmail.threads.getGet one Gmail threadFetch a whole conversation with every message in it.readcomm.email_thread.get7 connectors
gws_gmail.threads.listList Gmail threadsList conversation thread ids matching a Gmail search query.readcomm.email_thread.list7 connectors
gws_gmail.message_attachments.getGet a Gmail message attachmentDownload one attachment's bytes by its attachment id.readcomm.email_attachment.get5 connectors
gws_gmail.messages.deletePermanently delete a Gmail messagePermanently and irreversibly delete one message.destructivecomm.email.delete15 connectors
gws_gmail.drafts.createCreate a Gmail draftSave a new unsent draft from a base64url RFC 2822 message.writecomm.email_draft.create5 connectors
gws_gmail.labels.listList Gmail labelsList every label in a mailbox, system and user-created.readcomm.email_folder.list4 connectors
gws_gmail.labels.createCreate a Gmail labelCreate a new user label, optionally nested and coloured.writecomm.email_folder.create4 connectors
gws_gmail.drafts.sendSend a Gmail draftSend an existing draft and remove it from the drafts list.writecomm.email_draft.send3 connectors
gws_gmail.filters.createCreate a Gmail filterCreate a server-side rule that labels, archives or forwards matching mail.writecomm.mailbox_rule.create5 connectors

Try it

Prompts to paste into Claude.

Each one names the Gmail actions it will call, so you know what it reads and what it changes before you send it.

  1. Readread

    List Gmail messages and tell me what stands out.

    callsgws_gmail.messages.list

  2. Plandestructive

    Revoke a delegate and the forwarding that follows them in Gmail. Ask me before anything is sent or changed.

    callsgws_gmail.delegates.getgws_gmail.settings.get_auto_forwardinggws_gmail.settings.update_auto_forwardinggws_gmail.forwarding_addresses.deletegws_gmail.delegates.delete+1 more

  3. Planwrite

    Draft a reply, hold it for review, then send in Gmail. Ask me before anything is sent or changed.

    callsgws_gmail.threads.getgws_gmail.drafts.creategws_gmail.drafts.getgws_gmail.drafts.sendgws_gmail.threads.modify

  4. Writewrite

    Send a Gmail message in Gmail. Show me exactly what you will send before you save it.

    callsgws_gmail.messages.send

The plan store

Ready-made plans for Gmail.

6 plans in the store. Install one and your agent runs it by name; the reply says which connections are still missing. A schedule can run a plan on a timetable. There are no triggers or webhooks, by design.

  1. File a sender's mail under a new label from now on

    Use it when An agent should make all mail from one sender file itself under a label, past and future.

    Effect
    write
    Steps
    5
    Needs
    label name and sender
    Install
    gws_gmail-filter-sender-to-new-label
  2. Triage unread inbox mail onto a label

    Use it when An agent needs to sort a run of incoming mail onto a triage label without deleting anything.

    Effect
    write
    Steps
    5 · loops
    Needs
    label id, mark read and query
    Install
    gws_gmail-triage-inbox-to-label
  3. Turn on a vacation auto-reply for a date window

    Use it when Someone is going away and wants an out-of-office reply switched on for a fixed window.

    A person decidesAuto-reply from emailAddress to every sender between start time and end time with subject 'subject'.

    Effect
    write
    Steps
    5
    Needs
    body, end time, start time and subject
    Install
    gws_gmail-vacation-autoreply-window
  4. Draft a reply, hold it for review, then send

    Use it when A reply needs writing to an existing thread but a human must read it before it goes out.

    A person decidesSend the drafted reply on thread 'snippet' to its recipients.

    Effect
    write
    Steps
    6
    Needs
    done label id, raw and thread id
    Install
    gws_gmail-draft-review-and-send
  5. Purge old mail after human approval

    Use it when Someone wants to permanently clear out a large body of old mail and a human must sign off first.

    A person decidesPermanently delete number of items messages older than cutoff matching 'query'. This cannot be undone.

    Effect
    destructive
    Steps
    5 · loops
    Needs
    query
    Install
    gws_gmail-purge-old-mail-with-approval
  6. Revoke a delegate and the forwarding that follows them

    Use it when Someone leaves and their delegated access and mail forwarding must both be removed.

    A person decidesRevoke delegate delegate email and remove the forwarding address pointing at them. They lose all access to this mailbox.

    Effect
    destructive
    Steps
    7
    Needs
    delegate email
    Install
    gws_gmail-revoke-delegate-and-forwarding
install a plan
account { op: "plans.install", slug: "gws_gmail-filter-sender-to-new-label" }
# then ask for it by name; a schedule can run it on a timetable

Governance for Gmail

Destructive actions wait for a yes.

16 Gmail actions are destructive. These are all of them:

  • Permanently delete a Gmail messagegws_gmail.messages.delete
  • Permanently delete many Gmail messagesgws_gmail.messages.batch_delete
  • Permanently delete a Gmail threadgws_gmail.threads.delete
  • Update Gmail automatic forwarding settingsgws_gmail.settings.update_auto_forwarding
  • Delete a Gmail labelgws_gmail.labels.delete
  • Create a Gmail forwarding addressgws_gmail.forwarding_addresses.create
  • Delete a Gmail filtergws_gmail.filters.delete
  • Stop watching a Gmail mailboxgws_gmail.users.stop
  • Delete a Gmail draftgws_gmail.drafts.delete
  • Delete a Gmail send-as aliasgws_gmail.send_as.delete
  • Delete a Gmail forwarding addressgws_gmail.forwarding_addresses.delete
  • Delete an S/MIME certificategws_gmail.smime_info.delete
  • Remove a Gmail mailbox delegategws_gmail.delegates.delete
  • Disable a client-side encryption key pairgws_gmail.cse_keypairs.disable
  • Delete a client-side encryption identitygws_gmail.cse_identities.delete
  • Obliterate a client-side encryption key pairgws_gmail.cse_keypairs.obliterate

A destructive action runs only with confirm: true. Under the human policy the agent cannot confirm for itself: the run stops until a named person approves, in the console or from a signed link in an email. The cap on a key is refused before the call is sent, never after.

dogws_gmail.messages.deleteconfirm_policy: human

Permanently delete a Gmail message?

intent: the user asked me to permanently delete a Gmail message

run suspended · waiting for a named person · key gws-gmail-agent cannot confirm itself
In the console, or from an emailed signed link.
a key for this connector
account {  op: "keys.create", name: "gws-gmail-agent",  allowed_actions: ["gws_gmail.*"], cap_calls: 2000,  confirm_policy: "human_for_writes",  approval_rules: [    { match: "gws_gmail.messages.delete", approver: "[email protected]" },    { match: "gws_gmail.messages.batch_delete", approver: "[email protected]" },    { match: "gws_gmail.threads.delete", approver: "[email protected]" }  ]}
Illustrative. Scoped to Gmail only, capped at 2,000 upstream calls, every write confirmed, and the destructive ones approved by a named person.

Cost

What Gmail costs on actionlake.

Every Gmail action is one upstream call, the only thing actionlake bills. Searching, check, cost, account and any call Gmail refused with 401, 403, 429 or a 5xx are free. Paid plans start at US$49 a month for 250,000 calls, with overage from US$0.30 down to US$0.18 per 1,000.

  • 1upstream call per actionall 79 Gmail actions
  • 12actions pageeach page of a long list is one call
  • 28reads can be cacheda cache hit costs nothing
  • 100,000calls a month, freepaid plans from US$49 a month for 250,000

See pricing

Action index

Every Gmail action.

79 actions by area: the id your agent calls, what it does, and its effect.

Email79
  • gws_gmail.cse_identities.createCreate a client-side encryption identitywrite
  • gws_gmail.cse_identities.deleteDelete a client-side encryption identitydestructive
  • gws_gmail.cse_identities.getGet one client-side encryption identityread
  • gws_gmail.cse_identities.listList client-side encryption identitiesread
  • gws_gmail.cse_identities.patchPatch a client-side encryption identitywrite
  • gws_gmail.cse_keypairs.createCreate a client-side encryption key pairwrite
  • gws_gmail.cse_keypairs.disableDisable a client-side encryption key pairdestructive
  • gws_gmail.cse_keypairs.enableEnable a client-side encryption key pairwrite
  • gws_gmail.cse_keypairs.getGet one client-side encryption key pairread
  • gws_gmail.cse_keypairs.listList client-side encryption key pairsread
  • gws_gmail.cse_keypairs.obliterateObliterate a client-side encryption key pairdestructive
  • gws_gmail.delegates.createAdd a Gmail mailbox delegatewrite
  • gws_gmail.delegates.deleteRemove a Gmail mailbox delegatedestructive
  • gws_gmail.delegates.getGet one Gmail mailbox delegateread
  • gws_gmail.delegates.listList Gmail mailbox delegatesread
  • gws_gmail.drafts.createCreate a Gmail draftwrite
  • gws_gmail.drafts.deleteDelete a Gmail draftdestructive
  • gws_gmail.drafts.getGet one Gmail draftread
  • gws_gmail.drafts.listList Gmail draftsread
  • gws_gmail.drafts.sendSend a Gmail draftwrite
  • gws_gmail.drafts.updateUpdate a Gmail draftwrite
  • gws_gmail.filters.createCreate a Gmail filterwrite
  • gws_gmail.filters.deleteDelete a Gmail filterdestructive
  • gws_gmail.filters.getGet one Gmail filterread
  • gws_gmail.filters.listList Gmail filtersread
  • gws_gmail.forwarding_addresses.createCreate a Gmail forwarding addressdestructive
  • gws_gmail.forwarding_addresses.deleteDelete a Gmail forwarding addressdestructive
  • gws_gmail.forwarding_addresses.getGet one Gmail forwarding addressread
  • gws_gmail.forwarding_addresses.listList Gmail forwarding addressesread
  • gws_gmail.history.listList Gmail mailbox historyread
  • gws_gmail.labels.createCreate a Gmail labelwrite
  • gws_gmail.labels.deleteDelete a Gmail labeldestructive
  • gws_gmail.labels.getGet one Gmail labelread
  • gws_gmail.labels.listList Gmail labelsread
  • gws_gmail.labels.patchPatch a Gmail labelwrite
  • gws_gmail.labels.updateReplace a Gmail labelwrite
  • gws_gmail.message_attachments.getGet a Gmail message attachmentread
  • gws_gmail.messages.batch_deletePermanently delete many Gmail messagesdestructive
  • gws_gmail.messages.batch_modifyModify labels on many Gmail messageswrite
  • gws_gmail.messages.deletePermanently delete a Gmail messagedestructive
  • gws_gmail.messages.getGet one Gmail messageread
  • gws_gmail.messages.importImport a Gmail messagewrite
  • gws_gmail.messages.insertInsert a Gmail messagewrite
  • gws_gmail.messages.listList Gmail messagesread
  • gws_gmail.messages.modifyModify a Gmail message's labelswrite
  • gws_gmail.messages.sendSend a Gmail messagewrite
  • gws_gmail.messages.trashTrash a Gmail messagewrite
  • gws_gmail.messages.untrashUntrash a Gmail messagewrite
  • gws_gmail.send_as.createCreate a Gmail send-as aliaswrite
  • gws_gmail.send_as.deleteDelete a Gmail send-as aliasdestructive
  • gws_gmail.send_as.getGet one Gmail send-as aliasread
  • gws_gmail.send_as.listList Gmail send-as aliasesread
  • gws_gmail.send_as.patchPatch a Gmail send-as aliaswrite
  • gws_gmail.send_as.updateReplace a Gmail send-as aliaswrite
  • gws_gmail.send_as.verifySend a Gmail send-as verification emailwrite
  • gws_gmail.settings.get_auto_forwardingGet Gmail automatic forwarding settingsread
  • gws_gmail.settings.get_imapGet Gmail IMAP settingsread
  • gws_gmail.settings.get_languageGet Gmail language settingsread
  • gws_gmail.settings.get_popGet Gmail POP settingsread
  • gws_gmail.settings.get_vacationGet Gmail vacation responder settingsread
  • gws_gmail.settings.update_auto_forwardingUpdate Gmail automatic forwarding settingsdestructive
  • gws_gmail.settings.update_imapUpdate Gmail IMAP settingswrite
  • gws_gmail.settings.update_languageUpdate Gmail language settingswrite
  • gws_gmail.settings.update_popUpdate Gmail POP settingswrite
  • gws_gmail.settings.update_vacationUpdate Gmail vacation responder settingswrite
  • gws_gmail.smime_info.deleteDelete an S/MIME certificatedestructive
  • gws_gmail.smime_info.getGet one S/MIME certificateread
  • gws_gmail.smime_info.insertUpload an S/MIME certificatewrite
  • gws_gmail.smime_info.listList S/MIME certificates for a send-as aliasread
  • gws_gmail.smime_info.set_defaultSet the default S/MIME certificatewrite
  • gws_gmail.threads.deletePermanently delete a Gmail threaddestructive
  • gws_gmail.threads.getGet one Gmail threadread
  • gws_gmail.threads.listList Gmail threadsread
  • gws_gmail.threads.modifyModify a Gmail thread's labelswrite
  • gws_gmail.threads.trashTrash a Gmail threadwrite
  • gws_gmail.threads.untrashUntrash a Gmail threadwrite
  • gws_gmail.users.get_profileGet a Gmail profileread
  • gws_gmail.users.stopStop watching a Gmail mailboxdestructive
  • gws_gmail.users.watchWatch a Gmail mailboxwrite

Questions

The Gmail MCP server, answered.

Is there a Gmail MCP server for Claude?

Yes. actionlake is an MCP gateway: a remote MCP server that gives Claude, or another MCP client, 79 Gmail actions, through the same eight tools it uses for every other connector. actionlake is independent; it is not made or endorsed by Gmail.

What do I need to connect Gmail?

Your own Gmail OAuth app, registered with Gmail (its client id and client secret), and the access and refresh tokens from one admin sign-in. actionlake has no Gmail app of its own, so this is not a one-step consent. actionlake renews the access token as it expires. The free call account { op: "connections.requirements", service: "gws_gmail" } lists exactly what to paste.

Can an AI agent delete or change things in Gmail?

Only if its key allows it, and only with an explicit confirmation. 16 Gmail actions are destructive, including permanently delete a Gmail message, permanently delete many Gmail messages and permanently delete a Gmail thread. Each runs only with confirm: true. Under the human confirm policy, or an approval rule on the key, the run waits until a named person approves it.

Will an AI agent use up my Gmail API limit?

actionlake paces every call to the limits in the Gmail service file: 6,000 calls a minute per connection. Repeated reads are answered from cache (28 Gmail actions can be), which never reaches Gmail.

What does a Gmail action cost?

One upstream call, the only unit actionlake bills. A list that pages bills one call per page (12 Gmail actions page). Cache hits, searches, dry runs and calls Gmail refused with 401, 403, 429 or a 5xx are free. The Free plan includes 100,000 calls a month with no card. Paid plans start at US$49 a month for 250,000 calls, with overage from US$0.30 down to US$0.18 per 1,000.

Which Gmail API does it cover?

The Gmail API 1 at gmail.googleapis.com/gmail/v1. It is built from Gmail's documentation as read on 8 September 2026. 79 actions in 1 area, each one in the signed service file (version 1.0.0).

Does actionlake keep my Gmail data, and where?

actionlake processes and stores data in Sydney, Australia; there is no US region yet. Reads may be cached for up to an hour, and a write clears the reads it affects. Each run's request and response is kept, sealed, for your plan's trace window: 1 day on Free, 3 days on Starter, 7 days on Pro, 14 days on Team, 30 days on Business and 30 days on Enterprise. Your Gmail credential is sealed under your tenant's key, never logged and never returned. Your traffic is not used to train models.

Which AI clients can use it?

Claude Code, tested by us end to end, and the Claude app as a custom connector, tested by us with an existing key. Other MCP clients that support remote servers over Streamable HTTP (MCP revisions 2025-06-18 and 2025-11-25) and OAuth dynamic client registration, or a bearer header, should connect the same way; we have not tested them. Or plain REST, under the same action names.

Give your agent Gmail today.

Start free - 100,000 calls/month, no card. No signup. Hard caps on every key. Cached answers are free.