GMail-Manager-MCP is a tool that provides direct access to a Gmail inbox through the Model Context Protocol (MCP), and the project is hosted on GitHub (https://github.com/muammar-yacoob/GMail-Manager-MCP#readme)。其核心用途是让用户用自然语言清理、整理和查询 Gmail emails, and can integrate with Calendar and Drive.
Main capabilities
- Email cleanup and organization: batch delete promotional emails, newsletters, notification emails, password reset emails, etc.; create and move labels; find emails with large attachments; and generate inbox insights such as sender counts and busiest email days.
- Email summarization and replies: summarize emails on a specified subject or topic; generate reply drafts.
- Calendar operations: view this week's schedule, find common free time slots, move meetings and add Meet links, decline meetings with comments, and search calendar events.
- Rules and unsubscribe: view the account's existing rules; create rules (for example, emails from noreply@ skip the inbox and are labeled Noise); get sender unsubscribe links or perform unsubscribe.
- Attachments and Drive: save attachments to Google Drive (requires Drive permission).
Usage
- Prerequisites: Create a project in Google Cloud, enable the Gmail, Calendar, and Drive APIs, create an OAuth client ID (desktop app type), download it as gcp-oauth.keys.json, and add the three scopes in Data access:https://mail.google.com/、https://www.googleapis.com/auth/calendar、https://www.googleapis.com/auth/drive.file,同时将 Add the Google email to Test users.
- Configuration file locations: the current directory ./gcp-oauth.keys.json, the home directory ~/gcp-oauth.keys.json, or a custom path specified through the GMAIL_OAUTH_PATH environment variable.
- Installation and running: It can be run directly via npx, or installed globally as gmail-manager; it supports one-line installation in Claude Code and requires authorizing the Google account once.
- MCP client configuration: Add the server configuration to the configuration file of clients such as Claude Desktop (Windows path %APPDATA%\Claude\claude_desktop_config.json, macOS path ~/Library/Application Support/Claude/claude_desktop_config.json, Linux path ~/.config/Claude/claude_desktop_config.json).
- Send control: Sending is disabled by default, and all write operations only generate drafts. After setting GMAIL_ENABLE_SEND=1 and restarting the MCP client, three send-related tools are added.
- Cache: Emails are cached locally and verified based on Gmail's historyId to avoid duplicate downloads; GMAIL_CACHE=memory can be used to keep the cache out of disk.
Applicable scenarios Suitable for users who need to batch clean their inbox, organize emails by label, quickly summarize emails, manage calendar schedules, handle unsubscribes, and save attachments to Drive, especially for workflows that operate Gmail in natural language through an MCP client.
Limitations and notes
- When upgrading to a version that supports Calendar or Drive, because Google does not add scopes to already issued tokens, reauthentication is required once; otherwise Calendar calls and save_attachment_to_drive will fail due to permission errors.
- Sending is disabled by default and must be enabled by explicitly setting the environment variable.
- Drive uses the drive.file scope and can only access files created by this app; it cannot read, list, or modify existing files in Drive; passing a folderId not created by this app may return"not found", in which case the file will be uploaded to My Drive.
- Attachments are affected by Gmail's 25 MB encoding limit, so the actual file is about 18 MB, and files over the limit will be rejected in advance.
- Unsubscribe uses the sender's published unsubscribe method: when one-click unsubscribe (RFC 8058) is supported, it is completed automatically; when unsubscribe is only possible via email, the user is asked first; ordinary links are returned to the user to open themselves. It will not visit arbitrary URLs in emails, nor will it read sender response content.
- Changing the scope list invalidates existing credentials and requires reauthentication.
- More information about fees, pricing, platform support scope, etc. is not currently provided in the materials.