Gmail MCP Ae9454ab

MCP办公协作

提供方 bastienchabal · 包名 @smithery/cli

办公协作 stdio · 本地进程 OAuth 授权 社区 / 第三方 Claude DesktopClaude
查看接入方式

一个为Gmail和Google Calendar提供智能、上下文感知交互的模型上下文协议(MCP)服务器,集成于Claude Desktop中。

一句话选型结论

按资料字段整理

Gmail MCP Ae9454ab 属于办公协作类 MCP 服务器,stdio · 本地进程,OAuth 授权,可直接接入 Claude Desktop、Claude,有可直接复制的远程端点配置。接入前先确认权限范围;涉及写入、删除或付款的操作,建议先在测试环境验证。

分类办公协作 传输方式stdio · 本地进程 鉴权OAuth 授权 部署方式支持远程部署
GitHub 星标 0 仓库热度,无公开仓库时显示未标注
工具数 未标注 暴露给模型的工具数量
资源 / 提示词 0 / 0 资源与提示词模板数量
维护方 社区 / 第三方 核验等级 仅资料核对

工具与能力

办公协作
数量来自来源目录的标注,具体工具清单以官方文档为准
工具数量未标注暴露给模型可调用的工具个数
资源数量0可读取的资源条目
提示词数量0内置提示词模板数量

能力标签

支持客户端

适用场景

邮件分析Python本地部署智能回复日历集成上下文感知自然语言处理

安装与配置

stdio · 本地进程 OAuth 授权
客户端在本机拉起子进程,数据不出本机
npx -y @smithery/cli install @bastienchabal/gmail-mcp --client claude

这条命令只是入口,具体启动参数请按官方文档补齐,不要直接照搬到别的服务器。

  1. 1
    准备运行环境

    确认你的客户端支持远程端点,并拿到服务地址。

  2. 2
    安装服务

    复制上面的安装命令执行;命令里带占位符的位置,换成自己的密钥或路径。

  3. 3
    写入客户端配置

    在客户端的 MCP 配置里填好启动命令和参数,保存后完全退出客户端再打开,让新配置生效。

  4. 4
    验证是否可用

    连接成功后随便调一个只读工具,确认能返回结果,再接入正式流程。

典型使用场景

3 类
按分类与标签整理的常见用法,具体以官方文档为准
日程与消息

查日程、发消息、约会议。

表单与审批

填表单、走审批流。

团队协作

同步任务、汇总进展。

选择建议

选之前先看这几条
按条目字段给出的判断,不替你决定用不用

值得选的地方

  • 有现成的安装命令,不用自己找入口,照着跑就能起服务。
  • 已适配 Claude Desktop、Claude,换客户端不用重新研究配置。

先想清楚的地方

  • stdio 方式要求本地装好运行时(如 Node.js),换机器要重新装一遍。
  • 使用前要准备好OAuth 授权对应的凭据,并按最小权限配置。
  • 资料没标注工具数量,实际能力要装好后确认。
  • 版本更新与行为细节以官方仓库为准。

更适合

  • 需要在办公协作场景里让模型直接调用外部能力的人。
  • 已经在用 Claude Desktop、Claude 的用户,接入路径最短。
  • 想先快速试一下、能接受在本地或自有环境跑服务的人。

不太适合

  • 完全不想在本地装环境的人。
  • 不方便管理密钥或第三方授权的人。
  • 需要厂商级 SLA 和技术支持的生产环境。

同类对比

6 个同类
同分类里挑最接近的几条,字段以各自详情页为准
MCP 服务器工具数传输方式部署方式安装命令最后核验
Gmail MCP Ae9454ab当前 未标注 stdio · 本地进程 支持远程部署 有 2026-05-17
CowAgent 未标注 stdio · 本地进程 本地部署 有 2026-04-11
Karakeep MCP 未标注 未标注 未标注 无 2026-05-17
agentscope 未标注 stdio · 本地进程 本地部署 有 2026-04-11
note-gen 未标注 stdio · 本地进程 本地部署 有 2026-04-11
Everywhere 未标注 stdio · 本地进程 本地部署 有 2026-04-12

服务器档案

办公协作
字段来自项目仓库与公开索引,中文说明由本站标注
提供方bastienchabal上游标注的维护方 bastienchabal
分类办公协作本站按上游分类展示
连接方式stdio · 本地进程客户端在本机拉起子进程,数据不出本机
鉴权方式OAuth 授权远程服务建议用最小权限凭据
维护方社区 / 第三方核验等级 仅资料核对
包名 / 运行时@smithery/cli · Node.js本地安装时用到的包标识与运行时
部署类型支持远程部署上游给出的部署形态
最近核验2026-05-17上游最后核验时间

详细介绍

8.8 KB
来自项目仓库与上游目录的原文,未做删改

Gmail MCP Server

A Model Context Protocol (MCP) server for Gmail & Google Calendar integration with Claude Desktop, enabling intelligent, context-aware interactions with your email.

🌟 Features

  • Deep Email Analysis: Provides comprehensive context from entire conversation threads
  • Context-Aware Responses: Generates responses considering full communication history
  • Intelligent Action Suggestions: Analyzes email content for calendar events, tasks, and follow-ups
  • Calendar Integration: Detects events in emails and creates calendar entries with natural language support
  • Advanced Search: Searches across entire email history with semantic understanding
  • Personalization: Adapts to your communication style with specific contacts

🚀 Getting Started

Prerequisites

  • Python 3.10+
  • A Google Cloud Platform account with Gmail API and Google Calendar API (optional) enabled
  • OAuth 2.0 credentials for the Gmail API and Google Calendar API (optional)
  • Claude Desktop with MCP support (currently only LLM interface to support MCP)

Installation

Installing via Smithery

To install Gmail Integration Server for Claude Desktop automatically via Smithery:```bash
npx -y @smithery/cli install @bastienchabal/gmail-mcp --client claude


#### Installing Manually
1. Clone this repository:```bash
   git clone https://github.com/bastienchabal/gmail-mcp.git
   cd gmail-mcp
   ```

2. Set up a virtual environment using uv:```bash
   pip install uv
   uv venv
   source .venv/bin/activate  # On Windows: .venv\Scripts\activate
   ```

3. Install dependencies:```bash
   uv pip install -e .
   ```

## ⚙️ Configuration

### Step 1: Authenticate with Google

1. Go to the Google Cloud Console
2. Create a new project or select an existing one
3. Enable Google APIs:
   - Enable the Gmail API
   - Enable the Calendar API
4. Configure the OAuth consent screen:
   - Select "External" user type
   - Add your email as a test user
   - Add all the scopes of Gmail and Calendar
5. Create OAuth 2.0 credentials:
   - Choose "Desktop app" as the application type
   - Download the JSON credentials file and copy the Client ID and Client Secret

### Step 2: Configure Claude Desktop

1. Create or edit the `claude_desktop_config.json` file in `/Users//Library/Application Support/Claude`
2. Add the following configuration, replacing the placeholders with your actual values:```json
{
  "mcpServers": {
    "gmail-mcp": {
      "command": "/<absolute-path>/gmail-mcp/.venv/bin/mcp",
      "args": [
        "run",
        "/<absolute-path>/gmail-mcp/gmail_mcp/main.py:mcp"
      ],
      "cwd": "/<absolute-path>/gmail-mcp",
      "env": {
        "PYTHONPATH": "/<absolute-path>/gmail-mcp",
        "CONFIG_FILE_PATH": "/<absolute-path>/gmail-mcp/config.yaml",
        "GOOGLE_CLIENT_ID": "<your-client-id>",
        "GOOGLE_CLIENT_SECRET": "<your-client-secret>",
        "TOKEN_ENCRYPTION_KEY": "<generate-a-random-key>"
      }
    }
  }
}

Notes:
- Replace with the actual path to your gmail-mcp directory - Replace and ` with your Google OAuth credentials (previously generated in the json file) - Optional : Generate a random encryption key with:python -c "import os; from cryptography.fernet import Fernet; print(Fernet.generate_key().decode())"`

The configuration is designed to keep sensitive data (client ID, client secret, and encryption key) in the Claude Desktop configuration file, while non-sensitive settings are stored in the config.yaml file included in the repository.

Step 3: Use Claude Desktop

  1. Open Claude Desktop
  2. Type a prompt like: "Please retrieve my last email"
  3. Claude should automatically connect to the MCP server and ask you to authenticate to your Gmail account (creating the file tokens.json)

❓ Troubleshooting

Important Note on MCP

If Claude Desktop doesn't connect automatically (i.e. you do not see the tool icon underneath the prompt input), you can try:
- Restarting Claude Desktop
- Asking Claude to "Use the Gmail MCP server"
- Login to Gmail manually using one of these methods:

Important Note on Authentication

  1. Authentication Problems:
    - Run python debug/auth_test.py to test the authentication process with detailed feedback
    - Check that the token file exists at the project root
    - Verify that your Google Cloud Console project has the correct redirect URI configured
    - Make sure all required scopes are added to your OAuth consent screen
    - If you see "Scope has changed" errors, ensure that the openid scope is included in your OAuth consent screen
    - If you see "redirect_uri_mismatch" errors, add the exact URI shown in the error message to your authorized redirect URIs in Google Cloud Console
    - If the callback page doesn't load or process properly, check if port 8000 is already in use by another application

  2. Calendar API Issues:
    - Make sure you've enabled the Calendar API in Google Cloud Console
    - Check that you've granted all the necessary scopes during authentication
    - Run python debug/reauth_calendar.py to re-authenticate with Calendar API scopes
    - Verify that CALENDAR_API_ENABLED is set to true in your environment variables

Important Note on Calendar Integration

Calendar integration can be turned off in the configuration file. If you've previously authenticated with the Gmail MCP server and are now enabling Calendar integration, you'll need to re-authenticate to grant the additional Calendar API scopes. You can do this by:

  1. Deleting the existing tokens.json file (if present, either at projet root or in ~/Users/``gmail_mcp_tokens/tokens.json)
  2. Restarting the MCP server
  3. Following the authentication process again

👤 Usage

The Gmail MCP provides powerful, context-aware tools for managing your emails and calendar:

Email Management

  • Email Overview: Get a comprehensive view of your inbox with counts and recent emails
  • Advanced Search: Use Gmail's powerful search syntax to find specific emails
  • Detailed Email Analysis: View emails with full context, including thread history and sender information

Context-Aware Email Replies

  • Intelligent Reply Preparation: Analyze the full context of an email thread before replying
  • Communication Pattern Analysis: Understand your communication history with the sender
  • Personalized Drafting: Create draft replies that match your communication style with specific contacts
  • Entity Recognition: Identify important dates, times, action items, and other entities in emails
  • Related Email Context: Consider other relevant emails when crafting replies

Calendar Integration

  • Event Creation: Create calendar events with natural language time descriptions
  • Event Detection: Automatically detect potential events mentioned in emails
  • Calendar Management: View, search, and manage your upcoming calendar events
  • Smart Scheduling: Schedule meetings with appropriate context from email conversations

Example Requests

You can ask Claude to use these capabilities with natural language requests like:
- "Show me an overview of my inbox"
- "Find all unread emails from my boss about the quarterly report"
- "Help me reply to the last email from Sarah about the project deadline"
- "Create a calendar event for the team meeting mentioned in John's email"
- "What meetings do I have scheduled for next week?"
- "Analyze this email thread and help me understand the key points before I reply"
- "Draft a response to this email considering my previous communications with this person"

Available Resources

The MCP provides rich contextual resources that Claude can access:
- Email Context: Detailed information about specific emails
- Thread Context: Full conversation history for email threads
- Sender Context: Information about your relationship and communication history with senders
- Authentication Status: Current authentication state with Google
- Gmail Status: Overview of your Gmail account
- Server Information: Details about the MCP server configuration

Available Guides

The MCP includes several guides to help you get the most out of its capabilities:
- Quick Start Guide: Basic instructions for getting started
- Authentication Guide: Help with the authentication process
- Search Guide: Advanced Gmail search syntax reference
- Reply Guide: Best practices for context-aware email replies
- Debug Guide: Troubleshooting common issues

☑️ This MCP is configured so Claude will always ask you for confirmation before doing any important action, such as sending an email or creating a meeting.

⚠ Beta Notice

This MCP is a WIP and is currently in beta.

📝 License

This project is licensed under the MIT License.

💡 Acknowledgements

  • This project uses the Model Context Protocol (MCP) developed by Anthropic
  • Gmail API access is provided by Google's API services

常见问题

8 问
答案由本站依据条目字段整理,不引用上游原文
Gmail MCP Ae9454ab 怎么安装?

在客户端按下面的安装命令接入:npx -y @smithery/cli install @bastienchabal/gmail-mcp --client claude。对应的包名是 @smithery/cli。装完在客户端配置里引用同一个包或端点。

Gmail MCP Ae9454ab 怎么在 Claude Desktop、Claude 里配置?

它的传输方式是stdio · 本地进程,在客户端的 MCP 配置里填好启动命令和参数,保存后完全退出客户端再打开,配置才会生效。

Gmail MCP Ae9454ab 收费吗?

本站不代收费用,也没有标注具体价格。是否收费取决于服务本身和背后的接口额度,正式使用前按官方说明确认。

Gmail MCP Ae9454ab 需要 API Key 吗?

资料标注需要OAuth 授权认证,使用前准备好对应凭据,并按最小权限配置。

Gmail MCP Ae9454ab 支持哪些客户端?

资料标注支持 Claude Desktop、Claude;其他客户端只要能配置 MCP Server,也能用同样的命令或地址接入。

Gmail MCP Ae9454ab 能提供哪些能力?

资料显示能力标签包括 Python、Claude、上下文感知。具体工具清单以官方文档为准。

Gmail MCP Ae9454ab 需要什么运行环境?

运行时为 Node.js;属于本地进程,需要在本机装好运行环境。

Gmail MCP Ae9454ab 是本地还是远程?

它是本地进程(stdio),由客户端在本机拉起。传输方式为stdio · 本地进程。

热门专题

按标签挑服务器
全部专题 →

服务器信息以作者仓库与官方文档为准;分类、传输方式与鉴权方式的中文说明为中文整理,最近核验 2026-05-17。