fastmcp-gsuite
MCP server for Gmail, Google Calendar, and Google Drive integration using fastmcp. Supports multiple accounts, email management, calendar events, and file operations.
claude mcp add --transport stdio tumf-fastmcp-gsuite uvx fastmcp-gsuite
How to use
fastmcp-gsuite is an MCP server that bridges Google Workspace (Gmail and Google Calendar) with the MCP protocol, allowing you to manage and interact with your Google accounts through MCP prompts. It supports multiple Google accounts and exposes capabilities to query emails (including search by sender, date ranges, unread status, and attachments), retrieve full email content by ID, create and manage drafts, delete drafts, and compose and send (or store as drafts) replies. For Calendar, you can manage multiple calendars, fetch events within time ranges, create events with titles, times, locations, descriptions, attendees, time zones, and notification preferences, and delete events. The server is implemented using the fastmcp library and is a fork of the original mcp-gsuite project, updated to integrate with the fastmcp framework and modern configuration approaches.
To use the server, run it through the MCP launcher (via uv/uvx as shown in the config). The server relies on OAuth2 credentials for Google APIs. Configuration is now primarily driven by environment variables or a .env file, including paths to OAuth configuration, accounts, and credential storage. You can authenticate through an interactive setup workflow or use manual setup guided by the README. After setup, the server will expose prompts and tools for Gmail and Calendar operations that you can invoke via the MCP interface, such as retrieving unread messages, listing calendar events, creating drafts, or scheduling events.
How to install
Prerequisites:
- Python 3.8+ (or compatible runtime)
- pip and/or uv/uvx installed
- Access to Google Cloud Console for OAuth2 credentials (desktop app) and consent screen configured for Gmail, Calendar, and Drive APIs
Installation steps (recommended):
-
Install the package (Python) with interactive setup support: uv install fastmcp-gsuite or if using standard pip-based setup: pip install fastmcp-gsuite
-
Run the interactive setup to configure OAuth and accounts: uv run fastmcp-gsuite-setup
-
Follow prompts to authenticate Google accounts and generate the required configuration files (.gauth.json and .accounts.json). You can add accounts or list/remove them via the setup utility: uv run fastmcp-gsuite-setup --add-account uv run fastmcp-gsuite-setup --list uv run fastmcp-gsuite-setup --remove-account user@example.com
-
Run the server (as published, via the MCP launcher): uvx fastmcp-gsuite
Optional manual setup (advanced):
- Create .gauth.json with your OAuth client details as shown in the README
- Create .accounts.json with your Google account entries
- Export environment variables or use a .env file to point to these config files (GAUTH_FILE, ACCOUNTS_FILE, CREDENTIALS_DIR)
Notes:
- The setup wizard will guide you through authorizing Google accounts and generating credentials in your working directory.
- After initial setup, you can rely on environment variables or a .env file for configuration, rather than command-line arguments.
Additional notes
Configuration is primarily handled via environment variables or a .env file in the working directory. Key variables include:
- GAUTH_FILE: Path to the .gauth.json containing OAuth client configuration (default: ./ .gauth.json)
- ACCOUNTS_FILE: Path to the .accounts.json containing Google account information (default: ./ .accounts.json)
- CREDENTIALS_DIR: Directory to store generated .oauth2.{email}.json credentials (default: .)
Common issues and tips:
- If you encounter "No refresh token received" during setup, revoke the app’s access in Google Account permissions and re-run the setup.
- If the browser doesn’t open automatically during interactive setup, ensure popups are allowed or run the setup again.
- Ensure your Google Cloud project has Gmail API, Calendar API, and Drive API enabled and that OAuth2 client IDs are configured for Desktop/Installed applications.
- For multiple accounts, leverage the accounts.json structure to keep track of each account’s metadata and use the setup utilities to manage them.
Related MCP Servers
pfsense
pfSense MCP Server enables security administrators to manage their pfSense firewalls using natural language through AI assistants like Claude Desktop. Simply ask "Show me blocked IPs" or "Run a PCI compliance check" instead of navigating complex interfaces. Supports REST/XML-RPC/SSH connections, and includes built-in complian
mcp-kubernetes
A Model Context Protocol (MCP) server that enables AI assistants to interact with Kubernetes clusters. It serves as a bridge between AI tools (like Claude, Cursor, and GitHub Copilot) and Kubernetes, translating natural language requests into Kubernetes operations and returning the results in a format the AI tools can understand.
davinci -professional
An enterprise-grade MCP server that exposes the full functionality of DaVinci Resolve and DaVinci Resolve Studio (through version 20) to either Claude Desktop or Cursor MCP clients. Fully configured and tested as a Claude Desktop Extension making installation as easy as clicking a button. Supports both Windows and Macintosh.
mycobot
myCobot MCP(Model Context Protocol) server
mediawiki-api
A Model Context Protocol (MCP) server that allows LLMs to interact with MediaWiki installations through the MediaWiki API as a bot user.
local-process-intelligence
Local Process Intelligence MCP-Server for monitoring your system