Gmail MCP server

Endpoint: https://gmailmcp.googleapis.com/mcp/v1 · Authentication: No auth

Google's Gmail server searches threads, reads threads and messages, creates and lists drafts, and manages labels, trash and spam in the user's mailbox. It has no send tool. Tool calls need Google OAuth.

How do I authenticate?

Add the endpoint directly in your client. The catalog records no authentication requirement; no OAuth sign-in or API key is configured in this setup. The live server may change.

Authentication and connection guide

Connection specification

Remote endpoint
https://gmailmcp.googleapis.com/mcp/v1
Browser access
Not yet measured
Declared MCP transport
Streamable HTTP
Live-validated MCP transport
Streamable HTTP — Observed by the latest catalog validation
Declared authentication
No authentication
Detected authentication
No authentication detected or retained from publisher evidence
Alternative authentication
OAuth 2.1
Protocol lifecycle
Stateless MCP · 2026-07-28
Authorization server
https://accounts.google.com/

Product documentation · Official listing documentation · Claude connector directory listing

Provider guidance

  • Only the tool list is public: tools/list answers without credentials, but tool calls return 401 until the user signs in with Google OAuth (the server advertises accounts.google.com as its authorization server).
  • Google lists these servers in its Workspace Developer Preview Program. The OAuth client is pre-registered in the user's own Google Cloud project with the MCP service enabled; the server does not advertise Dynamic Client Registration.

More Communication MCP servers · Browse all MCP servers · Test this endpoint in the MCP Playground

Authorization setup

No app registration needed

This catalog entry does not require authorization or provider app registration.

Connect it

Live-validated endpoint: https://gmailmcp.googleapis.com/mcp/v1 · Streamable HTTP. No authentication is required by the catalog listing.

Agent prompt for Claude Code or Codex
Add the Gmail MCP server to my MCP client configuration and verify that it works.

What it is: Google's Gmail server searches threads, reads threads and messages, creates and lists drafts, and manages labels, trash and spam in the user's mailbox. It has no send tool. Tool calls need Google OAuth.
Server URL: https://gmailmcp.googleapis.com/mcp/v1
Transport: Streamable HTTP (remote MCP server, no local install).
Authentication: none. The server accepts connections without credentials.
Tools (23, as last observed by mcptest): apply_sensitive_message_label, apply_sensitive_thread_label, create_draft, create_label, get_draft, get_message, get_thread, label_message, label_thread, list_drafts, list_labels, mark_message_spam, mark_thread_spam, search_threads, trash_message, trash_thread, unlabel_message, unlabel_thread, unmark_message_spam, unmark_thread_spam, untrash_message, untrash_thread, update_message_labels.
Reference: https://mcptest.io/servers/gmail/

Steps:
1. Work out which MCP client I use (Claude Code, Codex, Cursor, VS Code or another) and add the server under the name "gmail" in that client's MCP configuration, user scope unless I ask otherwise.
   Claude Code: claude mcp add --transport http --scope user 'gmail' 'https://gmailmcp.googleapis.com/mcp/v1'
   Codex: codex mcp add 'gmail' --url 'https://gmailmcp.googleapis.com/mcp/v1'
   Other clients: use the setup for that client on the reference page.
2. Never write a credential value into a file that could be committed; reference an environment variable or the client's secret store, and ask me for any value you need.
3. Verify: connect to the server and call tools/list. Confirm the tools above are listed, and report any sign-in step I still have to complete.
MCP client

Claude Code setup

Run in a terminal. This user-scoped entry is available across projects.

claude mcp add --transport http --scope user 'gmail' 'https://gmailmcp.googleapis.com/mcp/v1'

Codex CLI setup

Run in a terminal; Codex stores the entry in ~/.codex/config.toml.

codex mcp add 'gmail' --url 'https://gmailmcp.googleapis.com/mcp/v1'

Cursor setup

Add to .cursor/mcp.json for this project, or ~/.cursor/mcp.json for all projects.

{
  "mcpServers": {
    "gmail": {
      "url": "https://gmailmcp.googleapis.com/mcp/v1"
    }
  }
}

VS Code setup

Add to .vscode/mcp.json, or run “MCP: Open User Configuration” for a private user-level entry.

{
  "servers": {
    "gmail": {
      "type": "http",
      "url": "https://gmailmcp.googleapis.com/mcp/v1"
    }
  }
}

Claude setup

Add the endpoint above in Claude:

  • Customize > Connectors > Add custom connector
  • Team/Enterprise: Organization settings > Connectors > Add > Custom > Web

Claude Desktop setup

Add the endpoint above in Claude Desktop:

  • Remote: Customize > Connectors (same as claude.ai)
  • Local: Settings > Developer > Edit Config, or Settings > Extensions for .mcpb files
  • ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows), local servers only

ChatGPT setup

Add the endpoint above in ChatGPT:

  • ChatGPT web: Plugins > Add custom MCP server, then configure authentication and accept the risk warning

Windsurf setup

Add the endpoint above in Windsurf:

  • ~/.config/devin/mcp_config.json (%APPDATA%\devin\mcp_config.json on Windows), serverUrl or url
  • Cascade panel > ... > MCPs > Open MCP config file

Gemini CLI setup

Add the endpoint above in Gemini CLI:

  • gemini mcp add --transport http <name> <url>
  • ~/.gemini/settings.json (user) or .gemini/settings.json (project), mcpServers

MCP SDK setup

Add the endpoint above in MCP SDK:

  • Programmatic: new Client(...).connect(new StreamableHTTPClientTransport(url))

Notes for every client

  • An optional oauth flow is cataloged, but its exact header is not documented; follow the publisher instructions instead of guessing.
  • Provider guidance: Only the tool list is public: tools/list answers without credentials, but tool calls return 401 until the user signs in with Google OAuth (the server advertises accounts.google.com as its authorization server).
  • Provider guidance: Google lists these servers in its Workspace Developer Preview Program. The OAuth client is pre-registered in the user's own Google Cloud project with the MCP service enabled; the server does not advertise Dynamic Client Registration.

Client compatibility

ClientStatusWhy
Claude CodeSupportedClaude Code supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
CodexSupportedCodex supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
CursorSupportedCursor supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
VS CodeSupportedVS Code supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
ClaudeSupportedClaude supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
Claude DesktopSupportedClaude Desktop supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
ChatGPTSupportedChatGPT supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
WindsurfPartialWindsurf's documentation does not state support for servers without authentication.
Gemini CLISupportedGemini CLI supports Streamable HTTP servers and servers without authentication or OAuth sign-in.
MCP SDKSupportedMCP SDK supports Streamable HTTP servers and servers without authentication or OAuth sign-in.

Computed from this server's validated transport, protocol and authentication against documented client support. Checks the catalog has not observed are not counted.

Similar servers

  • Slack — Remote MCP server for Slack messages, channels, users, canvases, and collaboration context. OAuth 2.1
  • Intercom — Intercom's hosted MCP server provides customer-support context through conversations, contacts, search, and retrieval tools. OAuth 2.1
  • Resend — Sends and schedules email and manages Resend domains, audiences, contacts, broadcasts, and API keys. Requires Resend sign-in through OAuth. OAuth 2.1
  • Vapi — Lists, creates, and updates Vapi voice assistants, phone numbers, and tools and places outbound calls. Sign in with your Vapi account over OAuth; the hosted server no longer accepts API keys. OAuth 2.1
  • Courier — Sends notifications and manages Courier users, lists, templates, journeys, preferences, tenants, and brands through the Courier API. Requires a Courier API key in the api_key header. API key
  • AgentMail — Creates and manages AgentMail inboxes, threads, messages, drafts, and attachments for AI agents. Requires AgentMail sign-in through OAuth; an x-api-key header is also documented. OAuth 2.1

Guides for this server

Watch this server for breaking changes

Share and embed

Maintain Gmail? Embed this badge in your README. It follows the latest catalog validation result and links to this server profile.

mcptest.io: ready

Latest validation evidence

Validation status
Online when last tested
Validation checked at
Nov 23, 2026 at 7:17 PM
Validation detail
Negotiated stateless MCP 2026-07-28 at https://gmailmcp.googleapis.com/mcp/v1; detected transport streamable-http; authentication none; WARNING: OAuth authorization servers advertised; an anonymous MCP handshake does not establish anonymous tool access

Tool inventory

What the catalog validator observed on at https://gmailmcp.googleapis.com/mcp/v1 without credentials. The live server may have changed since; connect in the Playground for the current list.

Tools provided by Gmail 23

Some details were sanitized for public display.

  • apply_sensitive_message_labeloutputSchema declared

    Prefer `trash_message` or `mark_message_spam` instead. Adds a sensitive label (Trash or Spam) to a single message in the authenticated user's Gmail account. Use `apply_sensitive_message_label` when applying Trash or Spam to exactly 1 message. If the message belongs to a thread that should be labeled as a whole, prefer `trash_thread` or `mark_thread_spam`. To find the message ID, use the `get_thread` tool. To find the draft message ID, use tools like `list_drafts`.

    Input labelOption: string, messageId: string
    • labelOption: stringrequired

      Required. The sensitive label option to add.

    • messageId: stringrequired

      Required. The ID of the message to add the label to.

  • apply_sensitive_thread_labeloutputSchema declared

    Prefer `trash_thread` or `mark_thread_spam` instead. Adds a sensitive label (Trash or Spam) to a single thread in the authenticated user's Gmail account. This operation affects all messages currently in the thread. Use `apply_sensitive_thread_label` when applying Trash or Spam to exactly 1 thread.

    Input labelOption: string, threadId: string
    • labelOption: stringrequired

      Required. The sensitive label option to add.

    • threadId: stringrequired

      Required. The ID of the thread to add the label to.

  • create_draftoutputSchema declared

    Creates a new draft email in the authenticated user's Gmail account. This tool takes recipient addresses (`to`, `cc`, `bcc`), a `subject`, and body content as inputs. Plain text body content can be provided in `body` (do NOT format `body` with Markdown), and rich-text HTML content can be provided in `htmlBody` (use valid HTML tags for formatting; if both are provided, `body` serves as the plain-text alternative). If the draft is created as a reply to an existing message, the ID of the original message should be passed to the tool in the `replyToMessageId` field. Set `includeSignature` to true

    Input attachments?: array, bcc?: array, body?: string, cc?: array, htmlBody?: string, includeSignature?: boolean, replyToMessageId?: string, subject?: string, to?: array
    • attachments?: arrayoptional

      Optional. The attachments to include in the email. The combined size of attachments in the message cannot exceed 25MB. If you need to send files larger than 25MB, upload the file to Drive first and then insert the Drive link into `body` or `htmlBody`.

    • bcc?: arrayoptional

      Optional. The blind carbon copy recipients of the email draft. Each string MUST be a valid plain email address (e.g., "[email protected]").

    • body?: stringoptional

      Optional. The plain text body content of the email draft. Do NOT format this field with Markdown (such as headers `#`, bold `**`, bullet points `*`, or tables `|`). If formatted rich text is desired, use `htmlBody` instead. If `htmlBody` is also provided, this field is treated as the plain-text alternative.

    • cc?: arrayoptional

      Optional. The carbon copy recipients of the email draft. Each string MUST be a valid plain email address (e.g., "[email protected]").

    • htmlBody?: stringoptional

      Optional. The HTML content of the email draft. If provided, this will be used as the rich-text version of the email. Use this field (with valid HTML tags such as `p`, `b`, `ul`, `li`, `h1`) whenever rich text formatting is needed.

    • includeSignature?: booleanoptional

      Optional. Whether to append the user's configured Gmail web signature to the draft. Defaults to false.

    • replyToMessageId?: stringoptional

      Optional. The ID of the message to reply to. If provided, this will be used as the reply-to message ID for the email draft, and the `body` and `htmlBody` will be appended to the original message body.

    • subject?: stringoptional

      Optional. The subject line of the email. Defaults to empty if not provided.

    • to?: arrayoptional

      Optional. The primary recipients of the email draft. Each string MUST be a valid plain email address (e.g., "[email protected]").

  • create_labeloutputSchema declared

    Creates a new label in the authenticated user's Gmail account. Supports creating nested labels (sub-labels) using a forward slash (e.g., 'Projects/Alpha/Sprint-1'). By default, parent labels will be automatically created if they do not exist.

    Input autoCreateParentLabels?: boolean, color?: any, colorPreset?: string, displayName: string, labelListVisibility?: string, messageListVisibility?: string
    • autoCreateParentLabels?: booleanoptional

      Optional. Whether to automatically create parent labels for nested labels (separated by `/`). Defaults to `true`. When set to `true`, missing parent labels in the hierarchy (e.g., `Projects` and `Projects/Alpha` for `Projects/Alpha/Sprint-1`) are created automatically. When set to `false`, parent label auto-creation is disabled.

    • color?: anyoptional

      Deprecated: Do not use. Use `colorPreset` instead. Legacy field for raw text and background color hex strings.

    • colorPreset?: stringoptional

      Optional. The color preset tile to assign to the new label. Select from predefined contrast-safe color options (e.g., LABEL_COLOR_PRESET_RED, LABEL_COLOR_PRESET_BLUE, LABEL_COLOR_PRESET_BLACK, LABEL_COLOR_PRESET_GREEN). If omitted, default label styling is applied.

    • displayName: stringrequired

      Required. The display name of the label to create. Supports nested label hierarchy using `/` (e.g., `Projects/Alpha/Sprint-1`).

    • labelListVisibility?: stringoptional

      Optional. The visibility of the label in the label list in the Gmail web interface. Defaults to `LABEL_SHOW`.

    • messageListVisibility?: stringoptional

      Optional. The visibility of messages with this label in the message list in the Gmail web interface. Defaults to `SHOW`.

  • get_draftoutputSchema declared

    Retrieves a specific draft email from the authenticated user's Gmail account by ID, including its `viewUrl` for viewing and editing in the Gmail Web UI. The optional `messageFormat` parameter controls the format of the draft returned. By default (or with `PLAIN_TEXT`), it returns the plain text body without the HTML body. Use `MINIMAL` to return snippet and key headers, `METADATA_ONLY` to exclude snippet, subject, and body, `FULL_CONTENT` for the complete draft including the HTML body, or `RAW` for the raw MIME message content.

    Input draftId: string, messageFormat?: string
    • draftId: stringrequired

      Required. The unique identifier of the draft to fetch.

    • messageFormat?: stringoptional

      Optional. Specifies the format of the draft returned. Defaults to `PLAIN_TEXT`.

  • get_messageoutputSchema declared

    Retrieves a specific email message from the authenticated user's Gmail account by its unique message ID, including its `viewUrl`. Use this tool to inspect a single, individual email when you already know its message ID. If the user wants to read a specific email in detail, check the exact wording of a message, or examine attachment metadata for a single email, this is the right tool. It is not suitable for retrieving entire conversations or viewing back-and-forth discussion threads; use the 'get_thread' tool instead. Note: This tool does not support retrieving draft messages. To view drafts, u

    Input messageFormat?: string, messageId: string
    • messageFormat?: stringoptional

      Optional. Specifies the format of the message returned. Defaults to `PLAIN_TEXT`. Use `FULL_CONTENT` only when the HTML body is needed.

    • messageId: stringrequired

      Required. The unique identifier of the message to fetch.

  • get_threadoutputSchema declared

    Retrieves a specific email thread from the authenticated user's Gmail account, including its `viewUrl` and a list of its messages (each with their own `viewUrl`). Note: This tool does not support retrieving drafts. Any draft messages within a thread are omitted. To view drafts, use the `list_drafts` tool instead. The optional `messageFormat` parameter controls the format of the messages returned. By default (or with `PLAIN_TEXT`), it returns the plain text body without the HTML body. Use `FULL_CONTENT` only when the HTML body is needed. Use `MINIMAL` to include only subject and snippet (exclud

    Input messageFormat?: string, threadId: string
    • messageFormat?: stringoptional

      Optional. Specifies the format of the messages returned within the thread. Defaults to `PLAIN_TEXT`. Use `FULL_CONTENT` only when the HTML body is needed. Note: `MINIMAL` format returns `id`, `snippet`, `subject`, `sender`, `toRecipients`, `ccRecipients`, `bccRecipients`, `date`, `labelIds`, `viewUrl` (if applicable). `METADATA_ONLY` format returns `id`, `sender`, `toRecipients`, `ccRecipients`, `bccRecipients`, `date`, `labelIds`, `viewUrl` (if applicable). `FULL_CONTENT` returns `id`, `snippet`, `subject`, `sender`, `toRecipients`, `ccRecipients`, `bccRecipients`, `date`, `labelIds`, `attach

    • threadId: stringrequired

      Required. The unique identifier of the thread to fetch.

  • label_messageoutputSchema declared

    Adds one or more labels to a specific message in the authenticated user's Gmail account. To find the message ID, use the `get_thread` tool. If unsure of a user label's ID, use the `list_labels` tool first to discover available labels and their IDs. To move a message to a different inbox category tab, add the target `CATEGORY_*` label (e.g. `CATEGORY_PERSONAL` for Primary); Gmail automatically removes the previous category. To move a specific message to Trash or mark it as Spam, please use the `trash_message` or `mark_message_spam` tool instead.

    Input labelIds: array, messageId: string
    • labelIds: arrayrequired

      Required. The IDs of the labels to add. Can be a system label ID (e.g., `INBOX`, `STARRED`, `UNREAD`, `IMPORTANT`) or a user-defined label ID. The tool accepts `labelIds` and not label names. Use the `list_labels` tool to get the corresponding label id to a display name for user-defined labels.

    • messageId: stringrequired

      Required. The ID of the message to add the labels to.

  • label_threadoutputSchema declared

    Adds labels to an entire thread in the authenticated user's Gmail account. This operation affects all messages currently in the thread and any future messages added to it. If unsure of a user label's ID, use the `list_labels` tool first to discover available labels and their IDs. To move a thread to a different inbox category tab, add the target `CATEGORY_*` label (e.g. `CATEGORY_PERSONAL` for Primary); Gmail automatically removes the previous category. To move a thread to Trash or mark it as Spam, please use the `trash_thread` or `mark_thread_spam` tool instead.

    Input labelIds: array, threadId: string
    • labelIds: arrayrequired

      Required. The unique identifiers of the labels to add. Can be a system label ID (e.g., `INBOX`, `STARRED`, `UNREAD`, `IMPORTANT`) or a user-defined label ID. The tool accepts `labelIds` and not label names. Use the `list_labels` tool to get the corresponding label id to a display name for user-defined labels.

    • threadId: stringrequired

      Required. The unique identifier of the thread to add labels to.

  • list_draftsoutputSchema declared

    Lists draft emails from the authenticated user's Gmail account, optionally filtered by a query string. Note: An empty JSON object `{}` represents zero matching items, not an error.

    Input pageSize?: integer, pageToken?: string, query?: string, view?: string
    • pageSize?: integeroptional

      Optional. The maximum number of drafts to return. If unspecified, defaults to 20. The maximum allowed value is 50.

    • pageToken?: stringoptional

      Optional. A token received from a previous `list_drafts` call to retrieve the next page of results. Leave empty to fetch the first page. This is primarily used for pagination to continue fetching results from where the previous `ListDraft` call left off, especially when the number of drafts matching the query exceeds the `pageSize` limit.

    • query?: stringoptional

      Optional. A query string to filter the drafts. Natural language queries must be pre-converted into Gmail compatible syntax queries to use this tool. If omitted, all drafts (excluding spam and trash by default) are listed. The tool inherently only searches for drafts. Supported Operators by Category: Sender & Recipient: - `from:EMAIL` - Sent from a specific person. - `to:EMAIL` - Sent to a specific person. - `cc:EMAIL` - Specific people in Cc. - `bcc:EMAIL` - Specific people in Bcc. - `deliveredto:EMAIL` - Delivered to a specific address. - `list:EMAIL` - From a specific mailing list. Time & Da

    • view?: stringoptional

      Optional. Controls the fields populated for drafts in the draft list. Defaults to returning metadata only (`id`, `threadId`, `toRecipients`, `ccRecipients`, `bccRecipients`, `date`). Set to `DRAFT_VIEW_FULL` to include `subject` and `plaintextBody` content.

  • list_labelsoutputSchema declared

    Lists all labels available in the authenticated user's Gmail account. Use this tool to discover the `labelId` and display `name` of each label in `labels` before calling `label_thread`, `unlabel_thread`, `label_message`, or `unlabel_message`. Note: the system labels, `DRAFT` and `SENT`, cannot be set on messages and are read only. Inbox category tabs are represented by system labels: `CATEGORY_PERSONAL` (Primary), `CATEGORY_SOCIAL` (Social), `CATEGORY_PROMOTIONS` (Promotions), `CATEGORY_UPDATES` (Updates), and `CATEGORY_FORUMS` (Forums). A message has at most one category: adding a category la

    Input No parameters

  • mark_message_spamoutputSchema declared

    Marks a specific message as Spam in the authenticated user's Gmail account. To find the message ID, use the `get_thread` tool.

    Input messageId: string
    • messageId: stringrequired

      Required. The ID of the message to mark as Spam.

  • mark_thread_spamoutputSchema declared

    Marks an entire thread as Spam in the authenticated user's Gmail account. This operation affects all messages currently in the thread. Use `mark_thread_spam` when marking a thread as spam, even if it currently contains only 1 message. Marking spam at the thread level ensures all current messages in the thread are marked as Spam.

    Input threadId: string
    • threadId: stringrequired

      Required. The ID of the thread to mark as Spam.

  • search_threadsoutputSchema declared

    Lists email threads from the authenticated user's Gmail account. This tool can filter threads based on a query string and supports pagination. It returns a list of threads, each with its thread `id`, `messageCount` (total messages in the thread), `viewUrl`, and a subset of up to 5 related messages (each with its own message `id`, `viewUrl`, `sender`, recipients, `date`, and `labelIds`). Use this tool to find thread `id`s matching a query before reading full threads or performing actions on matching emails or threads. The `view` parameter controls which additional fields are populated in the re

    Input includeTrash?: boolean, pageSize?: integer, pageToken?: string, query?: string, view?: string
    • includeTrash?: booleanoptional

      Optional. Include threads from TRASH in the results. Defaults to false.

    • pageSize?: integeroptional

      Optional. The maximum number of threads to return. If unspecified, defaults to 20. The maximum allowed value is 50.

    • pageToken?: stringoptional

      Optional. Page token to retrieve a specific page of results in the list. Leave empty to fetch the first page. This is primarily used for pagination to continue fetching results from where the previous `SearchThreads` call left off, especially when the number of threads matching the query exceeds the `pageSize` limit.

    • query?: stringoptional

      Optional. A query string to filter the threads. Natural language queries must be pre-converted into Gmail syntax queries to use this tool. If omitted, all threads (excluding spam and trash by default) are listed. Supported Operators by Category: Sender & Recipient: - `from:EMAIL` - Sent from a specific person. - `to:EMAIL` - Sent to a specific person. - `cc:EMAIL` - Specific people in Cc. - `bcc:EMAIL` - Specific people in Bcc. - `deliveredto:EMAIL` - Delivered to a specific address. - `list:EMAIL` - From a specific mailing list. Time & Date: - `after:YYYY/MM/DD` / `newer:YYYY/MM/DD` - Receive

    • view?: stringoptional

      Optional. Controls the fields populated for threads in the thread list. Defaults to `THREAD_VIEW_MINIMAL`. `THREAD_VIEW_MINIMAL` returns `id`, `snippet`, `subject`, `sender`, `toRecipients`, `ccRecipients`, `bccRecipients`, `date`, `labelIds`, `viewUrl` (if applicable). `THREAD_VIEW_METADATA_ONLY` returns `id`, `sender`, `toRecipients`, `ccRecipients`, `bccRecipients`, `date`, `labelIds`, `viewUrl` (if applicable). `THREAD_VIEW_IDS_ONLY` returns only `id` on each `Thread` without fetching per-thread message metadata. `THREAD_VIEW_SUMMARY` returns `THREAD_VIEW_MINIMAL` fields with only the most

  • trash_messageoutputSchema declared

    Moves a specific message to the Trash (soft delete) in the authenticated user's Gmail account. This is the default tool (along with `trash_thread`) when a user asks to 'delete', 'remove', or 'get rid of' a message without explicitly requesting permanent, irreversible deletion. Use `trash_message` when targeting a specific message within a thread. To trash an entire thread or a single-message thread, prefer `trash_thread`. To find the message ID, use the `get_thread` tool. To find the draft message ID, use tools like `list_drafts`.

    Input messageId: string
    • messageId: stringrequired

      Required. The ID of the message to move to Trash.

  • trash_threadoutputSchema declared

    Moves an entire thread to the Trash (soft delete) in the authenticated user's Gmail account. This operation affects all messages currently in the thread. This is the default tool (along with `trash_message`) when a user asks to 'delete', 'remove', or 'get rid of' an email or thread without explicitly requesting permanent, irreversible deletion. Use `trash_thread` when trashing a thread, even if it currently contains only 1 message. Trashing at the thread level ensures all current messages in the thread are moved to Trash.

    Input threadId: string
    • threadId: stringrequired

      Required. The ID of the thread to move to Trash.

  • unlabel_messageoutputSchema declared

    Removes one or more labels from a specific message in the authenticated user's Gmail account. To find the message ID, use the `get_thread` tool. If unsure of a user label's ID, use the `list_labels` tool first to discover available labels and their IDs.

    Input labelIds: array, messageId: string
    • labelIds: arrayrequired

      Required. The IDs of the labels to remove. Can be a system label ID (e.g., `INBOX`, `TRASH`, `STARRED`, `UNREAD`, `IMPORTANT`) or a user-defined label ID. `SPAM` cannot be removed with this tool. The tool accepts `labelIds` and not label names. Use the `list_labels` tool to get the corresponding label id to a display name for user-defined labels.

    • messageId: stringrequired

      Required. The ID of the message to remove the labels from.

  • unlabel_threadoutputSchema declared

    Removes labels from an entire thread in the authenticated user's Gmail account. This operation affects all messages currently in the thread. Use `unlabel_thread` when removing labels from an email or thread (such as marking it as read by removing `UNREAD`, archiving it by removing `INBOX`, or removing user-defined labels), even if the thread currently contains only 1 message. If unsure of a user label's ID, use the `list_labels` tool first.

    Input labelIds: array, threadId: string
    • labelIds: arrayrequired

      Required. The unique identifiers of the labels to remove. Can be a system label ID (e.g., `INBOX`, `TRASH`, `STARRED`, `UNREAD`, `IMPORTANT`) or a user-defined label ID. `SPAM` cannot be removed with this tool. The tool accepts `labelIds` and not label names. Use the `list_labels` tool to get the corresponding label id to a display name for user-defined labels.

    • threadId: stringrequired

      Required. The unique identifier of the thread to remove labels from.

  • unmark_message_spamoutputSchema declared

    Unmarks a specific message as Spam in the authenticated user's Gmail account. This does not return the message to the Inbox; to move it to the Inbox, add the `INBOX` label separately. To find the message ID, use the `get_thread` tool.

    Input messageId: string
    • messageId: stringrequired

      Required. The ID of the message to unmark as Spam.

  • unmark_thread_spamoutputSchema declared

    Unmarks an entire thread as Spam in the authenticated user's Gmail account. This does not return the thread to the Inbox; to move it to the Inbox, add the `INBOX` label separately.

    Input threadId: string
    • threadId: stringrequired

      Required. The ID of the thread to unmark as Spam.

  • untrash_messageoutputSchema declared

    Removes a specific message from the Trash in the authenticated user's Gmail account. This does not return the message to the Inbox; to move it to the Inbox, add the `INBOX` label separately. To find the message ID, use the `get_thread` tool.

    Input messageId: string
    • messageId: stringrequired

      Required. The ID of the message to remove from Trash.

  • untrash_threadoutputSchema declared

    Removes an entire thread from the Trash in the authenticated user's Gmail account. This does not return the thread to the Inbox; to move it to the Inbox, add the `INBOX` label separately.

    Input threadId: string
    • threadId: stringrequired

      Required. The ID of the thread to remove from Trash.

  • update_message_labelsoutputSchema declared

    Atomically adds and/or removes labels from a specific message in the authenticated user's Gmail account. Requires at least one of `addLabelIds` or `removeLabelIds` to be provided. Moving an email between labels can be accomplished in a single call by specifying the target label in `addLabelIds` and the current label in `removeLabelIds`. For inbox category tabs, adding the target `CATEGORY_*` label (e.g. `CATEGORY_PERSONAL` for Primary) is sufficient; Gmail automatically removes the previous category.

    Input addLabelIds?: array, messageId: string, removeLabelIds?: array
    • addLabelIds?: arrayoptional

      Optional. The IDs of the labels to add. Can be a system label ID (e.g., `INBOX`, `STARRED`, `UNREAD`, `IMPORTANT`) or a user-defined label ID.

    • messageId: stringrequired

      Required. The ID of the message to modify labels for.

    • removeLabelIds?: arrayoptional

      Optional. The IDs of the labels to remove. Can be a system label ID or a user-defined label ID.