@lkbaba/mcp-server-gemini
v1.2.4
Published
Specialized MCP server for Gemini 3.0 Pro focused on UI generation and frontend development
Downloads
444
Maintainers
Readme
Gemini MCP Server
Give Claude Code the power of Gemini 3.0
An MCP server that connects Claude Code to Google's Gemini 3.0, unlocking capabilities that complement Claude's strengths.
Why Gemini + Claude?
| Gemini's Strengths | Use Case | |-------------------|----------| | 1M Token Context | Analyze entire codebases in one shot | | Google Search Grounding | Get real-time documentation & latest info | | Multimodal Vision | Understand screenshots, diagrams, designs |
Philosophy: Claude is the commander, Gemini is the specialist.
Quick Start
1. Get API Key
Visit Google AI Studio and create an API key.
2. Configure Claude Code
Add to your MCP config file:
- Mac:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json - Linux:
~/.config/Claude/claude_desktop_config.json
{
"mcpServers": {
"gemini": {
"command": "npx",
"args": ["-y", "@lkbaba/mcp-server-gemini"],
"env": {
"GEMINI_API_KEY": "your_api_key_here"
}
}
}
}3. Restart Claude Code
Tools (5)
Research & Search
| Tool | Description |
|------|-------------|
| gemini_search | Web search with Google Search grounding. Get real-time info, latest docs, current events. |
Analysis (1M Token Context)
| Tool | Description |
|------|-------------|
| gemini_analyze_codebase | Analyze entire projects with 1M token context. Supports directory path, file paths, or direct content. |
| gemini_analyze_content | Analyze code, documents, or data. Supports file path or direct content input. |
Multimodal
| Tool | Description |
|------|-------------|
| gemini_multimodal_query | Analyze images with natural language. Understand designs, diagrams, screenshots. |
Creative
| Tool | Description |
|------|-------------|
| gemini_brainstorm | Generate creative ideas with project context. Supports reading README, PRD files. |
Model Selection (v1.2.0)
All tools now support an optional model parameter:
| Model | Speed | Best For |
|-------|-------|----------|
| gemini-3-pro-preview | Standard | Complex analysis, deep reasoning (default) |
| gemini-3-flash-preview | Fast | Simple tasks, quick responses |
Example: Use Flash for faster response
{
"name": "gemini_analyze_content",
"arguments": {
"filePath": "./src/index.ts",
"task": "review",
"model": "gemini-3-flash-preview"
}
}Usage Examples
Analyze a Large Codebase
"Use Gemini to analyze the ./src directory for architectural patterns and potential issues"Search for Latest Documentation
"Search for the latest Next.js 15 App Router documentation"Analyze an Image
"Analyze this architecture diagram and explain the data flow" (attach image)Brainstorm with Context
"Brainstorm feature ideas based on this project's README.md"Proxy Configuration
Add proxy environment variable to your config:
{
"mcpServers": {
"gemini": {
"command": "npx",
"args": ["-y", "@lkbaba/mcp-server-gemini"],
"env": {
"GEMINI_API_KEY": "your_api_key_here",
"HTTPS_PROXY": "http://127.0.0.1:7897"
}
}
}
}Local Development
git clone https://github.com/LKbaba/Gemini-mcp.git
cd Gemini-mcp
npm install
npm run build
export GEMINI_API_KEY="your_api_key_here"
npm startProject Structure
src/
├── config/
│ ├── models.ts # Model configurations
│ └── constants.ts # Global constants
├── tools/
│ ├── definitions.ts # MCP tool definitions
│ ├── multimodal-query.ts # Multimodal queries
│ ├── analyze-content.ts # Content analysis
│ ├── analyze-codebase.ts # Codebase analysis
│ ├── brainstorm.ts # Brainstorming
│ └── search.ts # Web search
├── utils/
│ ├── gemini-client.ts # Gemini API client
│ ├── file-reader.ts # File system access
│ ├── security.ts # Path validation
│ ├── validators.ts # Parameter validation
│ └── error-handler.ts # Error handling
├── types.ts # Type definitions
└── server.ts # Main serverCredits
Based on aliargun/mcp-server-gemini
License
MIT
