Gmail Guardian
Provides intelligent email management for Gmail, including classifying unread emails, organizing newsletters, archiving promotional emails in bulk, generating briefings with action points and deadlines, suggesting automatic filters, drafting responses to pending emails, and maintaining a full audit log with rollback support.
Uses Google APIs (via OAuth2 credentials) to interact with Gmail, enabling the server to read, archive, and manage emails through Google's services.
Requires Google Cloud Console credentials for OAuth2 authentication to access Gmail's API.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Gmail Guardiantriage my unread emails from today"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Gmail Guardian
Intelligent agent for Gmail management, built with Claude (Anthropic SDK) and integrated via MCP server.
Features
Skill | Description |
| Classifies unread emails by category and priority |
| Identifies and organizes newsletters by topic |
| Archives promotional emails in bulk with safeguards |
| Generates briefings with action items and deadlines |
| Analyzes patterns and creates automatic filters |
| Generates response drafts for pending emails |
| Complete action log with rollback support |
Related MCP server: Gmail MCP Server
Prerequisites
Python 3.11+
Google account with Gmail
Anthropic API key
OAuth2 credentials from Google Cloud Console
Installation
# 1. Instalar dependências
pip install -r requirements.txt
# 2. Configurar variáveis de ambiente
cp .env.example .env
# Editar .env com suas chaves
# 3. Baixar credentials.json do Google Cloud Console
# (APIs & Services > Credentials > OAuth 2.0 Client IDs)
# Salvar em config/credentials.jsonUsage
Interactive mode (REPL)
python run.pyGmail Guardian — Agente de gerenciamento de emails
Digite 'sair' para encerrar | 'log' para ver auditoria
Você: triar meus emails não lidos
Agente: Buscando emails não lidos...As MCP Server (Claude Code)
python run.py --mcpAdd to your ~/.claude/settings.json:
{
"mcpServers": {
"gmail": {
"command": "python",
"args": ["/caminho/para/email-guardian/run.py", "--mcp"],
"env": {
"ANTHROPIC_API_KEY": "sk-ant-...",
"GOOGLE_CREDENTIALS_PATH": "/caminho/para/credentials.json"
}
}
}
}Then use in Claude Code:
/triagem-email
/limpar-promocoes
/resumir-importantesProject Structure
email-guardian/
├── .claude/ # Configuração do agente e skills para Claude Code
│ ├── agents/ # Definição do agente gmail-guardian
│ └── skills/ # Skills invocáveis via /skill-name
├── agent/ # Orquestração do agente (Anthropic SDK)
├── gmail_mcp/ # MCP Server + ferramentas Gmail
│ ├── services/ # Wrappers da Gmail API
│ ├── tools/ # Implementação das ferramentas MCP
│ └── schemas/ # Dataclasses para tipagem
├── config/ # Settings, políticas e categorias
├── tests/ # Testes unitários
├── .env.example # Template de variáveis de ambiente
├── requirements.txt
└── run.py # Entry pointSecurity
Never permanently deletes emails without explicit confirmation
Automatically preserves order confirmations and invoices
All actions are logged in the audit log
Support for
DRY_RUN=trueto simulate without modifying
Tests
pytest tests/ -vThis server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityDmaintenanceEnables AI assistants to manage Gmail by reading unread emails with automatic classification, creating AI-generated draft replies, and saving drafts directly to Gmail through the Gmail API.192MIT
- Alicense-qualityFmaintenanceProvides comprehensive Gmail integration with 25+ tools for intelligent email management, including AI-powered categorization, advanced search and filtering, automated archiving and cleanup, analytics, and secure OAuth2 authentication.1922MIT
- Alicense-quality-maintenanceEnables AI agents to interact with Gmail for classifying messages, extracting action items, and performing batch inbox triage. It supports automated labeling, smart replies, and task creation for external platforms like Linear, Jira, and Todoist.
- Flicense-qualityDmaintenanceEnables AI-powered email management through Gmail, including search, send, drafts, labels, and an intelligent agent with human approval workflow and optional customer database integration.
Related MCP Connectors
Manage Gmail end-to-end: search, read, send, draft, label, and organize threads. Automate workflow…
Manage Gmail messages, threads, labels, drafts, and settings from your workflows. Send and organiz…
Governed email for AI agents (Mailbuttons / mbag.ai): sandbox inboxes, policy gate, audit log.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/wyller/mcp-email-guardian'
If you have feedback or need assistance with the MCP directory API, please join our Discord server