Skip to main content
Glama
INDEX.mdβ€’7.67 kB
# Nano Banana MCP Server - Documentation Index **Version:** 0.1.4 **Status:** Production Ready **Package:** `nanobanana-mcp-server` A production-ready Model Context Protocol (MCP) server for AI-powered image generation using Google's Gemini 2.5 Flash Image model. ## πŸ“‹ Quick Navigation ### πŸš€ Getting Started - **[README.md](../README.md)** - Installation and client configuration - **[CLAUDE.md](../CLAUDE.md)** - Claude Code development guidance ### πŸ“š Core Documentation - **[API Specification](API_SPECIFICATION.md)** - Complete API reference - **[System Design](SYSTEM_DESIGN.md)** - Architecture and design patterns - **[Component Design](COMPONENT_DESIGN.md)** - Detailed component documentation ### πŸ”§ Development - **[Implementation Plan](IMPLEMENTATION_PLAN.md)** - Development roadmap and milestones - **[FastMCP Skeleton](fastmcp-skeleton.md)** - FastMCP integration guide - **[Workflows](workflows.md)** - Development workflows and processes ### πŸ“¦ Publishing - **[Publishing Workflow](PUBLISHING_WORKFLOW.md)** - Complete publishing guide - **[PyPI Upload Guide](PYPI_UPLOAD_GUIDE.md)** - PyPI deployment instructions ## πŸ—οΈ Project Structure ### Package Layout ``` nanobanana_mcp_server/ β”œβ”€β”€ __init__.py # Package entry point (v0.1.4) β”œβ”€β”€ server.py # Main server implementation β”œβ”€β”€ config/ # Configuration management β”‚ β”œβ”€β”€ settings.py # Server and API settings β”‚ └── constants.py # Application constants β”œβ”€β”€ core/ # Core functionality β”‚ β”œβ”€β”€ server.py # FastMCP server setup β”‚ β”œβ”€β”€ exceptions.py # Custom exceptions β”‚ β”œβ”€β”€ validation.py # Input validation β”‚ └── progress_tracker.py # Progress tracking β”œβ”€β”€ services/ # Business logic services β”‚ β”œβ”€β”€ __init__.py # Service registry β”‚ β”œβ”€β”€ gemini_client.py # Gemini API wrapper β”‚ β”œβ”€β”€ *_image_service.py # Image processing services β”‚ β”œβ”€β”€ file_service.py # File management β”‚ └── maintenance_service.py # System maintenance β”œβ”€β”€ tools/ # MCP tools implementation β”‚ β”œβ”€β”€ generate_image.py # Image generation tool β”‚ β”œβ”€β”€ upload_file.py # File upload tool β”‚ β”œβ”€β”€ output_stats.py # Statistics tool β”‚ └── maintenance.py # Maintenance tool β”œβ”€β”€ resources/ # MCP resources β”‚ β”œβ”€β”€ file_metadata.py # File metadata resource β”‚ β”œβ”€β”€ stored_images.py # Image storage resource β”‚ β”œβ”€β”€ template_catalog.py # Template catalog β”‚ └── operation_status.py # Operation status β”œβ”€β”€ prompts/ # Prompt templates β”‚ β”œβ”€β”€ photography.py # Photography templates β”‚ β”œβ”€β”€ design.py # Design templates β”‚ └── editing.py # Image editing templates └── utils/ # Utility functions β”œβ”€β”€ image_utils.py # Image processing utilities β”œβ”€β”€ logging_utils.py # Logging configuration └── validation_utils.py # Validation helpers ``` ### Configuration Files ``` β”œβ”€β”€ pyproject.toml # Project configuration and dependencies β”œβ”€β”€ fastmcp.json # FastMCP CLI configuration β”œβ”€β”€ ruff.toml # Code linting configuration └── uv.lock # Dependency lock file ``` ### Scripts & Tools ``` scripts/ β”œβ”€β”€ build.py # Automated build script └── upload.py # PyPI upload script ``` ## πŸ”Œ MCP Integration ### Available Tools | Tool | Description | Status | |------|-------------|---------| | `generate_image` | AI image generation from prompts | βœ… Active | | `upload_file` | File upload to Gemini Files API | βœ… Active | | `output_stats` | Image storage statistics | βœ… Active | | `maintenance` | System maintenance operations | βœ… Active | ### Available Resources | Resource | URI Pattern | Description | |----------|-------------|-------------| | File Metadata | `gemini://files/{name}` | Gemini Files API metadata | | Stored Images | `file://images/{id}` | Generated image access | | Image Thumbnails | `file://images/{id}/thumbnail` | Image thumbnail access | | Template Catalog | `nano-banana://prompt-templates` | Prompt template browser | | Operation Status | `nano-banana://operations` | Server operation status | ### Prompt Templates | Template | Module | Purpose | |----------|---------|---------| | `photorealistic_shot` | photography.py | High-quality photography | | `product_shot` | photography.py | E-commerce product photos | | `logo_text` | design.py | Logo design with text | | `sticker_flat` | design.py | Flat design illustrations | | `iterative_edit_instruction` | editing.py | Precise image editing | | `composition_and_style_transfer` | editing.py | Artistic style transfer | ## πŸ› οΈ Technical Stack ### Core Dependencies - **FastMCP** (β‰₯2.11.0) - MCP server framework - **Google GenAI** (β‰₯0.3.0) - Gemini API integration - **Pillow** (β‰₯10.4.0) - Image processing - **Pydantic** (β‰₯2.0.0) - Data validation - **Python-dotenv** (β‰₯1.0.1) - Environment management ### Development Tools - **uv** - Modern Python package management - **Ruff** - Fast Python linter and formatter - **MyPy** - Static type checking - **Pytest** - Testing framework ### Build System - **Hatchling** - Modern Python build backend - **Twine** - PyPI package uploading - **Build** - PEP 517 build frontend ## πŸ“Š Project Metrics ### Package Information - **Total Python Files:** 40+ - **Package Size:** ~260KB (wheel + source) - **Supported Python:** 3.11+ - **License:** MIT - **Development Status:** Alpha (Production Ready) ### Documentation Coverage | Category | Files | Status | |----------|-------|---------| | API Documentation | 3 | βœ… Complete | | System Design | 2 | βœ… Complete | | User Guides | 2 | βœ… Complete | | Development Guides | 3 | βœ… Complete | | Publishing Guides | 2 | βœ… Complete | ## πŸ” Version History ### v0.1.4 (Latest) - Comprehensive Import Fixes - βœ… Fixed all absolute imports to relative imports - βœ… Restructured to proper package layout - βœ… Added automated PyPI publishing workflow - βœ… Streamlined README with client configurations ### v0.1.3 - Import Fixes - βœ… Fixed service import issues - βœ… Updated resource handlers ### v0.1.2 - Directory Fixes - βœ… Fixed read-only filesystem issues - βœ… Improved default directory handling ### v0.1.1 - Initial Package - βœ… Basic MCP server functionality - βœ… Image generation tools ## πŸ“‹ Development Status ### βœ… Completed Features - Production-ready MCP server - Comprehensive image generation capabilities - File management and storage - Template system with 6+ templates - Error handling and logging - PyPI package publishing - Multi-client configuration support ### πŸ”„ In Progress - Enhanced documentation - Performance optimization - Additional prompt templates ### πŸ“‹ Planned Features - Image editing capabilities expansion - Batch processing tools - Advanced template customization - Performance monitoring ## πŸ†˜ Support & Resources - **Issues:** [GitHub Issues](https://github.com/zhongweili/nanobanana-mcp-server/issues) - **Discussions:** [GitHub Discussions](https://github.com/zhongweili/nanobanana-mcp-server/discussions) - **Package:** [PyPI Package](https://pypi.org/project/nanobanana-mcp-server/) --- *Last updated: December 2024 | Version 0.1.4*

Latest Blog Posts

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/zhongweili/nanobanana-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server