AI image generation
AI image generation and editing API
Describe the image you need, or upload a photo and say what to change. Get product shots, banners and post images from your own app or your AI agent, with the gpt-image models.
- Generate from text, or edit an existing photo
- About 487 credits per image
- Works with the OpenAI SDK: change the base URL and key
What people use it for
Product photos
Put a product on a clean background, or into a real-looking scene, without a photo shoot.
Banners and post images
Make images for websites, Facebook posts and ads in the size you need.
Edit a real photo
Change the background, light or setting of a photo you already have.
Images inside your app
Let your software create thumbnails, illustrations and mock-ups on demand.
Real examples
Each image below came straight from LaRouter, with no retouching.



What it costs
Usage comes out of your LaRouter allowance, counted in credits. You pay for a plan in US dollars per month; the plan gives you credits that reset every week.
- One generated or edited image
- about 487 credits, plus a little for your prompt
- Free credits every week (5,000)
- about 10 images
- Smallest plan: C300, $19/month, 75,000 credits a week
- about 150 images per week
The allowance is shared with chat and voice models on the same key. See all plans
Start in three steps
- 1
Get a key
Sign in, open the portal and create an API key. You get 5,000 free credits every week.
- 2
Let your agent do it
Install the LaRouter image skill in Claude Code or Codex, then ask: "make a hero image for my bakery website".
- 3
Or call the API
Use the OpenAI-compatible /v1/images/generations and /v1/images/edits endpoints with a gpt-image model.
Agent skill: github.com/zhuylanz/larouter-image-generation-skill
curl https://i-larouter.lapage.vn/v1/images/generations \
-H "Authorization: Bearer $LAROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"gpt-image-2","prompt":"A terracotta ceramic cup, studio product photo","size":"1536x1024"}'import base64
from openai import OpenAI
client = OpenAI(base_url="https://i-larouter.lapage.vn/v1", api_key="YOUR_API_KEY")
img = client.images.generate(
model="gpt-image-2", prompt="A terracotta ceramic cup, studio product photo", size="1536x1024"
)
open("cup.png", "wb").write(base64.b64decode(img.data[0].b64_json))Questions
Which models can I use?
The gpt-image family, including gpt-image-2 and gpt-image-2.5. The /v1/models endpoint lists every model on your key.
Can I edit my own photos?
Yes. Send the photo to /v1/images/edits with a prompt that says what to change, as in the café example above.
Which sizes are supported?
Square 1024x1024, landscape 1536x1024 and portrait 1024x1536, among others.
Is it compatible with the OpenAI image API?
Yes. Code written for the OpenAI image endpoints works after you change the base URL and key.
Do I need a credit card to try it?
No. Sign in and you get 5,000 free credits every week, enough for about 10 images.
Can I use the images commercially?
Yes. You can use generated images commercially, for example for product shots, banners or ads. You are responsible for the content you create.
Make your first image in a few minutes
Sign in, create a key and try it on the free credit.
Get a free key