v2

latestOpenAPI 3.1.02026-07-26262762.2 KB
Models

Generate an image with FLUX.1 [dev]

Submits an image generation task with FLUX.1 [dev].

post/v1/flux-dev

Request body

promptstring

Text prompt for image generation.

image_promptstring nullable

Optional base64 encoded image to use as a prompt for generation.

widthinteger

Width of the generated image in pixels. Must be a multiple of 32.

heightinteger

Height of the generated image in pixels. Must be a multiple of 32.

stepsinteger nullable

Number of steps for the image generation process.

prompt_upsamplingboolean

Whether to perform upsampling on the prompt. If active, automatically modifies the prompt for more creative generation.

seedinteger nullable

Optional seed for reproducibility.

guidancenumber nullable

Guidance scale for image generation. High guidance scales improve prompt adherence at the cost of reduced realism.

safety_toleranceinteger

Tolerance level for input and output moderation. Between 0 and 6, 0 being most strict, 6 being least strict.

output_format'jpeg' | 'png' | 'webp'
webhook_urlstring uri nullable

URL to receive webhook notifications

webhook_secretstring nullable

Optional secret for webhook signature verification

Example request

{
  "prompt": "ein fantastisches bild",
  "steps": 28,
  "seed": 42,
  "guidance": 3,
  "safety_tolerance": 2
}

Response

Successful Response

OR