An MCP (Model Context Protocol) server for generating images from text prompts. This server allows AI assistants to create images / draw through a standardized interface.
- Node.js (v18 or higher)
- An OpenAI API key
First, get an OpenAI API key from OpenAI's platform. This will be used to authenticate the MCP server with OpenAI's services.
{
"mcpServers": {
"mcp-draw": {
"command": "npx",
"args": [
"-y",
"mcp-draw@latest"
"--api-key",
"<REPLACE-WITH-YOUR-OPENAI-API-KEY>",
"--output-dir",
"/ABSOLUTE/PATH/TO/SAVE/OUTPUT_FOLDER"
]
}
}
}
First, get an OpenAI API key from OpenAI's platform. This will be used to authenticate the MCP server with OpenAI's services.
git clone https://github.com/kdr/mcp-draw.git
cd mcp-draw
npm install
npm run build
{
"mcpServers": {
"mcp-draw": {
"command": "node",
"args": [
"/ABSOLUTE/PATH/TO/mcp-draw/build/index.js",
"--api-key",
"<REPLACE-WITH-YOUR-OPENAI-API-KEY>",
"--output-dir",
"/ABSOLUTE/PATH/TO/SAVE/OUTPUT_FOLDER"
]
}
}
}
The following tools are available to the LLM:
-
generate_image_from_description
: Creates an image from a text prompt using OpenAI's gpt-image-1 model