Gemini 2.5 Flash Image Edit overview
Gemini 2.5 Flash Image Edit specs
- Model ID
gemini-25-flash-image/edit- Developer
- Input
- Image, Text
- Output
- Image
- Endpoint
POST https://api.aimlapi.com/v1/images/generations
What is Gemini 2.5 Flash Image Edit API?
Gemini 2.5 Flash Image Edit enables text-guided image editing powered by Google's Gemini 2.5 Flash model.
Gemini 2.5 Flash Image Edit API Pricing
- Pricing on request
Where to Use Gemini 2.5 Flash Image Edit
Use cases
Multi-image fusion: the model is documented as able to combine multiple input images into one seamless visual, letting you merge references into a single result.
Character and style consistency: it is documented as suited to keeping the same subject, character, or visual style consistent across multiple generations, which helps preserve identity in storytelling or repeated scenes.
Conversational editing: it is documented as suited to targeted image edits from natural-language instructions, including changes like blurring backgrounds, removing objects or people, altering poses, adding color to black-and-white photos, and fixing small details.
Scene composition and restyling: it is documented as able to place an object into a scene or restyle a room with a chosen color scheme or texture using a single prompt.
Gemini 2.5 Flash Image Edit API pricing
| Usage | Price | Unit |
|---|---|---|
| Image generation | $0.039 | per generation |
The final price depends on request parameters such as resolution or duration.
Prices from the AI/ML API price list, checked on Nov 4, 2026.
Gemini 2.5 Flash Image Edit vs other image models: prices
AI/ML API rates for 5 models, per generation.
| Model | Per generation |
|---|---|
| $0.039 | |
| $0.039 | |
| $0.04 | |
| $0.15 | |
| $0.25 |
How to use the Gemini 2.5 Flash Image Edit API
View docsBuild with your agent
Give your agent the model details, code and documentation.
1Get your API key
Create API keyexport AIMLAPI_KEY="8f2b4c7d9a1e6b3f…"2Make your first request
curl 'https://api.aimlapi.com/v1/images/generations' \
-H "Authorization: Bearer $AIMLAPI_KEY" \
-H 'Content-Type: application/json' \
-d '{
"model": "gemini-25-flash-image/edit",
"prompt": "A ginger cat asleep on a stack of exactly three hardcover books in a rainy bookshop window at dusk. Gold lettering on the glass reads OPEN LATE. Warm lamp light inside, raindrops and blurred neon reflections outside, 35mm film photo.",
"image_urls": [
"https://example.com/input.jpg"
]
}'import os
import requests
headers = {
"Authorization": f"Bearer {os.environ['AIMLAPI_KEY']}",
"Content-Type": "application/json",
}
payload = {
"model": "gemini-25-flash-image/edit",
"prompt": "A ginger cat asleep on a stack of exactly three hardcover books in a rainy bookshop window at dusk. Gold lettering on the glass reads OPEN LATE. Warm lamp light inside, raindrops and blurred neon reflections outside, 35mm film photo.",
"image_urls": [
"https://example.com/input.jpg"
]
}
response = requests.post("https://api.aimlapi.com/v1/images/generations", headers=headers, json=payload, timeout=120)
response.raise_for_status()
print(response.json())const response = await fetch("https://api.aimlapi.com/v1/images/generations", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.AIMLAPI_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"model": "gemini-25-flash-image/edit",
"prompt": "A ginger cat asleep on a stack of exactly three hardcover books in a rainy bookshop window at dusk. Gold lettering on the glass reads OPEN LATE. Warm lamp light inside, raindrops and blurred neon reflections outside, 35mm film photo.",
"image_urls": [
"https://example.com/input.jpg"
]
}),
});
if (!response.ok) throw new Error(`HTTP ${response.status}`);
console.log(await response.json());Related articles
Gemini 2.5 Flash Image Edit FAQ
What inputs and outputs does Gemini 2.5 Flash Image Edit support?
Gemini 2.5 Flash Image Edit takes image, text as input and returns image.
How much does Gemini 2.5 Flash Image Edit cost?
Gemini 2.5 Flash Image Edit costs $0.039 per generation on AI/ML API, billed as you go with no subscription.
How is Gemini 2.5 Flash Image Edit billed?
Gemini 2.5 Flash Image Edit is billed per generation, a fixed charge per output rather than by prompt length.
Can Gemini 2.5 Flash Image Edit take an existing image as input?
Yes, Gemini 2.5 Flash Image Edit accepts image input as well as a text prompt.
Who created Gemini 2.5 Flash Image Edit?
Gemini 2.5 Flash Image Edit was built by Google.
How do I call Gemini 2.5 Flash Image Edit on AI/ML API?
Send a request to https://api.aimlapi.com/v1/images/generations with gemini-25-flash-image/edit as the model id.
Is Gemini 2.5 Flash Image Edit available through a single API key?
Yes. Gemini 2.5 Flash Image Edit is served through AI/ML API, so the same key and endpoint format used for other models applies.
What is the Gemini 2.5 Flash Image Edit model ID?
Use gemini-25-flash-image/edit as the model parameter. Requests go to https://api.aimlapi.com/v1/images/generations with your AI/ML API key.



.webp)