# Gmail integration

> Google email platform for sending, reading, managing messages, labels, drafts, and threads.

- Authentication: oauth2

## Tools (30)

- **Batch Delete Messages**: Permanently deletes multiple messages by ID. Provides no guarantees that messages existed or weren't already deleted.
- **Batch Modify Messages**: Modifies labels on multiple messages at once (up to 1000 per request).
- **Create a Draft**: Creates a new draft with a base64url-encoded RFC 2822 email message.
- **Create a Label**: Creates a new user label with configurable visibility and color settings.
- **Delete a Draft**: Immediately and permanently deletes a draft without moving it to trash.
- **Delete a Label**: Permanently deletes a label and removes it from all messages and threads it was applied to.
- **Delete a Message**: Immediately and permanently deletes a message. This cannot be undone — prefer trash instead.
- **Delete a Thread**: Immediately and permanently deletes a thread and all its messages. This cannot be undone — prefer trash instead.
- **Get a Draft**: Gets a specific draft by ID, with configurable detail level.
- **Get a Label**: Gets a specific label by ID, including message/thread counts.
- **Get a Message**: Gets a specific message by ID, with configurable detail level (full, metadata, minimal, raw).
- **Get a Thread**: Gets a specific thread by ID, including all messages in the conversation.
- **Get Attachment**: Gets a specific message attachment by attachment ID, returning base64url-encoded attachment data.
- **Get User Profile**: Gets the current user's Gmail profile including email address, total messages, total threads, and history ID.
- **List Drafts**: Lists drafts in the user's mailbox with optional search filtering and pagination.
- **List History**: Lists the history of changes to the mailbox since a given history ID, useful for incremental sync.
- **List Labels**: Lists all labels in the user's mailbox, including system labels and user-created labels.
- **List Messages**: Lists message IDs and thread IDs in the user's mailbox, with optional search query and label filtering.
- **List Threads**: Lists thread IDs and snippets in the user's mailbox, with optional search query and label filtering.
- **Modify Message Labels**: Adds or removes labels on a specific message, such as marking as read/unread, starring, or applying custom labels.
- **Modify Thread Labels**: Adds or removes labels on an entire thread, applying the changes to all messages in the thread.
- **Reply to a Message**: Replies to an existing message by sending with In-Reply-To and References headers and a threadId to keep it in the same conversation thread.
- **Send a Draft**: Sends an existing draft to the recipients in its To, Cc, and Bcc headers.
- **Send a Message**: Sends a new email message to recipients specified in the To, Cc, and Bcc headers of a base64url-encoded RFC 2822 message.
- **Trash a Message**: Moves a specific message to the trash. The message can later be restored with untrash.
- **Trash a Thread**: Moves a thread and all its messages to the trash.
- **Untrash a Message**: Removes a specific message from the trash, restoring it to the mailbox.
- **Untrash a Thread**: Removes a thread and all its messages from the trash, restoring them to the mailbox.
- **Update a Draft**: Replaces the content of an existing draft with a new base64url-encoded RFC 2822 email message.
- **Update a Label**: Updates an existing label's name, visibility, and color settings. Replaces the full label resource.

## Triggers (5)

- **New Email in Gmail**: Triggers when a new email arrives matching the configured filters
- **New Attachment in Gmail**: Triggers on emails with attachments, with optional MIME type and filename filters
- **New Starred Email in Gmail**: Triggers when an email is starred (is:starred)
- **New Conversation in Gmail**: Triggers once per new email thread. Replies on existing threads will not re-trigger.
- **New Sent Email in Gmail**: Triggers when an email is sent from the connected account

## Related prompts

- [Weekly Braintree revenue and refund report for finance](https://www.generalinput.com/prompts/weekly-braintree-revenue-and-refund-report-for-finance.md)
- [Recover failed subscription payments before they churn](https://www.generalinput.com/prompts/recover-failed-subscription-payments-before-they-churn.md)
- [Weekly ClickHouse Cloud security and access review email](https://www.generalinput.com/prompts/weekly-clickhouse-cloud-security-and-access-review-email.md)
- [Morning airport disruption brief for operations teams](https://www.generalinput.com/prompts/morning-airport-disruption-brief-for-operations-teams.md)
- [Weekly support performance report for your leadership team](https://www.generalinput.com/prompts/weekly-support-performance-report-for-your-leadership-team.md)
- [Weekly subscription revenue and churn brief for leadership](https://www.generalinput.com/prompts/weekly-subscription-revenue-and-churn-brief-for-leadership.md)
- [Thank-you and review-request emails after every job](https://www.generalinput.com/prompts/thank-you-and-review-request-emails-after-every-job.md)
- [Weekly accounts-receivable chaser for Housecall Pro](https://www.generalinput.com/prompts/weekly-accounts-receivable-chaser-for-housecall-pro.md)
- [Automatic follow-up emails for open Housecall Pro estimates](https://www.generalinput.com/prompts/automatic-follow-up-emails-for-open-housecall-pro-estimates.md)
- [Weekly UK company watchlist alerts from Companies House](https://www.generalinput.com/prompts/weekly-uk-company-watchlist-alerts-from-companies-house.md)
- [Daily GreyNoise threat brief for your security team](https://www.generalinput.com/prompts/daily-greynoise-threat-brief-for-your-security-team.md)
- [Weekday growth digest of new signups, emailed to your team](https://www.generalinput.com/prompts/weekday-growth-digest-of-new-signups-emailed-to-your-team.md)

Connect Gmail in General Input: https://www.generalinput.com/apps/gmail