Gmail MCP - Instalación Automática y Segura
About
Acceso de asistentes de IA a Gmail mediante el Model Context Protocol (MCP)
Details
- Author
- FranciscoYuster
- Downloads
- 323
- Categories
- Communication, Automation
Jump to
- Automatic detection and placement of OAuth credentials
- One‑command installer for Windows, macOS, and Linux
- OAuth 2.0 authentication with Google Gmail API
- No credentials are uploaded or shared
- Requires Python 3.11 or higher
- Compatible with any MCP‑enabled AI assistant
Setting up with Highlight
This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:
- Download and install Highlight from highlightai.com/download
- Navigate to the plugins tab and select "Add Custom Plugin"
-
Configure the plugin with the settings below
Plugin Name
Gmail MCP - Instalación Automática y SeguraCommand (node, npx, python, etc.)Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.
- Enable "Start Automatically" if you want the plugin to start when Highlight launches
From the repository
Obtain a Gmail API OAuth client secret from Google Cloud Console (with redirect URI http://localhost:8080/), save it to your Downloads folder, then run the platform‑specific installer: python setup.py (Windows) or python3 setupUnix.py (macOS/Linux). For manual setup, clone the repo, create a virtual environment with uv, install dependencies, place the credentials file in a credentials/ directory, and add the MCP configuration to your client’s JSON.
Claude Desktop / Cursor
Paste into your MCP client config file to install this server.
{
"mcpServers": {
"gmail mcp - instalaci\u00f3n autom\u00e1tica y segura": {
"gmail-client-mcp-server": {
"command": "python",
"args": [
"setup.py"
]
}
}
}
}
McpServers
{
"gmail-client-mcp-server": {
"command": "python",
"args": [
"setup.py"
]
}
}
Gmail MCP - Instalación Automática y Segura
> Acceso de asistentes de IA a Gmail mediante el Model Context Protocol (MCP)
🧪 ¿Qué es MCP?
MCP (Model Context Protocol) es un protocolo de integración desarrollado por Antrophic para facilitar la comunicación entre modelos de lenguaje (como ChatGPT o Claude) y herramientas externas (APIs, bases de datos, servicios web, etc.). Su objetivo es proporcionar un contexto ampliado, estructurado y en tiempo real a los modelos, permitiéndoles ejecutar acciones más allá del texto.
---
🚀 Instalación rápida (Windows)
1. Primero:
- Ve a Google Cloud Console
- Crea un proyecto y habilita la API de Gmail
- Agrega http://localhost:8080/ a las URIs de redireccionamiento autorizados
- Descarga el archivo client_secret_...json y déjalo en tu carpeta Descargas (no te preocupes por el nombre ni la ubicación final)
- El instalador detectará y moverá el archivo automáticamente a la carpeta correcta y con el nombre adecuado
> [!IMPORTANT]
> Solo necesitas descargar el archivo de credenciales desde Google Cloud despues configurar las URIs de redireccionamiento autorizados y dejarlo en Descargas. ¡No te preocupes por el nombre ni la ubicación final, el instalador se encarga de todo!
2. Clona este repositorio desde tu terminal:
git clone https://github.com/FranciscoYuster/gmail-client-mcp-server
cd gmail-client-mcp-server
3. Y ejecuta el script:
python setup.py
4. El instalador hará el resto
5. Cuando veas el mensaje final, ¡abre Claude Desktop y disfruta!
---
💻 Instalación en macOS / Linux
1. Sigue los mismos pasos de Google Cloud indicados arriba para obtener tu archivo de credenciales y dejarlo en Descargas.
2. Clona este repositorio desde tu terminal:
git clone https://github.com/FranciscoYuster/gmail-client-mcp-server
cd gmail-client-mcp-server
3. Ejecuta el script para sistemas Unix:
python3 setupUnix.py
4. El instalador hará el resto.
5. Cuando veas el mensaje final, ¡abre Claude Desktop y disfruta!
---
> [!IMPORTANT]
> Si usas Windows, ejecuta: python setup.py
> Si usas macOS o Linux, ejecuta: python3 setupUnix.py
> Ambos scripts ejecutan la instalación, pero cada uno está adaptado a su sistema operativo.
---
🔒 Seguridad
> [!WARNING]
> Nunca subas ni compartas tu archivo de credenciales. Si lo expones por error, elimínalo y genera uno nuevo en Google Cloud Console. El script nunca sube ni distribuye tus datos sensibles.
---
📝 Requisitos previos
- Python 3.11 o superior
- git
- Cuenta de Gmail
> [!TIP]
> El instalador te guiará para instalar cualquier requisito que falte.
---
⚙️ Configuración manual
🚀 Configuración
1. Clona este repositorio:
git clone https://github.com/FranciscoYuster/mcp-server-client-gmail
cd mcp-server-client-gmail
2. Crea y activa un entorno virtual:
uv init
# o alternativamente
uv venv
Luego actívalo:
.venv\scripts\activate
3. Instala dependencias:
uv pip install -r requirements.txt
4. Configura credenciales OAuth:
- Crea un directorio llamado
credentials en la raíz del proyecto- Crea un proyecto en Google Cloud Console
- Habilita la API de Gmail
- Crea credenciales OAuth
- Agrega la siguiente URI a las URIs de redirección autorizadas:
http://localhost:8080/
- Descarga el archivo JSON de credenciales y guárdalo como
credentials/client_secret_gmail_oauth.json
> [!CAUTION]
> Asegúrate de que la ruta y el nombre del archivo de credenciales sean correctos para evitar errores de autenticación.
5. Agrega el servidor MCP a tu configuración JSON. Por favor, consulta la documentación oficial de tu cliente MCP para instrucciones específicas. Asegúrate de ajustar la ruta según tu entorno:
{
"mcpServers": {
"gmail-mcp": {
"command": "uv",
"args": [
"--directory",
"/path/to/your/gmail-mcp/src",
"run",
"main.py"
]
}
}
}
6. Ejecuta Claude Desktop
---
📝 Licencia
MIT. Consulta el archivo LICENSE.
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.


