Gemini Image Generation MCP
Provides image generation capabilities via the Google Gemini API, enabling Claude to produce images from text prompts.
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., "@Gemini Image Generation MCPgenerate an image of a cat wearing a top hat"
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.
Conector MCP — Generación de imágenes con Gemini
Servidor MCP remoto en Node.js/TypeScript que expone la herramienta generate_image para que Claude (claude.ai) genere imágenes usando la API de Google Gemini.
Requisitos
API key de Google AI Studio: crea una gratis en https://aistudio.google.com/apikey
Node.js 20+ (para probar en local)
Una cuenta de hosting que soporte Node.js: Render, Railway, Fly.io o Google Cloud Run. Render tiene plan gratuito y es el más sencillo.
Related MCP server: Nano Banana MCP
Prueba en local
npm install
cp .env.example .env # edita .env con tu API key
npm run devEl endpoint queda en http://localhost:3000/mcp/TU_SECRETO (POST). Verifica salud en http://localhost:3000/health.
Puedes probarlo con MCP Inspector:
npx @modelcontextprotocol/inspector
# Transport: Streamable HTTP
# URL: http://localhost:3000/mcp/TU_SECRETODespliegue en Render (gratis)
Sube este proyecto a un repositorio de GitHub.
En https://render.com crea un Web Service apuntando al repo.
Configuración:
Build command:
npm install && npm run buildStart command:
npm startEnvironment variables:
GEMINI_API_KEY= tu key de AI StudioMCP_SECRET= un texto aleatorio largo (ej. genera uno conopenssl rand -hex 12)
Render te da una URL tipo
https://gemini-mcp-xxxx.onrender.com.
Tu endpoint MCP final será:
https://gemini-mcp-xxxx.onrender.com/mcp/TU_SECRETONota: en el plan gratuito de Render el servicio "duerme" tras 15 min de inactividad; la primera petición puede tardar ~30-50 segundos en despertar.
Conectar en claude.ai
Ve a Configuración → Conectores (Settings → Connectors).
Clic en Agregar conector personalizado (Add custom connector).
Nombre:
Gemini Imágenes— URL: tu endpoint MCP completo (con el secreto).Guarda. Al iniciar un chat, activa el conector en el menú de herramientas.
Pídele a Claude: "Genera una imagen de un paisaje cafetero de Ebéjico al atardecer" — Claude llamará a
generate_imagey te mostrará el resultado.
Seguridad
El
MCP_SECRETen la ruta evita que cualquiera que descubra tu dominio consuma tu cuota de la API de Gemini. No lo compartas ni lo subas a GitHub (usa variables de entorno).La API key de Gemini nunca sale del servidor; Claude solo ve la herramienta.
Si sospechas que el secreto se filtró, cámbialo en las variables de entorno y actualiza la URL del conector.
Cambiar de modelo
Por defecto usa gemini-2.0-flash-preview-image-generation. Si Google publica un modelo nuevo (o quieres usar Imagen), cambia la variable GEMINI_IMAGE_MODEL. Verifica los modelos disponibles para tu key en https://ai.google.dev/gemini-api/docs/models
Estructura
gemini-mcp/
├── src/index.ts # Servidor Express + MCP + llamada a Gemini
├── package.json
├── tsconfig.json
└── .env.exampleThis server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- 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/Yamidor/gemini-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server