
greatsumini/nanobanana-api-mcp
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
ナノバナナ へ API MCP サーバー
概要
MCP (Model Context Protocol) サーバーで、Google Gemini API を使用して画像を生成および編集できます。 - : Google Gemini AI を使用してテキストプロンプトから画像を生成する - : テキストの記述に基づいて既存の画像を編集する - 参照イメージのためのサポート - 生成/編集 - 複数のモデルオプション (Pro と Normal) - タイプ安全のための TypeScript で構築 - CLI 引数または環境変数を介して柔軟な構成 生成されたイメージ:「前景の湖と夕日で穏やかな山の風景」 スミサリーを介して自動的にすべてのクライアントにNanobanana MCP Serverをインストールするには: 利用可能なクライアント:カーソル、クラウド、vcode、ウィンドサーフィン、クライン、zedなど 選択したクライアントでMCPサーバーを自動的に設定します。 GeminiモデルにアクセスできるGoogle APIキーが必要です。 Google AI Studio から API キーを取得します。 CLI 引数で API キーを提供できます
概要(AI 翻訳)
MCP (Model Context Protocol) サーバーで、Google Gemini API を使用して画像を生成および編集できます。
##特徴
- generate image: Google Gemini AIを用いたテキストプロンプトから画像を生成 -edit image:テキストの説明に基づいて既存の画像を編集する
- 参照イメージのためのガイドの生成/編集へのサポート
- 複数のモデルオプション(プロとノーマル)
- タイプ安全のためのTypeScriptによって造られる
- CLI 引数または環境変数による柔軟な設定
##画像生成例
生成されたイメージ:「前景の湖と夕日で穏やかな山の風景」
インストール
###NPM ##NPM ## ##NPM ## ##NPM ## ## ## ##NPM ## ## ## ## ## ## ## ##NPM ## ## ##NPM ## ## ## ## ## ##NPM ## ## ## ## ## ## ## ##NPM ## ## ## ## ## ## ## ##NPM ## ## ## ## ## ## ##NPM ##
##スモーレ
スミサリーを介して自動的にすべてのクライアントにNanobanana MCP Serverをインストールするには:
利用可能なクライアント: cursor, claude], [vscode], [windsurf]], [cline]], [zed, 等。
カーソル例:
選択したクライアントでMCPサーバーを自動的に設定します。
前提条件
GeminiモデルにアクセスできるGoogle APIキーが必要です。 Google AI Studio から API キーを取得します。
CLI 引数で API キーを提供できます。
環境変数として設定するか:
MCP クライアントの統合
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
Nanobanana API MCP
MCP (Model Context Protocol) server for generating and editing images using Google Gemini API.
Features
- generate_image: Generate images from text prompts using Google Gemini AI
- edit_image: Edit existing images based on text descriptions
- Support for reference images to guide generation/editing
- Multiple model options (Pro and Normal)
- Built with TypeScript for type safety
- Flexible configuration via CLI arguments or environment variables
Image Generation Example
Generated image: “A serene mountain landscape at sunset with a lake in the foreground”
Installation
NPM
npm install -g nanobanana-api-mcp
Smithery
To install Nanobanana MCP Server for any client automatically via Smithery:
npx -y @smithery/cli@latest install nanobanana-api-mcp --client
Available clients: cursor, claude, vscode, windsurf, cline, zed, etc.
Example for Cursor:
npx -y @smithery/cli@latest install nanobanana-api-mcp --client cursor
This will automatically configure the MCP server in your chosen client.
Prerequisites
You need a Google API key with access to Gemini models. Get your API key from Google AI Studio.
You can provide the API key via CLI argument:
nanobanana-api-mcp --apiKey "your-api-key-here"
Or set it as an environment variable:
export GOOGLE_API_KEY="your-api-key-here"
nanobanana-api-mcp
MCP Client Integration
Nanobanana MCP can be integrated with various AI coding assistants and IDEs that support the Model Context Protocol (MCP).
Requirements
- Node.js >= v18.0.0
- Google API key with Gemini access
- An MCP-compatible client (Cursor, Claude Code, VS Code, Windsurf, etc.)
Go to: Settings -> Cursor Settings -> MCP -> Add new global MCP server
Add the following configuration to your ~/.cursor/mcp.json file:
{
"mcpServers": {
"nanobanana": {
"command": "npx",
"args": ["-y", "nanobanana-api-mcp", "--apiKey", "your-api-key-here"]
}
}
}
Optionally, you can fix the model to use for all operations:
{
"mcpServers": {
"nanobanana": {
"command": "npx",
"args": [
"-y",
インストール
npx -y nanobanana-api-mcp --apiKey your-api-key-here設定
{
"mcpServers": {
"nanobanana": {
"command": "npx",
"args": ["-y", "nanobanana-api-mcp", "--apiKey", "your-api-key-here"]
}
}
}