Integrations
Enables email management including sending, receiving, reading, trashing emails, marking emails as read, and opening emails in browser through Gmail's API with OAuth2 authentication.
Gmail Plugin MCP Server
A powerful MCP server that enables Gmail integration, allowing you to manage emails directly through MCP clients. This plugin provides seamless access to Gmail's core functionality including reading, sending, and managing emails.
Reference: For a sample MCP server implementation using uvx, check out this example.
🎥 Demo
https://github.com/user-attachments/assets/df9e86cf-1f6b-4265-9c68-b3ed88103d1f
✨ Features
- 📧 Send and receive emails
- 📥 Read unread messages
- 🗑️ Trash emails
- 📱 Open emails in browser
- 📝 Mark emails as read
- 🔒 Secure OAuth2 authentication
🚀 Quick Start
Prerequisites
- Python 3.12 or higher
- Gmail API credentials
- MCP client (like Claude Desktop)
Installation
- Clone the repository:
- Install dependencies (choose one method):
- Configure your Gmail API credentials:
- Go to Google Cloud Console
- Create a new project or select existing one
- Enable Gmail API
- Configure OAuth consent screen:
- Select "External" user type (no publishing required)
- Go to the Audiences tab : Add your email as a "Test user"
- Add OAuth scope:
https://www.googleapis.com/auth/gmail/modify
- Create OAuth 2.0 credentials:
- Choose "Desktop App" as application type
- Download the JSON credentials file
- Save the credentials file and note its absolute path (will be used for
--creds-file-path
)
Configuration
For Development/Unpublished Servers
Add this to your MCP client configuration:
For Published Servers
🛠️ Development
Building and Publishing
- Sync dependencies:
- Build package:
- Publish to PyPI:
Debugging
Use the MCP Inspector for debugging:
📚 API Reference
Available Tools
Tool Name | Description | Required Arguments |
---|---|---|
send-email | Send an email | recipient_id, subject, message |
get-unread-emails | Retrieve unread emails | None |
read-email | Read email content | email_id |
trash-email | Move email to trash | email_id |
mark-email-as-read | Mark email as read | email_id |
open-email | Open email in browser | email_id |
Available Prompts
Prompt Name | Description | Arguments |
---|---|---|
manage-email | Act as email administrator | None |
draft-email | Draft a new email | content, recipient, recipient_email |
edit-draft | Edit existing email draft | changes, current_draft |
🤝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
This server cannot be installed
local-only server
The server can only run on the client's local machine because it depends on local resources.
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.
Related MCP Servers
- AsecurityAlicenseAqualityModel Context Protocol server for Gmail integration. This allows Claude Desktop (or any MCP client) to interact with your Gmail account through Google Apps Script.Last updated -378JavaScriptMIT License
- -securityAlicense-qualityIntegrates with Gmail to enable sending, reading, drafting, and managing emails via the Model Context Protocol (MCP), allowing users to interact with email tasks through automated client prompts.Last updated -PythonGPL 3.0
- -securityFlicense-qualityEnables users to manage Gmail accounts using AI agent-assisted operations via an MCP protocol, supporting email search, reading, deletion, and sending with a voice-powered interface.Last updated -25TypeScript
- AsecurityFlicenseAqualityA simple MCP server that enables users to send emails using Resend's API, integrating with tools like Cursor and Claude Desktop for seamless email composition and delivery.Last updated -16321TypeScript