MCP.so
登录

Google Workspace MCP Server

@trymeuj

关于 Google Workspace MCP Server

暂无概览

基本信息

分类

沟通协作

许可证

MIT

运行时

node

传输方式

stdio

发布者

trymeuj

配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "gmail-mcp-server-3": {
      "command": "node",
      "args": [
        "get-refresh-token.js"
      ]
    }
  }
}

工具

未检测到工具

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is Google Workspace MCP Server?

It is a Model Context Protocol (MCP) server that provides tools for interacting with Gmail and Calendar APIs, enabling programmatic management of emails and calendar events through the MCP interface.

How to use Google Workspace MCP Server?

Clone the repository, run npm install, then set up OAuth 2.0 credentials via Google Cloud Console. Run node get-refresh-token.js to obtain a refresh token, configure the MCP settings file with environment variables (GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET, GOOGLE_REFRESH_TOKEN), build with npm run build, and then invoke tools through MCP.

Key features of Google Workspace MCP Server

  • List recent emails with optional filtering
  • Advanced email search using Gmail query syntax
  • Send emails with support for CC and BCC
  • Modify email labels (archive, trash, mark read/unread)
  • List upcoming calendar events with date range filtering
  • Create, update, and delete calendar events with attendees

Use cases of Google Workspace MCP Server

  • Automate retrieving unread emails from your inbox
  • Search for emails with attachments from specific senders
  • Send programmatic emails with CC and BCC recipients
  • Archive or mark emails read/unread in bulk
  • Schedule and manage calendar events with attendees

FAQ from Google Workspace MCP Server

What are the prerequisites for setting up Google Workspace MCP Server?

You need Node.js version 14 or higher, a Google Cloud Console project with the Gmail API and Google Calendar API enabled, and OAuth 2.0 credentials (client ID and secret) with http://localhost:4100/code as an authorized redirect URI.

How do I obtain a refresh token?

Run node get-refresh-token.js in the project root. This opens a browser for Google OAuth authentication, requests the required scopes, saves credentials to token.json, and displays the refresh token in the console.

What OAuth scopes does the server request?

It requests https://www.googleapis.com/auth/gmail.modify, https://www.googleapis.com/auth/calendar, and https://www.googleapis.com/auth/gmail.send.

How do I configure the MCP settings for the server?

Add an entry to the mcpServers object in your MCP settings file (VSCode Claude extension or Claude desktop app), specifying the command node, the path to build/index.js, and environment variables for your Google client ID, client secret, and refresh token.

What should I do if I encounter authentication errors?

Verify that all required OAuth scopes are granted, that your client ID and secret are correct, and that the refresh token is still valid. Also check the Google Cloud Console for API quotas and ensure the Gmail and Calendar APIs are enabled.

评论

沟通协作 分类下的更多 MCP 服务器