Skip to main content
Glama

📬 Claude 桌面版 EmailAssistant

EmailAssistant 是一款兼容 MCP 的服务器,它集成了 Gmail API,可以根据自定义查询或近期活动来获取和汇总电子邮件。它可以与 Claude Desktop 配合使用,轻松与收件箱进行交互。


⚙️ 设置说明

1. 启用 Gmail API

  1. 转到Google Cloud Console 。

  2. 创建新项目或使用现有项目。

  3. 在“API 和服务”下启用Gmail API 。

  4. 创建OAuth 2.0 客户端 ID凭证。

  5. 下载client_secret_XXXXX.json文件。


Related MCP server: Gmail Plugin MCP Server

🔧 配置摘要

🔁 在config.py中替换这些

  • 将/absolute/path/to/your/project替换为您本地 EmailAssistant 项目目录的完整路径。

  • 将"your_client_secret_file.json"替换为您从 Google Cloud 下载的 OAuth 凭据的确切文件名。


🖥️ 3. Claude 桌面配置

在您的 Claude Desktop 配置文件中:

{
  "mcpServers": {
    "EmailAssistant": {
      "command": "uv",
      "args": [
        "run",
        "--with",
        "mcp[cli]",
        "--with",
        "google-api-python-client",
        "--with",
        "google-auth-httplib2",
        "--with",
        "google-auth-oauthlib",
        "mcp",
        "run",
        "/absolute/path/to/your/project/MCPEmailAssistant/main.py"
      ]
    }
  }
}

✅ 运行它

配置完成后:

  1. 启动 Claude Desktop

  2. Claude 将自动识别EmailAssistant MCP 服务器。

  3. 您现在可以使用 Claude 调用如下函数:

get_email_summary(time="newer_than:1d")
get_top_matching_email(query_keywords="project deadline")

📌 要求

  • Python 3.9+

  • uv (如果不使用uv则使用pip )

  • 以下 Python 包:

    • google-api-python-client

    • google-auth-httplib2

    • google-auth-oauthlib

    • mcp[cli]

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    An MCP server that enables Gmail integration, allowing users to manage emails (send, receive, read, trash, mark as read) directly through MCP clients like Claude Desktop.
    1
    MIT
  • F
    license
    Not graded
    quality
    D
    maintenance
    This MCP server provides a natural language interface to the Gmail API, allowing users to interact with Gmail functionality (like emails, threads, labels, etc.) through the Model Context Protocol.
    -
  • 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