openai-images-mcp
Provides tools for generating and editing images using OpenAI's GPT Image and DALL·E models, including image generation from text prompts, editing existing images with masks, and creating image variations.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@openai-images-mcp generate a logo for a coffee shop called 'Morning Brew' with a minimalist design"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
openai-images-mcp
Generate and edit images with OpenAI's gpt-image and DALL·E models, exposed as Model Context Protocol tools. Supports gpt-image-1.5, gpt-image-1, gpt-image-1-mini, dall-e-3, and dall-e-2.
Tools
Tool | Purpose | Models |
| List supported models and their capabilities (sizes, qualities, edit/variation support). | all |
| Generate one or more images from a text prompt. |
|
| Edit existing images with a prompt and optional mask. |
|
| Generate variations of an image. |
|
All generated files are saved to disk. Set return_image_content: true on any call to also receive the images as MCP image blocks (useful when the client should "see" the result, but adds a lot of tokens).
Related MCP server: GPT Image MCP Server
Install
npm install
npm run buildConfigure your MCP client
Claude Desktop / Claude Code
Add to claude_desktop_config.json (or your project's .mcp.json):
{
"mcpServers": {
"dalle": {
"command": "node",
"args": ["/absolute/path/to/dalle-mcp/dist/index.js"],
"env": {
"OPENAI_API_KEY": "sk-...",
"DALLE_OUTPUT_DIR": "/absolute/path/where/images/save"
}
}
}
}Environment variables
Variable | Purpose |
| Required. Your OpenAI API key. |
| Optional. Override OpenAI base URL. |
| Optional. |
| Optional. |
| Optional. Default directory for saved images. Falls back to |
| Optional. Model used when a tool call omits |
Tool reference
generate_image
Required: prompt.
Optional: model, size, quality, n, background, output_format, output_compression, moderation, style, user, output_dir, filename_prefix, return_image_content.
Model-specific notes:
GPT Image (
gpt-image-1.5,gpt-image-1,gpt-image-1-mini): sizesauto|1024x1024|1536x1024|1024x1536, qualitiesauto|low|medium|high. Supportsbackground,output_format,output_compression,moderation.DALL·E 3: sizes
1024x1024|1792x1024|1024x1792, qualitiesstandard|hd,nmust be 1, supportsstyle.DALL·E 2: sizes
256x256|512x512|1024x1024, qualitystandard.
edit_image
Required: prompt, images (absolute paths, up to 16 for GPT Image).
Optional: mask (transparent pixels indicate editable regions), plus the generation options above. DALL·E 3 does not support edits.
create_variation
DALL·E 2 only. Required: image (PNG, square, under 4MB).
Optional: n, size (256x256|512x512|1024x1024), output_dir, filename_prefix, return_image_content.
list_models
No arguments. Returns a JSON document describing each model's sizes, qualities, and supported options — handy for the caller to consult before picking parameters.
Development
npm run dev # run with tsx, no build step
npm run build # tsc to dist/
npm start # node dist/index.jsThe server speaks MCP over stdio, so you can drive it with any MCP-compatible client or manually by piping JSON-RPC messages to node dist/index.js.
Notes
DALL·E 2 and DALL·E 3 are deprecated by OpenAI and support ends 2026-05-12; prefer the GPT Image family.
GPT Image models always return base64 data; DALL·E models are asked for base64 as well so files can be saved without a second HTTP round-trip.
Available Tools
4 toolscreate_variationCreate image variationA
Generate variations of an existing image using DALL·E 2 (the only model that supports variations). Results are saved to disk and file paths are returned.
Inputs: image (required), n, size, user, +3 more.
edit_imageEdit imageC
Edit one or more existing images using a text prompt and optional mask. Supports gpt-image-1.5, gpt-image-1, gpt-image-1-mini, and dall-e-2. Results are saved to disk and file paths are returned.
Inputs: prompt (required), images (required), mask, model, +11 more.
generate_imageGenerate imageB
Create one or more images from a text prompt using OpenAI's image models (gpt-image-1.5, gpt-image-1, gpt-image-1-mini, dall-e-3, dall-e-2). Images are saved to disk and file paths are returned.
Inputs: prompt (required), model, size, quality, +10 more.
list_modelsList image modelsA
List supported OpenAI image models with their capabilities (sizes, qualities, edit/variation support, etc.). Use this before calling generate_image or edit_image to check which options a model accepts.
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 4 tools
Each tool has a clearly distinct purpose: generating new images, editing existing ones, creating variations, and listing supported models. There is no overlap or confusion between them.
All tool names follow a consistent verb_noun pattern using snake_case (create_variation, edit_image, generate_image, list_models), making them predictable and easy to understand.
With 4 tools, the server is well-scoped for its purpose of generating and manipulating images via OpenAI's APIs. Each tool earns its place without unnecessary duplication or gaps.
The set covers the full lifecycle of image creation: generating, editing, and creating variations, along with a model listing tool for configuration. No obvious missing functionality for the intended domain.
Maintenance
Related MCP Connectors
MCP server for Qwen Image 3 AI image generation
MCP server for OpenAI API (chat completions, image generation, embeddings) via AceDataCloud
MCP server for Midjourney AI image generation and editing
Generate and edit images, video, voice and music from any MCP client. 50 tools, 46 models.
Related MCP Servers
- FlicenseAqualityDmaintenanceAn MCP server that allows users to generate, edit, and create variations of images through OpenAI's DALL-E API, supporting both DALL-E 2 and DALL-E 3 models.49-
- FlicenseNot gradedqualityDmaintenanceAn MCP server that enables text-to-image generation and editing using OpenAI's gpt-image-1 model, supporting multiple output formats, quality settings, and background options.69-
- AlicenseNot gradedqualityDmaintenanceAn MCP server that enables image generation and editing using OpenAI's DALL-E models with support for text prompts, inpainting, and outpainting. It includes advanced features like automatic aspect ratio mapping and intelligent file management to handle large image payloads.1MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that provides tools to generate, edit, and create variations of images using OpenAI DALL-E models.MIT