image-gen-mcp
Verified Safeby JasonBates
Overview
Generates images using the laozhang.ai Gemini 3 Pro API and saves them to an Obsidian vault.
Installation
uv run image-gen-mcpEnvironment Variables
- LAOZHANG_API_KEY
- OBSIDIAN_VAULT_PATH
- AI_GRAPHICS_FOLDER
Security Notes
The server correctly loads API keys from environment variables and provides configurable paths for saving images. Filenames generated from prompts are sanitized, preventing path traversal. File operations are limited to user-defined directories. The use of httpx for API calls and pydantic for settings are standard secure practices. The LLM call for prompt variations is structured to parse JSON output, mitigating direct code execution via LLM responses. Reference images are read as bytes and passed to the API, without local execution of their content. User configuration of the Obsidian vault path to a sensitive system directory could pose a risk, but this is user-dependent and not a direct vulnerability in the server's code.
Similar Servers
mcp-obsidian
Enables LLMs (like Claude) to programmatically interact with an Obsidian vault through the Local REST API plugin.
nanobanana-api-mcp
An MCP server providing image generation and editing capabilities via the Google Gemini API, integrable with various AI coding assistants and IDEs.
obsidian-mcp-server
Provides an OpenAI-compatible local Model Context Protocol (MCP) server within Obsidian, enabling external AI assistants and tools to semantically search the vault and perform file system operations.
obsidian-mcp-server
Enables AI assistants to interact with and manage an Obsidian markdown vault via the Model Context Protocol (MCP).