We use cookies. Cookies and browser storage keep you signed in and remember your preferences. With your permission we also measure how the site is used. You can any time. See our cookie policy.
Microsoft AI: MAI-Image-2.5
microsoft/mai-image-2.5Try Microsoft AI: MAI-Image-2.5 now
Runs on your balance at the prices above. New accounts start with free usage.
Settings
Microsoft AI: MAI-Image-2.5 at a glance
- Input price is close to the median of 21 Image models.
About Microsoft AI: MAI-Image-2.5
MAI-Image-2.5 is an image generation model from Microsoft, published under the Microsoft AI banner and identified on api14 as microsoft/mai-image-2.5. It sits in the image category, and Microsoft describes it as a high-quality image generation model available via Azure AI Foundry. If you are already working within Microsoft's ecosystem or evaluating it, this is the model that backs that offering.
The model takes text and image inputs and returns images. That means you can drive it with a prompt alone, or supply a single input reference image alongside your prompt to guide the result. Its context window is 4096 tokens, and the maximum output is 1024. Generation is controlled through a small set of image parameters: aspect_ratio, which accepts 1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3 or auto; n, which is fixed at exactly 1, so each request returns a single image; and input_references, which accepts between 0 and 1 reference images. Microsoft positions the output as both photorealistic and artistic, so it is intended to cover a fairly wide stylistic range rather than one narrow look.
The practical uses follow directly from those capabilities. Text to image generation covers the usual ground: concept art, marketing visuals, illustrations, and asset drafts where you need a specific framing, which is where the aspect ratio options matter, since you can request square, landscape or portrait output without post-processing crops. Because the model accepts one input reference image, it also suits workflows where you want a new image guided by an existing one, such as producing a variation on a composition or carrying a visual style from a reference into a new scene. The single image per request constraint means batch work is a matter of issuing multiple calls rather than asking for several images at once.
Calling it through api14 works the same way as any other model on the gateway, using the OpenAI-compatible API with the model id microsoft/mai-image-2.5. The supported request parameters are max_completion_tokens, max_tokens and temperature, alongside the image parameters described above for aspect ratio and input references. If you have existing OpenAI client code, you change the model id and the base URL, and the request shape stays familiar.
A few limits are worth knowing before you commit. The context window of 4096 tokens is modest, so very long or heavily detailed prompts have less room than on larger-context models. Output is capped at 1024, n cannot exceed 1, and only one input reference is accepted, so tasks needing multiple reference images or several images per call will not fit here. If your work is text rather than image generation, or you need a much larger context, a different model on api14 will serve you better.
How to call the Microsoft AI: MAI-Image-2.5 API
- Create an API key in your dashboard.
- Install the official openai SDK for your language.
- Set baseURL to https://api14.com/api/v1 and model to "microsoft/mai-image-2.5".
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://api14.com/api/v1",
apiKey: process.env.API14_API_KEY,
});
const result = await client.images.generate({
"model": "microsoft/mai-image-2.5",
"prompt": "A minimalist product photo of a ceramic mug on a wooden table",
"n": 1,
"aspect_ratio": "1:1"
});
import { writeFile } from "node:fs/promises";
await writeFile("image.png", Buffer.from(result.data[0].b64_json, "base64"));
Supported parameters
max_completion_tokensmax_tokenstemperatureSpecifications
- Context length
- 4,096
- Max output
- 1,024
- Input
- text, image
- Output
- image
Requests on api14 · last 7 days
Microsoft AI: MAI-Image-2.5: frequently asked questions
- How much does the Microsoft AI: MAI-Image-2.5 API cost?
- Microsoft AI: MAI-Image-2.5 costs Input $17.50 / 1M tokens. It is charged from your USD balance only for successful requests; failed requests are free.
- What is the context window of Microsoft AI: MAI-Image-2.5?
- Microsoft AI: MAI-Image-2.5 reads up to 4,096 tokens per request: prompt, history and documents together. It writes up to 1,024 output tokens per response.
- What can Microsoft AI: MAI-Image-2.5 do?
- Microsoft AI: MAI-Image-2.5 accepts text, image and returns image.
- How do I call Microsoft AI: MAI-Image-2.5 from my code?
- Point any OpenAI SDK at https://api14.com/api/v1 and set the model to "microsoft/mai-image-2.5". No other code changes. Copy a ready example from the code panel on this page.
- What are alternatives to Microsoft AI: MAI-Image-2.5?
- Comparable Image models at a similar price: Microsoft AI: MAI-Image-2.6, Krea: Krea 2 Large, OpenAI: GPT-5.4 Image 2. Each runs through the same API key, so switching is one string.
Microsoft AI: MAI-Image-2.5 community
New topicThis community has no topics yet. Open the first one about Microsoft AI: MAI-Image-2.5.