Claude Opus 5.5 is live on SeedRouter

Image

FLUX 3 Image Klein

View Markdown

Generate or edit one image with up to ten reference URLs, five resolution tiers, and asynchronous task results.

Quick example

Submit one image request, save the returned id, and poll until the task is completed or failed. This API uses asynchronous tasks and URL outputs.

curl https://api.seedrouter.ai/v1/images/generations \
  -H "Authorization: Bearer $SEEDROUTER_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{"model":"flux-3-image-klein","prompt":"An amber bottle on pale limestone in soft morning light","resolution":"1k","aspect_ratio":"3:2"}'

Endpoint and headers

POST https://api.seedrouter.ai/v1/images/generations

HeaderValue
AuthorizationBearer YOUR_API_KEY
Content-Typeapplication/json

Keep the key on your server. An HTTP success acknowledges a task; it does not mean that its image is ready.

Parameters

There are 11 accepted fields. Only model and prompt are required. Omit optional fields to use their defaults; null is not accepted.

FieldTypeDefaultConstraint
modelstringRequiredflux-3-image-klein
promptstringRequiredNon-empty image description or edit instruction
image_urlsstring arrayNoneAt most 10 public HTTP(S) image URLs, without credentials; empty array means no references
aspect_ratiostringautoA listed ratio; also accepts forms such as 16x9
sizestringNoneCompatibility alias for aspect ratio; prefer aspect_ratio and send only one
resolutionstring1k768sq, 1k, 1.5k, 2k, 4k; case insensitive; 768 aliases 768sq
safety_toleranceinteger20–4; 0 is strictest
seedintegerRandom0–4294967295; explicit 0 is preserved
stepsinteger161–16
output_formatstringjpegjpeg, png; jpg aliases jpeg
ninteger1Only 1

Ratios: auto, 21:9, 2:1, 16:9, 3:2, 7:5, 4:3, 5:4, 1:1, 4:5, 3:4, 5:7, 2:3, 9:16, 1:2, 9:21.

The Playground has a fixed model and ten input controls, including n fixed at 1. Safety values above 2 are API only, except for administrators.

Modes and constraints

No references means text-to-image. One reference enables editing; multiple references enable composition from several images. With auto, edits follow the first reference's aspect ratio. Text-only generation uses the prompt to select a frame, falling back to 1:1 when no frame is determined. Resolution defaults to 1k in every mode.

Resolution tiers represent approximate image scale: 768sq is about 768 × 768; 1K is about 1 MP; 1.5K about 2 MP; 2K about 4 MP; 4K about 16 MP. Inspect the returned file for actual dimensions.

This endpoint does not accept width, height, pixel dimensions in size, negative_prompt, guidance, grounding, prompt_upsampling, mask, or mask_url. Unknown fields return HTTP 400 before billing. WebP output, base64 input, streaming, and callbacks are not offered.

Reference images and regional edits

Upload references to a public URL before submitting. The request body contains URLs, never file bytes or data URLs.

{
  "model": "flux-3-image-klein",
  "prompt": "Use Image 1 as the subject and Image 2 as the setting; match the perspective and light",
  "image_urls": ["https://example.com/subject.png", "https://example.com/setting.png"],
  "aspect_ratio": "auto",
  "resolution": "2k",
  "seed": 0,
  "steps": 16,
  "output_format": "png"
}

Replace these placeholder URLs with your own accessible images. References are ordered: ref_image_0 is the first. Bounding-box instructions are part of the prompt string, not a separate request field. Coordinates use [y1, x1, y2, x2] normalized to 0–1000. A layout object can contain id, bbox, and desc; an edit can use id, from, src_bbox, tgt_bbox, and desc. JSON-encode the complete request so quotes inside the prompt are escaped correctly.

Billing

One successful request is one image. The selected resolution alone sets the price; steps, seed, aspect ratio, reference count, and format do not add fees. Text-to-image and editing have the same rate. Failed requests are not charged. See live pricing.

Task response and polling

Submission:

{"id":"task_example","model":"flux-3-image-klein","status":"processing"}
curl https://api.seedrouter.ai/v1/tasks/task_example \
  -H "Authorization: Bearer $SEEDROUTER_API_KEY"

Completed task (illustrative URL):

{
  "id": "task_example",
  "model": "flux-3-image-klein",
  "status": "completed",
  "output": {"data": [{"url": "https://file.deepytb.com/generated/example.png"}]}
}

Read output.data[0].url. Allow up to ten minutes for generation, especially at 4K. Polling is read-only; a client timeout is not permission to submit another paid request. Public task responses do not include costs or account balances.

Errors

HTTP errors use {"error": {"code": integer, "message": string}}. See the shared error directory. A failed task exposes its error alongside status: "failed". Correct invalid parameters before resubmitting; retain the task ID when checking a submitted request.

Use positive descriptions and name the regions or details to preserve. Lower steps may alter quality without reducing the price. Compare one change at a time.