generationstableimagetextreference
Generate image
studio_generate_imageText-to-image and image-to-image generation across the full WM Studio model catalogue.
Overview
Creates one or more images from a text prompt, optionally guided by reference images. Routes to the correct provider for the requested model (OpenAI GPT Image 2, Flux 2 Pro, Nano Banana Pro, Recraft, Gemini, …). Returns hosted URLs on the WM Studio asset CDN.
Auth
oauth-jwt
Returns
{ job_id, status, images?: [{ url, width, height, seed }] }
Web client
src/app/[locale]/dashboard/creative-studio/images/images-page-client.tsx
MCP handler
mcp-director/src/tools/studio.py
Quick start
Invoke the tool over Streamable HTTP at {MCP_BASE_URL}/mcp/. The request below assumes you already minted an MCP JWT via the OAuth flow.
{
"name": "studio_generate_image",
"arguments": {
"prompt": "<prompt>"
}
}Parameters
| Name | Type | Default | Description |
|---|---|---|---|
| promptrequired | string | — | Text prompt. |
| model | string | "openai/gpt-image-2" | Provider/model id (see /docs/configuration#models). |
| reference_images | string[] | — | Public URLs of reference images. |
| aspect_ratio | "1:1" | "16:9" | "9:16" | "4:3" | "3:4" | "1:1" | Target aspect ratio. |
| num_images | number | 1 | Batch size (1–4). |
| seed | number | — | Optional deterministic seed. |
Examples
Text-to-image
json
{
"name": "studio_generate_image",
"arguments": {
"prompt": "minimalist product photo of a black ceramic mug, soft daylight",
"model": "fal-ai/flux-2-pro",
"aspect_ratio": "4:3",
"num_images": 2
}
}Image-to-image (reference)
json
{
"name": "studio_generate_image",
"arguments": {
"prompt": "same mug, golden hour rooftop scene",
"model": "fal-ai/nano-banana-pro",
"reference_images": ["https://cdn.wm.studio/uploads/mug.png"]
}
}