Gmail

Read, send, and manage Gmail messages from any myai canvas, function, or chat — across Google Workspace domains.

Productivity & OfficeAvailable now

Gmail is the inbox most Google Workspace teams default to, and the one most likely to hold the customer context everyone needs but nobody can find. The integration lets myai read and send mail through the Gmail API — threads, attachments, labels, and Gmail's powerful query syntax all become structured inputs to canvases and automations.

What you can do

  • Find threads from a conversation — "what did the customer say about pricing last week" returns matching messages without leaving the chat.
  • Send mail from automations — a function composes the reply, pulls attachments from Drive, and sends it on a schedule or trigger.
  • Pull attachments into a pipeline — a function watches a label, extracts PDFs from inbound mail, feeds them downstream (parse, route, summarize).
  • Read label-scoped sets — every "Customer Escalation" thread, every "Renewal Q4" message, queryable as a structured set.
  • Trigger on inbound — a new message from a key sender kicks off downstream automation (CRM update, task creation, alert).
  • Draft management — for the workflows that prepare a send but need human review before it goes out.

How to connect

Google Workspace service account with domain-wide delegation (DWD). Your admin grants the service account the required Gmail API scopes, and the integration impersonates Workspace users within the domain. Per-user OAuth is also supported for personal Gmail.

Setup (admin, one-time):

  1. Enable the Gmail API in your GCP project.
  2. Create a service account and generate a JSON key — paste it into the integration form.
  3. Enable DWD on the service account and note the Client ID.
  4. In Workspace Admin Console → Security → API controls → Domain-wide Delegation, add the Client ID and authorize the scopes the use case needs:
    • gmail.readonly — list, search, read
    • gmail.send — minimum for sending
    • gmail.modify — labeling, archiving, marking read
  5. Impersonation target must be a real Workspace user, not a group alias.
Connect Gmail in myai

Common use cases

  • Customer-thread digest — pull every email from a domain over the last 30 days, summarize, post to a canvas before the QBR.
  • Attachment processing pipeline — a function watches a label, extracts PDF data from new messages, writes results to a database.
  • Sales-context primer — when a deal updates in HubSpot or Salesforce, a function pulls all related Gmail threads and posts a primer to the AE.

Reference

  • Connection model: Google Workspace service account with DWD (or OAuth 2.0 for personal Gmail)
  • Scopes: gmail.readonly, gmail.send, gmail.modify (request only what's needed)
  • Personal @gmail.com accounts cannot use DWD — only Workspace users