Skip to main content
Glama
gmail-fast-mcp

gmail-fast-mcp

by jeffmm

gmail-fast-mcp

Gmail MCP server built with FastMCP. Provides 19 tools for email operations, label management, filter management, and attachment handling via the Gmail API.

Setup

1. Google OAuth Credentials

Place your Google Cloud OAuth client credentials at ~/.gmail-mcp/gcp-oauth.keys.json (or in the project directory — they'll be copied automatically).

2. Authenticate

uv run python -m gmail_fast_mcp auth

This opens a browser for the OAuth flow and saves tokens to ~/.gmail-mcp/credentials.json.

For cloud environments with a custom callback URL:

uv run python -m gmail_fast_mcp auth https://your-domain.com/oauth2callback

3. Run the Server

uv run python -m gmail_fast_mcp

MCP Client Configuration

{
  "mcpServers": {
    "gmail": {
      "command": "uv",
      "args": ["run", "--directory", "/path/to/gmail-fast-mcp", "python", "-m", "gmail_fast_mcp"]
    }
  }
}

Related MCP server: Gmail MCP Server

Tools

Tool

Description

send_email

Send an email (text/html/multipart, attachments, threading)

draft_email

Create an email draft

read_email

Retrieve email content and attachment metadata

search_emails

Search using Gmail query syntax

modify_email

Add/remove labels on a message

trash_email

Move a message to trash

batch_modify_emails

Modify labels on multiple messages

batch_trash_emails

Trash multiple messages

list_email_labels

List all Gmail labels

create_label

Create a new label

update_label

Update label name/visibility

delete_label

Delete a user label

get_or_create_label

Find existing label or create it

create_filter

Create a filter with custom criteria/actions

list_filters

List all filters

get_filter

Get filter details

delete_filter

Delete a filter

create_filter_from_template

Create a filter from a preset template

download_attachment

Download an attachment to disk

Gmail API Scopes

  • gmail.modify — Read, send, modify emails and labels

  • gmail.settings.basic — Manage filters and settings

Available Tools

19 tools
batch_modify_emailsB

Modify labels for multiple emails in batches.

Inputs: message_ids (required), batch_size, add_label_ids, remove_label_ids. Returns: result

batch_trash_emailsA

Move multiple emails to trash in batches.

Inputs: message_ids (required), batch_size. Returns: result

create_filterB

Create a new Gmail filter with custom criteria and actions.

Inputs: action (required), criteria (required). Returns: result

create_filter_from_templateB

Create a filter using a pre-defined template for common scenarios.

Inputs: template (required), archive, label_ids, search_text, +6 more. Returns: result

create_labelC

Create a new Gmail label.

Inputs: name (required), label_list_visibility, message_list_visibility. Returns: result

delete_filterB

Delete a Gmail filter.

Inputs: filter_id (required). Returns: result

delete_labelB

Delete a Gmail label.

Inputs: id (required). Returns: result

download_attachmentB

Download an email attachment to a specified location.

Inputs: message_id (required), attachment_id (required), filename, save_path. Returns: result

draft_emailC

Create an email draft.

Inputs: to (required), body (required), subject (required), cc, +6 more. Returns: result

get_filterA

Get details of a specific Gmail filter.

Inputs: filter_id (required). Returns: result

get_or_create_labelA

Get an existing label by name or create it if it doesn't exist.

Inputs: name (required), label_list_visibility, message_list_visibility. Returns: result

list_email_labelsA

Retrieve all available Gmail labels.

Inputs: no named parameters. Returns: result

list_filtersA

Retrieve all Gmail filters.

Inputs: no named parameters. Returns: result

modify_emailC

Modify email labels (move to different folders).

Inputs: message_id (required), label_ids, add_label_ids, remove_label_ids. Returns: result

read_emailC

Retrieve the content of a specific email.

Inputs: message_id (required). Returns: result

search_emailsB

Search for emails using Gmail search syntax.

Inputs: query (required), max_results. Returns: result

send_emailC

Send a new email.

Inputs: to (required), body (required), subject (required), cc, +6 more. Returns: result

trash_emailB

Move an email to the trash.

Inputs: message_id (required). Returns: result

update_labelB

Update an existing Gmail label.

Inputs: id (required), name, label_list_visibility, message_list_visibility. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 19 tools

    Disambiguation4/5

    Most tools target a distinct resource and action: labels, filters, emails, attachments, and drafts. The only real ambiguity is between modify_email and trash_email (both affect email placement) and between create_filter and create_filter_from_template, but the descriptions clarify the difference.

    Naming Consistency5/5

    All tool names are lowercase snake_case and follow a verb_noun pattern, from list_email_labels to batch_trash_emails. Even compound operations like get_or_create_label and create_filter_from_template fit the pattern without mixing styles.

    Tool Count3/5

    At 19 tools, the set sits in the 16-25 range that reads as heavy for an MCP server. That said, each tool has a role in Gmail's email/label/filter domain, so it is not extreme.

    Completeness4/5

    Labels and filters have full CRUD plus conveniences, and emails can be sent, read, searched, labeled, trashed, and have attachments downloaded. Missing draft lifecycle operations (send/update/list/delete) and restore/permanent-delete are the main gaps, but core workflows are still achievable.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      A comprehensive MCP server providing 24 tools for full Gmail management, including email operations, label organization, and batch filtering. It features multi-account support and secure OAuth authentication for interacting with mailboxes via natural language.
      -
    • F
      license
      B
      quality
      D
      maintenance
      A comprehensive MCP server for Gmail, providing 17 tools to read, send, search, and manage emails with OAuth2 authentication, including attachment handling and privacy features.
      18
      -
    • A
      license
      Not graded
      quality
      D
      maintenance
      An MCP server that provides Gmail access for LLMs, enabling email composition, sending, searching, and label management via the Gmail API.
      MIT