Gmail

Gmail is Google’s email service, featuring spam protection, search functions, and seamless integration with other G Suite apps for productivity

61 actions Integration catalog
Request access
Connect Gmail once you're in Boring.
01 · WHAT THE AGENT CAN DO

Actions

Every capability is a discrete, logged action the agent calls by name — scoped to what you authorize and recorded in the run trace.

Modify email labelsGMAIL_ADD_LABEL_TO_EMAIL
This action allows you to add or remove labels from a specific email message in Gmail. By providing the user's ID and the message ID, you can modify the labels associated with that email, helping to organize or categorize messages as needed.
Batch delete Gmail messagesGMAIL_BATCH_DELETE_MESSAGES
This action allows you to delete multiple Gmail messages at once by specifying their IDs. It's useful for managing email clutter and enforcing retention policies.
Batch modify Gmail messagesGMAIL_BATCH_MODIFY_MESSAGES
This action allows users to modify labels on multiple Gmail messages simultaneously. It supports adding or removing labels for up to 1,000 messages in a single request.
Create email draftGMAIL_CREATE_EMAIL_DRAFT
This action creates a draft email in Gmail. It allows specifying recipients, subject, body content, and attachments, enabling users to prepare emails for sending at a later time.
Create Gmail filterGMAIL_CREATE_FILTER
Tool to create a new Gmail filter with specified criteria and actions. Use when the user wants to automatically organize incoming messages based on sender, subject, size, or other criteria. Note: you can only create a maximum of 1,000 filters per account.
Create labelGMAIL_CREATE_LABEL
This action creates a new label in the user's Gmail account with the specified properties. It ensures that the label name is unique and validates the color selections for the label.
Create Prompt PostGMAIL_CREATE_PROMPT_POST
Send a one-shot prompt to the Sanity Content Agent. Stateless one-shot prompt endpoint. No thread management or message persistence. Ideal for simple, single-turn interactions. Use when you need to send a single prompt and receive a response without maintaining conversation context.
Delete DraftGMAIL_DELETE_DRAFT
This action deletes a specified Gmail draft by its ID. It requires the user's permissions to perform this operation on the specified draft.
Delete Gmail filterGMAIL_DELETE_FILTER
Tool to permanently delete a Gmail filter by its ID. Use when you need to remove an existing email filtering rule.
Delete label from account (permanent)GMAIL_DELETE_LABEL
This action permanently DELETES a custom label from your Gmail account. The label will be removed from all messages that had it. System labels (INBOX, SENT, DRAFT, UNREAD, STARRED, etc.) cannot be deleted. WARNING: If you want to add or remove labels from specific messages (e.g., mark as read by removing UNREAD, or archive by removing INBOX), use the GMAIL_ADD_LABEL_TO_EMAIL action instead - this action DELETES labels entirely from your account.
Delete messageGMAIL_DELETE_MESSAGE
This action deletes a specified email message from a Gmail mailbox. You can use it to remove messages either for the authenticated user or another user with delegated access.
Delete threadGMAIL_DELETE_THREAD
Tool to immediately and permanently delete a specified thread and all its messages. This operation cannot be undone. Use threads.trash instead for reversible deletion.
Fetch emailsGMAIL_FETCH_EMAILS
This action retrieves a list of email messages from a specified Gmail account. It allows for filtering the messages based on various parameters such as label IDs and search queries, as well as controlling the level of detail returned for each message.
Fetch message by message IDGMAIL_FETCH_MESSAGE_BY_MESSAGE_ID
This action retrieves an email message from Gmail using its unique message ID. It allows users to access information about the email content based on the provided user ID.
Fetch Message by Thread IDGMAIL_FETCH_MESSAGE_BY_THREAD_ID
This action retrieves messages from a specific Gmail thread. It requires the thread's ID and the user's ID to access the messages within that thread.
Forward email messageGMAIL_FORWARD_MESSAGE
This action allows users to forward an existing Gmail message to one or more specified recipients. It retains the original message body and attachments while allowing for optional additional text to be included in the forwarded message.
Get Gmail attachmentGMAIL_GET_ATTACHMENT
This action fetches a specific attachment from a user's Gmail messages using the provided message and attachment IDs. It ensures that the returned attachment is valid and is appropriately decoded for the user.
Get Auto-Forwarding SettingsGMAIL_GET_AUTO_FORWARDING
Tool to get the auto-forwarding setting for the specified account. Use when you need to retrieve the current auto-forwarding configuration including enabled status, forwarding email address, and message disposition.
Get contactsGMAIL_GET_CONTACTS
This action retrieves the list of contacts associated with the authenticated user's Google account. It allows for filtering the fields that are returned and supports pagination for large sets of contacts.
Get DraftGMAIL_GET_DRAFT
Retrieves a single Gmail draft by its ID. Use this to fetch and inspect draft content before sending via GMAIL_SEND_DRAFT. The format parameter controls the level of detail returned.
Get Gmail filterGMAIL_GET_FILTER
Tool to retrieve a specific Gmail filter by its ID. Use when you need to inspect the criteria and actions of an existing filter.
Get label detailsGMAIL_GET_LABEL
Gets details for a specified Gmail label. Use this to retrieve label information including name, type, visibility settings, message/thread counts, and color.
Get Language SettingsGMAIL_GET_LANGUAGE_SETTINGS
Tool to retrieve the language settings for a Gmail user. Use when you need to determine the display language preference for the authenticated user or a specific Gmail account.
Get PeopleGMAIL_GET_PEOPLE
This action fetches details about a specific person identified by the resource name or retrieves a list of 'Other Contacts' if requested. You can specify which person-related fields you want to return.
Get ProfileGMAIL_GET_PROFILE
This action retrieves the Gmail profile information for a specified user. You can obtain details such as the user's primary email address and message totals.
Get Vacation SettingsGMAIL_GET_VACATION_SETTINGS
Tool to retrieve vacation responder settings for a Gmail user. Use when you need to check if out-of-office auto-replies are configured and view their content.
Import messageGMAIL_IMPORT_MESSAGE
Tool to import a message into the user's mailbox with standard email delivery scanning and classification. Use when you need to add an existing email to a Gmail account without sending it through SMTP. This method doesn't perform SPF checks, so it might not work for some spam messages.
Insert message into mailboxGMAIL_INSERT_MESSAGE
Tool to insert a message into the user's mailbox similar to IMAP APPEND. Use when you need to add an email directly to a mailbox bypassing most scanning and classification. This does not send a message.
List CSE identitiesGMAIL_LIST_CSE_IDENTITIES
Tool to list client-side encrypted identities for an authenticated user. Use when you need to retrieve CSE identity configurations including key pair associations.
List CSE key pairsGMAIL_LIST_CSE_KEYPAIRS
Tool to list client-side encryption key pairs for an authenticated user. Use when you need to retrieve CSE keypair configurations including public keys and enablement states. Supports pagination for large result sets.
List DraftsGMAIL_LIST_DRAFTS
This action retrieves a list of email drafts for the authenticated user's Gmail account. It allows the user to specify the number of drafts to return and whether to fetch detailed information for each draft.
List Gmail filtersGMAIL_LIST_FILTERS
Tool to list all Gmail filters (rules) in the mailbox. Use for security audits to detect malicious filter rules or before creating new filters to avoid duplicates.
List forwarding addressesGMAIL_LIST_FORWARDING_ADDRESSES
Tool to list all forwarding addresses for the specified Gmail account. Use when you need to retrieve the email addresses that are allowed to be used for forwarding messages.
List Gmail historyGMAIL_LIST_HISTORY
This action retrieves the change history of a Gmail mailbox, starting from a specified history ID. It is useful for syncing mailbox changes incrementally and providing updated history records.
List Gmail labelsGMAIL_LIST_LABELS
This action retrieves all labels associated with a specified Gmail account. It is useful for understanding the organization of emails for the user by categorizing them into different labels.
List Gmail messages (Deprecated)GMAIL_LIST_MESSAGES
DEPRECATED: Use GMAIL_FETCH_EMAILS instead. Lists the messages in the user's mailbox. Use when you need to retrieve a list of email messages with optional filtering by labels or search query.
List send-as aliasesGMAIL_LIST_SEND_AS
Lists the send-as aliases for a Gmail account, including the primary address and custom 'from' aliases. Use when you need to retrieve available sending addresses for composing emails.
List S/MIME configsGMAIL_LIST_SMIME_INFO
Lists S/MIME configs for the specified send-as alias. Use when you need to retrieve all S/MIME certificate configurations associated with a specific send-as email address.
List threadsGMAIL_LIST_THREADS
This action fetches a list of email threads associated with a specific user. It provides options to filter results and paginate through them based on the specified parameters.
Modify thread labelsGMAIL_MODIFY_THREAD_LABELS
This action modifies the labels of a specified Gmail thread by adding or removing existing label IDs. It allows for organization of the thread's messages based on the user's input labels.
Trash threadGMAIL_MOVE_THREAD_TO_TRASH
Moves the specified thread to the trash. Any messages that belong to the thread are also moved to the trash.
Move to TrashGMAIL_MOVE_TO_TRASH
This action allows the user to move a specified email message to the trash. It requires the message ID and the user's email address or 'me' to identify the user.
Patch LabelGMAIL_PATCH_LABEL
This action modifies the properties of an existing Gmail label. It allows the user to update attributes such as the label's name, visibility, and color.
Patch send-as aliasGMAIL_PATCH_SEND_AS
Tool to patch the specified send-as alias for a Gmail user. Use when you need to update properties of an existing send-as email address such as display name, reply-to address, signature, default status, or SMTP configuration.
Remove label (Deprecated)GMAIL_REMOVE_LABEL
This action allows users to permanently delete a specific label they have created in their Gmail account using its unique ID. The label must exist and cannot be a system label.
Reply to email threadGMAIL_REPLY_TO_THREAD
This action allows users to reply to an existing email thread in Gmail. Users must provide the thread ID and at least one recipient's email address to successfully send their reply.
Search PeopleGMAIL_SEARCH_PEOPLE
This action searches your Google Contacts by name, email, phone number, or organization. You can choose to include 'Other Contacts' (people you've interacted with but haven't explicitly saved) for a more comprehensive search.
Send DraftGMAIL_SEND_DRAFT
This action sends an existing Gmail draft to the recipients already defined in it. The draft is sent as-is with its pre-configured recipients, subject, and body.
Send EmailGMAIL_SEND_EMAIL
This action sends an email using the Gmail API from the authenticated user's email account. It requires at least one recipient and either a subject or body for the email to be sent.
Get IMAP SettingsGMAIL_SETTINGS_GET_IMAP
This action retrieves the IMAP settings configured for a Gmail user account. It provides information about IMAP configuration, such as whether IMAP is enabled and how messages are handled when deleted.
Get POP settingsGMAIL_SETTINGS_GET_POP
Tool to retrieve POP settings for a Gmail account. Use when you need to check the current POP configuration including access window and message disposition.
Get send-as aliasGMAIL_SETTINGS_SEND_AS_GET
Tool to retrieve a specific send-as alias configuration for a Gmail user. Use when you need to get details about a send-as email address including display name, signature, SMTP settings, and verification status. Fails with HTTP 404 if the specified address is not a member of the send-as collection.
Stop watch notificationsGMAIL_STOP_WATCH
Tool to stop receiving push notifications for a Gmail mailbox. Use when you need to disable watch notifications previously set up via the watch endpoint.
Untrash MessageGMAIL_UNTRASH_MESSAGE
Tool to remove a message from trash in Gmail. Use when you need to restore a previously trashed email message.
Untrash threadGMAIL_UNTRASH_THREAD
Tool to remove a thread from trash in Gmail. Use when you need to restore a deleted thread and its messages.
Update draftGMAIL_UPDATE_DRAFT
Updates (replaces) an existing Gmail draft's content in-place by draft ID. This action replaces the entire draft content with the new message - it does not patch individual fields. All fields are optional; if not provided, you should provide complete draft content to avoid data loss.
Update IMAP settingsGMAIL_UPDATE_IMAP_SETTINGS
Tool to update IMAP settings for a Gmail account. Use when you need to modify IMAP configuration such as enabling/disabling IMAP, setting auto-expunge behavior, or configuring folder size limits.
Update LabelGMAIL_UPDATE_LABEL
Tool to update the properties of an existing Gmail label. Use when you need to modify label name, visibility settings, or color.
Update Language SettingsGMAIL_UPDATE_LANGUAGE_SETTINGS
Tool to update the language settings for a Gmail user. Use when you need to change the display language preference for the authenticated user or a specific Gmail account. The returned displayLanguage may differ from the requested value if Gmail selects a close variant.
Update POP settingsGMAIL_UPDATE_POP_SETTINGS
Tool to update POP settings for a Gmail account. Use when you need to configure POP access window or message disposition behavior.
Showing the first 60 of 61 actions.