Imgx MCP Server

AI image generation and editing MCP server with context-aware prompt optimization, 24 editing techniques, and session undo/redo

Local serverstdioTypeScript

What is the Imgx MCP MCP server?

Imgx MCP MCP server exists for a simple reason — assistants are far more useful when they can act on Imgx MCP directly instead of describing what you should do. AI image generation and editing MCP server with context-aware prompt optimization, 24 editing techniques, and session undo/redo.

What you get

AI image generation and editing MCP server. Works with Claude Code, Gemini CLI, Cursor, Windsurf, and any MCP-compatible tool.

What the assistant can call

Once Imgx MCP is connected, these are the calls the assistant has available:

  • generate_image — Generate an image from a text prompt
  • edit_image — Edit an existing image with text instructions
  • edit_last — Edit the last generated/edited image (no input path needed)
  • undo_edit — Undo the last edit, reverting to the previous image in the session
  • redo_edit — Redo a previously undone edit
  • edit_history — Show all sessions and their edit history with metadata
  • switch_session — Switch to a different editing session
  • clear_history — Clear project history (optionally delete image files)
  • set_output_dir — Change the default output directory (optionally move existing files)
  • list_providers — List available providers and capabilities
  • Detected — /.imgx/
  • Usage — The Usage tool exposed by this server

Setting it up

has on npm is all you need. Most clients run it directly, so configuration is a few lines and a restart.

Configuration and credentials

You will need 5 environment variables: GEMINI_API_KEY, OPENAI_API_KEY, IMGX_PROJECT_ROOT, YOUR_GEMINI_API_KEY, YOUR_OPENAI_API_KEY. The server will not start without them, which is usually why the tools fail to appear on a first run. Keep credentials in your client's env block or a secrets manager rather than in a file you might commit.

Choosing this one

Plenty of file and storage access servers cover similar ground. The differences that matter in practice are scope of access and how much setup stands between you and a working tool call. Imgx MCP's toolset — generate_image, edit_image, edit_last and 11 more — is a fair guide to whether it matches your workflow. It is maintained by somacoffeekyoto; worth a glance at recent repository activity before you build anything load-bearing on it.

We check each listing at SyncDev against the project's documentation before it goes live — if something here drifts out of date, it is a bug worth reporting.

Before you rely on it

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • With 14 tools registered it takes up a noticeable share of the context window; turn it off in projects that never touch Imgx MCP.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • MCP clients confirm each tool call by default. Leave that on until you have watched what the imgx mcp mcp server does with a few real requests.

Available tools

ToolWhat it does
generate_imageGenerate an image from a text prompt
edit_imageEdit an existing image with text instructions
edit_lastEdit the last generated/edited image (no input path needed)
undo_editUndo the last edit, reverting to the previous image in the session
redo_editRedo a previously undone edit
edit_historyShow all sessions and their edit history with metadata
switch_sessionSwitch to a different editing session
clear_historyClear project history (optionally delete image files)
set_output_dirChange the default output directory (optionally move existing files)
list_providersList available providers and capabilities
Detected<project-root>/.imgx/
UsageThe Usage tool exposed by this server.
ConfigurationThe Configuration tool exposed by this server.
SkillDelete the image-generation/ directory from .claude/skills/ or ~/.claude/skills/.

How to install the Imgx MCP MCP server

{
  "mcpServers": {
    "imgx": {
      "command": "npx",
      "args": ["--package=imgx-mcp", "-y", "imgx-mcp"],
      "env": { "GEMINI_API_KEY": "your-key" }
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

VariableDescriptionRequired
GEMINI_API_KEYCredential the server authenticates with.Yes
OPENAI_API_KEYCredential the server authenticates with.Yes
IMGX_PROJECT_ROOTConfiguration value read at startup.Optional
YOUR_GEMINI_API_KEYCredential the server authenticates with.Yes
YOUR_OPENAI_API_KEYCredential the server authenticates with.Yes

Example prompts to try

  • Use Imgx MCP to generate image.
  • Use Imgx MCP to edit image.
  • Use Imgx MCP to edit last.

Frequently asked questions

It connects Imgx MCP to MCP-compatible AI assistants such as Claude and Cursor, exposing 14 tools (generate_image, edit_image, edit_last, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Imgx MCP directly.