Image Generator MCP Server
Allows generating images from text prompts using OpenAI's image generation models (e.g., DALL-E). Users can specify prompt, aspect ratio, and quality.
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., "@Image Generator MCP ServerGenerate an image of a sunset over mountains."
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.
Image Generator MCP Server
A Laravel app that exposes AI image generation as a Model Context Protocol (MCP) tool, built with laravel/mcp and laravel/ai. Any MCP-compatible client — Claude, Claude Code, Cursor, ChatGPT, etc. — can call it to generate an image from a text prompt.
What it does
The server registers one tool, generate-image. When an MCP client calls it with a prompt, the tool passes the prompt to the Laravel AI SDK, which generates the image via OpenAI, Gemini, or xAI (whichever provider you've configured), stores the result, and returns the image (or a link to it) back to the client.
Related MCP server: nanobanana-mcp
Requirements
PHP 8.2+, Laravel 12.x or 13.x
An API key for at least one supported image provider
Installation
composer require laravel/mcp laravel/ai
php artisan vendor:publish --tag=ai-routes
php artisan vendor:publish --provider="Laravel\Ai\AiServiceProvider"
php artisan migrateAdd a provider key to .env:
OPENAI_API_KEY=
GEMINI_API_KEY=
XAI_API_KEY=The server is registered in routes/ai.php:
use App\Mcp\Servers\ImageGeneratorServer;
use Laravel\Mcp\Facades\Mcp;
Mcp::web('/mcp/image-generator', ImageGeneratorServer::class);How to use it
Point any MCP client at the server's URL:
{
"mcpServers": {
"image-generator": {
"url": "https://your-app.test/mcp/image-generator"
}
}
}Once connected, just ask the client to generate an image — for example, "generate an image of a private jet" — and it will call the generate-image tool with your prompt and return the result. The tool accepts:
prompt(required) — what to generateaspect_ratio—square,portrait, orlandscape(defaultsquare)quality—low,medium, orhigh(defaultmedium)
If the endpoint requires authentication, add a bearer token to the client config:
{
"mcpServers": {
"image-generator": {
"url": "https://your-app.test/mcp/image-generator",
"headers": { "Authorization": "Bearer YOUR_TOKEN" }
}
}
}This server cannot be deployed
Maintenance
Related MCP Connectors
Generate AI images and videos from any compatible MCP client.
Use AI models for chat, image, and video generation from Claude Code and other MCP hosts.
Generate AI images, video, music, and sound effects, and upscale them, from any MCP client.
MCP server for Qwen Image 3 AI image generation
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI image generation via multiple providers (Yunwu, Gemini) with customizable aspect ratios, resolutions, and output settings, seamlessly integrating with MCP-compatible clients.15 npmMIT
- AlicenseAqualityDmaintenanceMCP server for AI image generation supporting text-to-image and image-to-image editing via any OpenAI-compatible service, with configurable models, aspect ratios, and sizes.2MIT
- AlicenseBqualityDmaintenanceEnables AI image generation via MCP protocol, supporting dozens of models, customizable parameters, and multiple resolutions.38 npmISC
- AlicenseNot gradedqualityAmaintenanceEnables AI assistants in MCP clients to generate and edit images by automatically expanding short requests into detailed prompts with composition, lighting, and camera direction, then saving results to disk. Supports Gemini, OpenAI, and BytePlus Seedream providers with selectable quality presets, aspect ratios, and image sizes.932 npmMIT