Skip to content

MAI Image 2.5 image generation

MAI Image 2.5 is Microsoft's text-to-image model, hosted through FAL. The orchestrator exposes it as a single engine: "fal", model: "maiImage", operation: "createImage" entry — text-to-image only, with no editing, seed, or style-reference inputs.

Default choice for new integrations: leave aspectRatio at "auto" and let the model pick a composition-appropriate ratio, or pin one of the eleven supported ratios when you need a specific shape.

Prerequisites

Text-to-image

http
POST https://orchestration.civitai.com/v2/consumer/workflows?wait=60
Authorization: Bearer <your-token>
Content-Type: application/json

{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "fal",
      "model": "maiImage",
      "operation": "createImage",
      "prompt": "A photorealistic portrait of a woman with flowers in her hair, golden hour lighting",
      "aspectRatio": "1:1"
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Parameters

FieldRequiredDefaultNotes
prompt3–5000 characters. Natural-language prompts work well.
aspectRatio"auto"One of auto / 21:9 / 16:9 / 3:2 / 4:3 / 5:4 / 1:1 / 4:5 / 3:4 / 2:3 / 9:16. auto lets the model choose. MAI returns a fixed resolution per ratio — no width/height.
quantity114. MAI bills each image separately; quantities > 1 fan out to parallel FAL calls.
outputFormat"jpeg"jpeg / png / webp.

MAI Image does not accept negative prompts, seeds, LoRAs, style references, or explicit width/height — use the Krea, Qwen, or Flux 2 recipes if you need any of those.

Auto aspect ratio

Omit aspectRatio (or set it to "auto") to let MAI choose a ratio that suits the prompt:

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "fal",
      "model": "maiImage",
      "operation": "createImage",
      "prompt": "A majestic dragon soaring through clouds at sunset, highly detailed, fantasy art",
      "aspectRatio": "auto"
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Batch generation

Set quantity up to 4 for multiple images from one step. Each image is a separate FAL call (and a separate charge), run in parallel:

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "fal",
      "model": "maiImage",
      "operation": "createImage",
      "prompt": "An astronaut riding a horse on Mars, dramatic lighting",
      "aspectRatio": "9:16",
      "quantity": 4
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Reading the result

MAI emits the standard imageGen output — an images[] array with one entry per quantity:

json
{
  "status": "succeeded",
  "steps": [{
    "name": "0",
    "$type": "imageGen",
    "status": "succeeded",
    "output": {
      "images": [
        { "id": "blob_...", "url": "https://.../signed.jpeg" }
      ]
    }
  }]
}

Blob URLs are signed and expire — refetch the workflow or call GetBlob for a fresh URL.

Runtime

Single images typically land well inside the wait=60 long-poll window, so a single wait=60 POST covers the common case. A quantity: 4 batch fans out to parallel calls but can still push toward the 100-second request timeout on busy FAL queues — submit those with wait=0 and poll, or register a webhook.

Preliminary timings

MAI Image 2.5 is a fresh addition. Treat the wall-time guidance above as preliminary until the model has steady-state fleet capacity, and re-measure after it has been live for ~24 h.

Cost

Billed in Buzz on the workflow's transactions. Use whatif=true for an exact preview; see Payments (Buzz) for currency selection.

MAI bills a flat rate per generated image:

total = 65 × quantity
ShapeBuzz
Default (quantity: 1)65
Batch of 4 (quantity: 4)260

Aspect ratio and output format don't affect MAI's Buzz price — the provider charges flat per image.

Troubleshooting

SymptomLikely causeFix
400 with "prompt" length errorPrompt under 3 or over 5000 charactersKeep the prompt within 3–5000 characters.
400 with "aspectRatio must be one of"Invalid aspect ratioPick one of the listed ratios (or auto) — MAI doesn't accept width/height.
400 with "quantity" range errorquantity outside 14MAI caps batches at 4 images per step.
Request timed out (wait expired)Large quantity or busy FAL queueResubmit with wait=0 and poll.
Step failed, reason = "blocked"Prompt hit content moderationDon't retry the same input — see Errors & retries → Step-level failures.

Civitai Developer Documentation