Image Gen
v0.2.1Generate and edit images from your coding agent with Gemini and OpenAI, using your own API keys.
Values you need
| Variable | What it is | |
|---|---|---|
GEMINI_API_KEY | optional secret | Google Gemini API key. Enables the Gemini provider. At least one provider key is required. |
OPENAI_API_KEY | optional secret | OpenAI API key. Enables the OpenAI provider. At least one provider key is required. |
IMAGE_GEN_MCP_DEFAULT_PROVIDER | optional | Provider used when a tool call does not name one: gemini or openai. Defaults to whichever key is set, preferring gemini. |
IMAGE_GEN_MCP_GEMINI_MODEL | optional | Default Gemini model. Defaults to gemini-3.1-flash-image. |
IMAGE_GEN_MCP_OPENAI_MODEL | optional | Default OpenAI model. Defaults to gpt-image-2. |
IMAGE_GEN_MCP_OUTPUT_DIR | optional | Directory used when a tool call passes no output_path. |
IMAGE_GEN_MCP_ALLOWED_DIRS | optional | Comma separated directories that file reads and writes are confined to. Unset means unrestricted. |
IMAGE_GEN_MCP_TIMEOUT_MS | optional | Per-request timeout to the provider API in milliseconds. Defaults to 180000. |
IMAGE_GEN_MCP_LOG_FILE | optional | Path of the JSONL image ledger. Defaults to ~/.image-gen-mcp/images.jsonl. Set to none to disable the file. |
npm (npx) discovery passed
Requires Node.js 18+
Run in a terminal
claude mcp add image-gen -- npx -y @nuver-labs/image-gen-mcp@0.2.1Add to
claude_desktop_config.json{
"mcpServers": {
"image-gen": {
"args": [
"-y",
"@nuver-labs/image-gen-mcp@0.2.1"
],
"command": "npx"
}
}
}Add to
~/.cursor/mcp.json{
"mcpServers": {
"image-gen": {
"args": [
"-y",
"@nuver-labs/image-gen-mcp@0.2.1"
],
"command": "npx"
}
}
}Add to
.vscode/mcp.json{
"servers": {
"image-gen": {
"args": [
"-y",
"@nuver-labs/image-gen-mcp@0.2.1"
],
"command": "npx",
"type": "stdio"
}
}
}Add to
~/.codex/config.toml[mcp_servers.image-gen]
command = "npx"
args = ["-y", "@nuver-labs/image-gen-mcp@0.2.1"]For AI agents
- Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
- Restart or reload the client so it starts the server.
- Verify: the server should expose these tools: generate_image, edit_image, list_capabilities.
- If it fails, check that the required runtime is installed (Node.js 18+) and that the values above are set.
Machine-readable: install.md · manifest.json