U

Ultimate Image Gen MCP

by nikships · io.github.nikships/ultimate-image-gen-mcp

MCP server for Google's Gemini 3.1 Flash Image that enables fast, high-resolution image generation with advanced reasoning, up to 14 reference images, Google Search grounding, and automatic thinking mode.

pypi Local · stdio GlamaOfficial MCP Registry High confidence

Install

Add to ~/Library/Application Support/Claude/claude_desktop_config.json

Windows / Linux path
Windows: %APPDATA%\Claude\claude_desktop_config.json
Linux: ~/.config/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "io-github-nikships-ultimate-image-gen-mcp": {
      "command": "uvx",
      "args": [
        "ultimate-gemini-mcp"
      ],
      "env": {
        "GEMINI_API_KEY": "<YOUR_VALUE>",
        "OUTPUT_DIR": "~/gemini_images",
        "DEFAULT_IMAGE_SIZE": "2K",
        "DEFAULT_MODEL": "gemini-3-pro-image-preview",
        "ENABLE_PROMPT_ENHANCEMENT": "false",
        "ENABLE_GOOGLE_SEARCH": "false",
        "REQUEST_TIMEOUT": "60",
        "MAX_BATCH_SIZE": "8",
        "LOG_LEVEL": "INFO"
      }
    }
  }
}

Restart Claude Desktop to activate the new server.

Add to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)

Windows / Linux path
Windows: .cursor\mcp.json (project) or %USERPROFILE%\.cursor\mcp.json (global)
Linux: .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)
{
  "mcpServers": {
    "io-github-nikships-ultimate-image-gen-mcp": {
      "command": "uvx",
      "args": [
        "ultimate-gemini-mcp"
      ],
      "env": {
        "GEMINI_API_KEY": "<YOUR_VALUE>",
        "OUTPUT_DIR": "~/gemini_images",
        "DEFAULT_IMAGE_SIZE": "2K",
        "DEFAULT_MODEL": "gemini-3-pro-image-preview",
        "ENABLE_PROMPT_ENHANCEMENT": "false",
        "ENABLE_GOOGLE_SEARCH": "false",
        "REQUEST_TIMEOUT": "60",
        "MAX_BATCH_SIZE": "8",
        "LOG_LEVEL": "INFO"
      }
    }
  }
}

Cursor usually picks up config changes automatically; if the server does not appear, reload the window.

Add to .mcp.json (project) or ~/.claude.json (global)

Windows / Linux path
Windows: .mcp.json (project) or %USERPROFILE%\.claude.json (global)
Linux: .mcp.json (project) or ~/.claude.json (global)
{
  "mcpServers": {
    "io-github-nikships-ultimate-image-gen-mcp": {
      "command": "uvx",
      "args": [
        "ultimate-gemini-mcp"
      ],
      "env": {
        "GEMINI_API_KEY": "<YOUR_VALUE>",
        "OUTPUT_DIR": "~/gemini_images",
        "DEFAULT_IMAGE_SIZE": "2K",
        "DEFAULT_MODEL": "gemini-3-pro-image-preview",
        "ENABLE_PROMPT_ENHANCEMENT": "false",
        "ENABLE_GOOGLE_SEARCH": "false",
        "REQUEST_TIMEOUT": "60",
        "MAX_BATCH_SIZE": "8",
        "LOG_LEVEL": "INFO"
      }
    }
  }
}

The server will be available in the next Claude Code session.

Add to .vscode/mcp.json

Windows / Linux path
Windows: .vscode\mcp.json
Linux: .vscode/mcp.json
{
  "servers": {
    "io-github-nikships-ultimate-image-gen-mcp": {
      "command": "uvx",
      "args": [
        "ultimate-gemini-mcp"
      ],
      "env": {
        "GEMINI_API_KEY": "<YOUR_VALUE>",
        "OUTPUT_DIR": "~/gemini_images",
        "DEFAULT_IMAGE_SIZE": "2K",
        "DEFAULT_MODEL": "gemini-3-pro-image-preview",
        "ENABLE_PROMPT_ENHANCEMENT": "false",
        "ENABLE_GOOGLE_SEARCH": "false",
        "REQUEST_TIMEOUT": "60",
        "MAX_BATCH_SIZE": "8",
        "LOG_LEVEL": "INFO"
      }
    }
  }
}

Reload the VS Code window to activate.

Add to ~/.codeium/windsurf/mcp_config.json

Windows / Linux path
Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json
Linux: ~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "io-github-nikships-ultimate-image-gen-mcp": {
      "command": "uvx",
      "args": [
        "ultimate-gemini-mcp"
      ],
      "env": {
        "GEMINI_API_KEY": "<YOUR_VALUE>",
        "OUTPUT_DIR": "~/gemini_images",
        "DEFAULT_IMAGE_SIZE": "2K",
        "DEFAULT_MODEL": "gemini-3-pro-image-preview",
        "ENABLE_PROMPT_ENHANCEMENT": "false",
        "ENABLE_GOOGLE_SEARCH": "false",
        "REQUEST_TIMEOUT": "60",
        "MAX_BATCH_SIZE": "8",
        "LOG_LEVEL": "INFO"
      }
    }
  }
}

Restart Windsurf (or refresh its MCP servers panel) to activate the new server.

Windsurf Next uses ~/.codeium/windsurf-next/mcp_config.json. Devin Desktop (the Windsurf rebrand) uses ~/.config/devin/mcp_config.json and imports the Windsurf file.

Add to ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json

Windows / Linux path
Windows: %APPDATA%\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json
Linux: ~/.config/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
{
  "mcpServers": {
    "io-github-nikships-ultimate-image-gen-mcp": {
      "command": "uvx",
      "args": [
        "ultimate-gemini-mcp"
      ],
      "env": {
        "GEMINI_API_KEY": "<YOUR_VALUE>",
        "OUTPUT_DIR": "~/gemini_images",
        "DEFAULT_IMAGE_SIZE": "2K",
        "DEFAULT_MODEL": "gemini-3-pro-image-preview",
        "ENABLE_PROMPT_ENHANCEMENT": "false",
        "ENABLE_GOOGLE_SEARCH": "false",
        "REQUEST_TIMEOUT": "60",
        "MAX_BATCH_SIZE": "8",
        "LOG_LEVEL": "INFO"
      }
    }
  }
}

Cline reloads cline_mcp_settings.json automatically; if the server does not appear, reload the VS Code window.

Open it from Cline's MCP Servers panel → Configure. Roo Code uses a different file and format.

Configuration

Environment variables this server reads. Secrets stay on your machine.

NameRequiredDescription
GEMINI_API_KEY secret Yes Required. Google Gemini API key.
OUTPUT_DIR No Directory where images are saved. Default: ~/gemini_images
DEFAULT_IMAGE_SIZE No Default resolution (1K, 2K, 4K). Default: 2K
DEFAULT_MODEL No Default model. Default: gemini-3-pro-image-preview
ENABLE_PROMPT_ENHANCEMENT No Auto-enhance prompts by default. Default: false
ENABLE_GOOGLE_SEARCH No Enable Google Search grounding by default. Default: false
REQUEST_TIMEOUT No API timeout in seconds. Default: 60
MAX_BATCH_SIZE No Max parallel requests in batch mode. Default: 8
LOG_LEVEL No Logging level. Default: INFO

Similar servers