Gmail
Also an agent toolEmail management and real-time notifications via Google Pub/Sub
44 actions · 4 triggers
The Gmail integration lets you connect Gmail to your automations with 44 actions and 4 triggers — and every action is also a tool an AI agent can call. Examples: Get Profile, Watch Mailbox, Stop Watch, Create Draft, Delete Draft. No blank-canvas wiring — connect it and use it in your workflows.
Every action below is also a tool an AI agent can call — the same pack powers your workflows and your agents.
Triggers 4
Events in Gmail that can start a workflow.
Pub/Sub Push
Inbound Pub/Sub push notification
Mailbox Change
Persist the max observed historyId as the cursor; pass it as startHistoryId on the next poll. A 404 means the cursor is too old — full re-sync via list_messages and reset from getProfile.historyId.
New Gmail Message
Use the 'q' parameter with 'after:TIMESTAMP' for time-based filtering. nextPageToken enables cursor-based pagination.
New Gmail Thread
Use the 'q' parameter with 'after:TIMESTAMP' for time-based filtering. nextPageToken enables cursor-based pagination.
Actions 44
What Zervanor can do in Gmail.
Get Profile
Return the authenticated user's profile (Gmail API: users.getProfile). Returns emailAddress, messagesTotal, threadsTotal, historyId.
Watch Mailbox
Subscribe the mailbox to Pub/Sub push notifications (Gmail API: users.watch).
Stop Watch
Cancel any active Pub/Sub push subscription on the mailbox (Gmail API: users.stop).
Create Draft
Create a draft from a RFC 2822 / MIME body (Gmail API: users.drafts.create).
Delete Draft
Permanently delete a draft (Gmail API: users.drafts.delete).
Get Draft
Retrieve a draft with format projection (Gmail API: users.drafts.get).
List Drafts
List drafts (Gmail API: users.drafts.list). Supports q, maxResults, pageToken, includeSpamTrash.
Send Draft
Send an existing draft (Gmail API: users.drafts.send). Becomes a messages resource.
Update Draft
Replace a draft's content (Gmail API: users.drafts.update).
List History
List changes since startHistoryId (Gmail API: users.history.list). Primary reconciliation engine after a Pub/Sub push.
Create Label
Create a user label (Gmail API: users.labels.create).
Delete Label
Permanently delete a label (Gmail API: users.labels.delete).
Get Label
Retrieve label metadata and counts (Gmail API: users.labels.get).
List Labels
List all labels, system and user (Gmail API: users.labels.list).
Patch Label
Partial update of a label: name, visibility, color (Gmail API: users.labels.patch).
Update Label
Full replace of a label resource (Gmail API: users.labels.update).
Batch Delete Messages
Permanently delete up to 1,000 messages by id list (Gmail API: users.messages.batchDelete).
Batch Modify Messages
Add / remove labels on up to 1,000 messages atomically (Gmail API: users.messages.batchModify).
Delete Message
Permanently delete one message (Gmail API: users.messages.delete).
Get Message
Retrieve one message (Gmail API: users.messages.get). format=minimal|full|raw|metadata; metadataHeaders[] for the metadata projection.
List Messages
List messages (Gmail API: users.messages.list). Supports q, labelIds[], maxResults, pageToken, includeSpamTrash.
Modify Message
Add / remove labels on one message (Gmail API: users.messages.modify).
Send Message
Send a MIME message (Gmail API: users.messages.send). Body should match Gmail API (e.g., {raw: base64url}); supports threadId for in-thread replies.
Compose & Send Email
Send an email by providing human-readable fields (to, subject, body). The engine automatically constructs the RFC 5322 MIME message and base64URL-encodes it for the Gmail API. For advanced use (attachments, custom MIME), use send_message directly.
Trash Message
Move message to TRASH (Gmail API: users.messages.trash).
Untrash Message
Restore a message from TRASH (Gmail API: users.messages.untrash).
Get Attachment
Retrieve attachment payload, Base64URL-encoded data field (Gmail API: users.messages.attachments.get).
Delete Thread
Permanently delete a thread (Gmail API: users.threads.delete).
Get Thread
Retrieve a thread with format projection (Gmail API: users.threads.get).
List Threads
List threads (Gmail API: users.threads.list). Supports q, labelIds[], maxResults, pageToken, includeSpamTrash.
Modify Thread
Add / remove labels at thread granularity (Gmail API: users.threads.modify).
Trash Thread
Move thread to TRASH (Gmail API: users.threads.trash).
Untrash Thread
Restore a thread from TRASH (Gmail API: users.threads.untrash).
Get Auto-Forwarding
Read auto-forward config (Gmail API: users.settings.getAutoForwarding).
Get IMAP Settings
Read IMAP access settings (Gmail API: users.settings.getImap).
Get Language Settings
Read display language (Gmail API: users.settings.getLanguage).
Get POP Settings
Read POP access settings (Gmail API: users.settings.getPop).
Get Vacation Settings
Read vacation auto-reply config (Gmail API: users.settings.getVacation).
List Send-As Aliases
List send-as aliases (Gmail API: users.settings.sendAs.list). Read-only; mutation deferred.
Get Send-As Alias
Retrieve one send-as alias (Gmail API: users.settings.sendAs.get). Read-only; mutation deferred.
List Filters
List filters (Gmail API: users.settings.filters.list). Read-only; mutation deferred.
Get Filter
Retrieve one filter (Gmail API: users.settings.filters.get). Read-only; mutation deferred.
List Forwarding Addresses
List forwarding addresses (Gmail API: users.settings.forwardingAddresses.list). Read-only; mutation deferred.
Get Forwarding Address
Retrieve one forwarding address (Gmail API: users.settings.forwardingAddresses.get). Read-only; mutation deferred.
Nothing matches your search.
Automations using Gmail
Build your own automation with Gmail in the visual builder.
Automations with Gmail
Frequently asked questions
What can I automate with Gmail?
44 actions are available — for example: Get Profile, Watch Mailbox, Stop Watch, Create Draft, Delete Draft, and more.
Which Gmail events can start a workflow?
4 triggers — for example: Pub/Sub Push, Mailbox Change, New Gmail Message, New Gmail Thread.
Can Gmail be used as an AI agent tool?
Yes. Every Gmail action automatically becomes a tool an AI agent can call — the same pack powers both your workflows and your agents.
How is the Gmail integration modelled?
Gmail is modelled as a versioned connector pack, and the steps that need reasoning fall to first-party agents hosted in the same runtime as the workflows.