Text-to-Image API
Generate images from text prompts through one API — open-source diffusion models and first-party provider models side by side, priced per image or per megapixel so short runs stay cheap.
39 text-to-image models available right now — every one runnable in a free playground, through the REST API and JavaScript SDK, or from an AI assistant via MCP.
Text-to-Image models & pricing
| Model | Endpoint | Price |
|---|---|---|
| Qwen-Image 3.0 | alibaba/qwen-image/v3.0/text-to-image | $0.03 per image |
| Nano Banana 2 Lite Text to Image | google/nano-banana-2-lite | $0.034 per image |
| Seedream 5.0 Pro Text to Image | bytedance/seedream-v5-pro/text-to-image | $0.09 per image |
| Recraft V4.1 | recraft/v4.1/text-to-image | $0.035 per image |
| Recraft V4 | recraft/v4/text-to-image | $0.04 per image |
| Recraft V4.1 Pro | recraft/v4.1/pro/text-to-image | $0.21 per image |
| Recraft V4 Pro | recraft/v4/pro/text-to-image | $0.25 per image |
| Recraft V4.1 Pro | recraft/v4.1/pro/text-to-vector | $0.3 per image |
| Recraft V4 Pro | recraft/v4/pro/text-to-vector | $0.3 per image |
| Recraft V4.1 | recraft/v4.1/text-to-vector | $0.08 per image |
| HiDream I1 Dev | hidream/i1-dev | $0.03 per megapixel |
| Stable Diffusion 3.5 Large Turbo | stability-ai/stable-diffusion-v3.5-large-turbo | $0.015 per megapixel |
| Recraft V4 | recraft/v4/text-to-vector | $0.08 per image |
| Stable Diffusion 3.5 Medium | stability-ai/stable-diffusion-v3.5-medium | $0.02 per megapixel |
| Grok Imagine Image | xai/grok-imagine/image | $0.02 per image |
| FLUX.2 [flex] | black-forest-labs/flux-2/flex | from $0.05 per image |
| FLUX.2 [pro] | black-forest-labs/flux-2/pro | from $0.03 per image |
| HunyuanImage 3.0 Instruct | tencent/hunyuan-image/v3/instruct/text-to-image | $0.09 per megapixel |
| HunyuanImage 3.0 | tencent/hunyuan-image/v3/text-to-image | $0.1 per megapixel |
| HiDream I1 Fast | hidream/i1-fast | $0.01 per megapixel |
| HiDream I1 Full | hidream/i1-full | $0.05 per megapixel |
| Stable Diffusion 3.5 Large | stability-ai/stable-diffusion-v3.5-large | $0.065 per megapixel |
| Boogu-Image | boogu/boogu-image | $0.04 per megapixel |
| Recraft V3 | recraft/v3/text-to-image | $0.04 per image |
| FLUX.2 [dev] | black-forest-labs/flux-2 | $0.012 per megapixel |
| Qwen-Image | qwen/qwen-image | $0.02 per megapixel |
| GPT Image 2 | openai/gpt-image-2 | $0.145 per image |
| Ideogram V4 | ideogram/ideogram-v4 | $0.06 per megapixel |
| Luma Uni-1 | luma/uni-1 | $0.042 per image |
| Krea 2 Large | krea/krea-2-large | $0.06 per image |
| Luma Uni-1 Max | luma/uni-1-max | $0.102 per image |
| Seedream 5.0 Lite Text to Image | bytedance/seedream-v5/text-to-image | $0.035 per image |
| Seedream V4.5 Image Editing | bytedance/seedream-v4.5/edit | $0.04 per image |
| Seedream V4.5 Text to Image | bytedance/seedream-v4.5/text-to-image | $0.04 per image |
| Nano Banana 2 Text to Image | google/nano-banana-2 | from $0.045 per image |
| BitDance Text to Image | shallowdream204/bitdance | $0.01 per image |
| Z-Image Base | tongyi-mai/z-image/base | $0.01 per megapixel |
| Z-Image Turbo | tongyi-mai/z-image/turbo | $0.005 per megapixel |
| SDXL Lightning 4-step | bytedance/sdxl-lightning-4step | ≈$0.00251692 per image |
Full catalog on the models page; live per-configuration costs on the pricing page.
Call a text-to-image model in one request
Every model shares the same request lifecycle: submit to the queue, poll the status URL, fetch the result. Swap the endpoint to switch models — nothing else changes.
cURL
curl -X POST https://queue.modelrunner.run/alibaba/qwen-image/v3.0/text-to-image \
-H "Authorization: Key $MRUN_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "prompt": "..." }'
# → { "request_id": "...", "status_url": "...", "response_url": "..." }Use text-to-image models from Claude & Cursor
Connect the ModelRunner MCP server once and your AI assistant can run every text-to-image model in this table as a tool — authorized via OAuth, results returned as hosted URLs in the conversation.
Claude Code
claude mcp add --transport http modelrunner https://mcp.modelrunner.run/mcpFrequently asked questions
How much does a text-to-image API cost?
Pricing is per model and pay-per-use: most text-to-image models are priced per generated image or per megapixel of output, with the exact rate shown in the table above and on each model page. There is no subscription — you buy credits and pay only for what you generate.
How do I call a text-to-image model via the API?
Every model shares the same request shape: POST https://queue.modelrunner.run/<owner>/<alias> with an Authorization: Key header and the input fields as the top-level JSON body (no wrapper object), then poll the returned status_url and fetch the result from response_url. The JavaScript SDK (@modelrunner/client) wraps this in a single subscribe() call, which is the one place an { input } object is used. Each model page shows copy-paste cURL, JavaScript, and Python examples with that model's real inputs.
Can I run text-to-image models from Claude or Cursor?
Yes. Connect the ModelRunner MCP server (https://mcp.modelrunner.run/mcp) once and every text-to-image model in the catalog becomes a tool your AI assistant can call with the run_model tool — authorized via OAuth, no API key pasted into config.
