Gpt Image 2 Polza MCP Server logo

Gpt Image 2 Polza MCP Server

Generates and edits images with GPT Image 2 through Polza, with reference uploads, local output storage, previews, and metadata.

Install Gpt Image 2 Polza MCP Server

Run the project’s own setup commands, in order.

Setup steps from the project

gpt-image-2-polza-mcp-server installs with its own steps rather than a config we can generate, so these are copied as-is. Follow them in order and run the commands in a terminal. Source: github.com

  1. 1. Install
    git clone https://github.com/ivanantigravity-lgtm/gpt-image-2-polza-mcp.git
    
  2. 2. Run
    cd gpt-image-2-polza-mcp
    
  3. 3. Install
    uv sync
    
  4. 4. Configure
    cp .env.example .env
    
  5. 5. Start the server
    uv run gpt-image-2-polza-mcp-server
    

Overview

The gpt-image-2-polza-mcp-server MCP server connects MCP clients to Polza’s GPT Image 2 image-generation API. It can create or edit images, use up to three local reference images, save full-size results locally, and return previews with structured metadata. Use it when an agent needs image generation through Polza without a separate OpenAI API key. The server runs locally with Python and uv and communicates with clients through MCP.

Use cases

  • Generate product visuals from text prompts
  • Edit existing images with local references
  • Create images in specified aspect ratios and resolutions
  • Recover completed generations after a client timeout
  • Track local output and metadata storage

Key features

  • GPT Image 2 generation and editing through Polza
  • Support for up to three reference image paths
  • Local full-size output storage
  • Preview and structured metadata responses
  • Generation recovery by Polza media ID
  • Local cache maintenance and output statistics

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

15/15 checks healthy over the last 78d

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

Last commit5mo agoMost recent push to the default branch.
Directory activity2 viewsConfig copies, upvotes, and views on AllMCPs.

How Gpt Image 2 Polza MCP Server works

What the gpt-image-2-polza-mcp-server MCP server does

The gpt-image-2-polza-mcp-server MCP server exposes Polza’s image API to MCP-compatible clients. It uses the openai/gpt-5.4-image-2 model through the gpt-image-2 model tier and supports both new image generation and image editing.

The main workflow accepts a text prompt or editing instruction and can optionally use local reference files. Results can be written to a selected file or directory. The server also returns a preview and structured metadata through MCP, while full-size output is retained on disk.

Supported image controls include 1k, 2k, 4k, or high resolution and aspect ratios such as 1:1, 16:9, 9:16, and 4:5. The force_new_generation option bypasses an existing cached result for the same request.

How it works

The gpt-image-2-polza-mcp-server MCP server starts a generation through Polza’s POST /v1/media endpoint, then checks the corresponding media record with GET /v1/media/{id}. A completed request produces a local output file and MCP response data. Polling behavior can be adjusted with environment variables for interval and timeout.

If a client times out while Polza continues processing, do not immediately submit the same request again. Instead, find the gen_... identifier in Polza’s generation history and pass it to fetch_generation, optionally specifying a destination path. This retrieves the existing result rather than starting another generation.

Reference images are first sent to Polza Storage through POST /v1/storage/upload. Storage metadata can be read and files can be deleted through the corresponding Polza endpoints. Local maintenance and output statistics are available through dedicated MCP tools.

Setup and configuration

The server requires Python 3.11 or newer, uv, a Polza account, and POLZA_AI_API_KEY. Clone the repository, run uv sync, and register the executable with an MCP client using a configuration that calls uv run gpt-image-2-polza-mcp-server. The configuration should use an absolute working directory and can define a separate output directory.

POLZA_BASE_URL defaults to https://polza.ai/api. IMAGE_OUTPUT_DIR defaults to ~/gpt-image-2-images. Other optional settings select the model tier, polling interval, polling timeout, external Polza user ID, and whether the response should contain the full image instead of a preview. Restart the MCP client after adding or changing its configuration.

Tools and capabilities

The available MCP tools are:

  • generate_image creates or edits an image and accepts prompts, modes, resolutions, aspect ratios, reference paths, output paths, and cache control.
  • fetch_generation retrieves an existing generation by its Polza media ID.
  • upload_file uploads a local reference image to Polza Storage.
  • show_output_stats reports statistics for the local result directory.
  • maintenance manages the local cache and metadata database.

Limitations and notes

Generation may continue remotely after an MCP-side timeout, so retrying immediately can create and charge a second request. The documented setup uses a local stdio process launched with uv. Client support depends on an MCP client that can run this configuration.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Gpt Image 2 Polza MCP Server

gpt-image-2-polza-mcp-server is an MCP server that connects MCP clients to Polza’s GPT Image 2 API. Its main tools generate or edit images, upload reference files, retrieve completed generations, report local output statistics, and maintain the local cache and metadata database. It requires a Polza API key, not an OpenAI key.

Install it by cloning the repository, changing into its directory, and running `uv sync`. Add an MCP configuration that launches `uv run gpt-image-2-polza-mcp-server`, sets the repository as the working directory, and provides `POLZA_AI_API_KEY`. Restart the MCP client after saving the configuration.

Configure Cursor to launch the server with uv, provide the repository’s absolute working directory, and set the required Polza API key in the server environment.

Use `fetch_generation` with the existing `gen_...` media ID from Polza’s generation history. A client timeout does not necessarily stop processing on Polza, so retrieve the existing generation instead of submitting the same prompt again.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewGpt Image 2 Polza MCP Server AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/gpt-image-2-polza-mcp-server?style=directory)](https://allmcps.com/mcp/gpt-image-2-polza-mcp-server)
HTML Embed
<a href="https://allmcps.com/mcp/gpt-image-2-polza-mcp-server"><img src="https://allmcps.com/api/badge/gpt-image-2-polza-mcp-server?style=directory" alt="Gpt Image 2 Polza MCP Server on AllMCPs" /></a>