google-workspace-alias-mcp
A Model Context Protocol server for Google Workspace integration with send-as alias support, email templates, and scheduled send, enabling AI assistants to manage Gmail and Google Calendar through natural language.
README
Google Workspace Alias MCP
A Model Context Protocol (MCP) server for Google Workspace integration with send-as alias support, email templates, and scheduled send. This server enables AI assistants to manage Gmail and Google Calendar through natural language interactions.
Why google-workspace-alias-mcp?
- Unique: Only MCP with send-as alias support
- Unified: Gmail + Calendar in one package
- Full Featured: 28 tools with complete API coverage
✨ Why This MCP?
| Feature | This MCP | Gmail MCP (Original) |
|---|---|---|
| Send-As Alias Support | ✅ Dynamic discovery | ❌ Not supported |
| Email Templates | ✅ With variables | ❌ Not supported |
| Scheduled Send | ✅ Built-in | ❌ Not supported |
| Gmail + Calendar | ✅ Unified | ❌ Gmail only |
| Multi-Account | ✅ Planned | ❌ Not supported |
| Free/Busy Check | ✅ Built-in | ❌ Not supported |
🚀 Features
Gmail
- ✅ Send emails - with subject, content, attachments, and recipients
- ✅ Send-As Alias Support - dynamic discovery of all configured aliases
- ✅ Email templates - save and reuse templates with variables
- ✅ Scheduled send - schedule emails for later delivery
- ✅ Draft emails - create drafts without sending
- ✅ Read emails - get full email content with enhanced attachment display
- ✅ List emails - view inbox, sent, or custom labels
- ✅ Search emails - using Gmail search syntax
- ✅ Modify emails - mark read/unread, move to labels/folders
- ✅ Delete emails - permanent deletion
- ✅ Download attachments - save attachments to local filesystem
- ✅ Label management - create, update, delete labels
- ✅ Batch operations - process multiple emails efficiently
- ✅ Full attachment support - send and receive file attachments
- ✅ HTML emails - multipart messages with both HTML and plain text
- ✅ International characters - full support in subject and content
Google Calendar
- ✅ Create events - with title, time, description, location, attendees
- ✅ Get event - retrieve event details by ID
- ✅ List events - view events within specified time range
- ✅ Update events - modify existing events
- ✅ Delete events - remove events
- ✅ Search events - find events by query
- ✅ Free/Busy check - check availability across calendars
- ✅ Multi-calendar support - work with multiple calendars
- ✅ Recurring events - support for repeating events
📦 Installation
Using npm (Recommended)
npm install -g google-workspace-alias-mcp
Manual Installation
git clone https://github.com/johndelapena168/google-workspace-alias-mcp.git
cd google-workspace-mcp
npm install
⚙️ Setup
1. Create Google Cloud Project
- Go to Google Cloud Console
- Create a new project or select existing one
- Enable the following APIs:
- Gmail API
- Google Calendar API
2. Create OAuth 2.0 Credentials
- Go to "APIs & Services" > "Credentials"
- Click "Create Credentials" > "OAuth client ID"
- Select "Desktop app" as application type
- Give it a name (e.g., "Google Workspace MCP")
- Click "Create"
- Download the JSON file
- Rename it to
gcp-oauth.keys.json
3. Authenticate
Place your gcp-oauth.keys.json in one of these locations:
~/.google-workspace-mcp/(recommended)- Current directory
Then run:
npx google-workspace-alias-mcp auth
This will:
- Open your browser for Google authentication
- Ask for permission to access Gmail and Calendar
- Save credentials locally for future use
🔧 Configuration
Claude Desktop
Add to your Claude Desktop configuration (claude_desktop_config.json):
{
"mcpServers": {
"google-workspace": {
"command": "npx",
"args": ["google-workspace-alias-mcp"]
}
}
}
Cursor
Add to your Cursor settings:
{
"mcpServers": {
"google-workspace": {
"command": "npx",
"args": ["google-workspace-alias-mcp"]
}
}
}
Qoder
The MCP will be automatically detected when installed globally.
📖 Usage Examples
Send Email with Alias
{
"tool": "send_email",
"arguments": {
"to": ["client@example.com"],
"subject": "Project Update",
"body": "Hi,\n\nHere's the latest update on the project.\n\nBest regards",
"from": "hello@nexteraofai.com"
}
}
List Available Aliases
{
"tool": "list_aliases",
"arguments": {}
}
List Email Templates
{
"tool": "list_templates",
"arguments": {}
}
Send Email Using Template
{
"tool": "send_template_email",
"arguments": {
"template": "meeting-followup",
"to": ["client@example.com"],
"variables": {
"name": "John",
"meeting_name": "Project Review",
"summary": "Discussed project timeline and milestones",
"next_steps": "1. Finalize requirements\n2. Start development",
"sender_name": "John Dela Pena"
},
"from": "hello@nexteraofai.com"
}
}
Create Custom Template
{
"tool": "create_template",
"arguments": {
"name": "weekly-report",
"displayName": "Weekly Report",
"subject": "Weekly Report: {{week_date}}",
"body": "Hi {{name}},\n\nHere's the weekly report for {{week_date}}:\n\n{{report_content}}\n\nBest regards,\n{{sender_name}}"
}
}
Schedule Email for Later
{
"tool": "send_scheduled_email",
"arguments": {
"to": ["team@example.com"],
"subject": "Weekly Update",
"body": "Here's the weekly project update...",
"scheduledTime": "2026-07-15T09:00:00",
"from": "hello@nexteraofai.com"
}
}
Create Calendar Event
{
"tool": "create_event",
"arguments": {
"summary": "Project Kickoff Meeting",
"description": "Initial meeting to discuss project scope and timeline",
"location": "Zoom Meeting",
"start": "2026-07-15T14:00:00",
"end": "2026-07-15T15:00:00",
"attendees": ["john@example.com", "jane@example.com"],
"reminders": [
{ "method": "email", "minutes": 60 },
{ "method": "popup", "minutes": 10 }
]
}
}
Search Events
{
"tool": "search_events",
"arguments": {
"query": "meeting",
"timeMin": "2026-07-01T00:00:00Z",
"timeMax": "2026-07-31T23:59:59Z",
"maxResults": 20
}
}
Check Free/Busy
{
"tool": "get_freebusy",
"arguments": {
"timeMin": "2026-07-15T09:00:00Z",
"timeMax": "2026-07-15T17:00:00Z",
"calendars": ["primary", "work@example.com"]
}
}
Get Event by ID
{
"tool": "get_event",
"arguments": {
"calendarId": "primary",
"eventId": "abc123def456"
}
}
List Emails in Inbox
{
"tool": "list_emails",
"arguments": {
"labelIds": ["INBOX"],
"maxResults": 10
}
}
Mark Email as Read
{
"tool": "modify_email",
"arguments": {
"messageId": "18a1b2c3d4e5f6789",
"removeLabelIds": ["UNREAD"]
}
}
Move Email to Label
{
"tool": "modify_email",
"arguments": {
"messageId": "18a1b2c3d4e5f6789",
"addLabelIds": ["Label_123"],
"removeLabelIds": ["INBOX"]
}
}
Download Attachment
{
"tool": "download_attachment",
"arguments": {
"messageId": "18a1b2c3d4e5f6789",
"attachmentId": "ANGjdJ8z7_OQ",
"savePath": "C:/Users/Downloads"
}
}
Create New Label
{
"tool": "create_label",
"arguments": {
"name": "Client Projects",
"messageListVisibility": "show",
"labelListVisibility": "labelShow"
}
}
Batch Delete Emails
{
"tool": "batch_delete_emails",
"arguments": {
"messageIds": ["msg1", "msg2", "msg3"]
}
}
🎯 Unique Selling Points
1. Dynamic Alias Support
No other MCP server supports Gmail send-as aliases. This MCP automatically discovers all configured aliases and lets you send from any of them.
2. Email Templates
Save frequently used email templates with variables:
"Use meeting-followup template for {{name}}"
3. Scheduled Send
Schedule emails for later delivery:
{
"scheduledTime": "2026-07-15T09:00:00"
}
4. Unified Workspace
Gmail + Calendar in one MCP server. No need to install separate servers.
🔐 Security
- OAuth credentials are stored locally in
~/.google-workspace-mcp/ - Tokens are automatically refreshed when expired
- No data is sent to third-party servers
- Full control over permissions
🤝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Development Setup
git clone https://github.com/johndelapena168/google-workspace-alias-mcp.git
cd google-workspace-mcp
npm install
npm start
📝 License
MIT License - see LICENSE file
🙏 Acknowledgments
- Inspired by Gmail-MCP-Server by GongRzhe
- Built with Model Context Protocol SDK
- Uses Google APIs
📧 Contact
- GitHub: @johndelapena168
- Email: hello@nexteraofai.com
⭐ Support
If you find this MCP useful, please give it a star on GitHub!
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。