by Black Forest Labs

FLUX.2 Klein 4B LoRA edit API: redraw a photo in a LoRA style or change its time of day from 1 to 3 references, seconds per image, flat price.

black-forest-labs/flux-2-klein-4b-lora/edit
FLUX.2 Klein 4B LoRA AI Image Generator online
  • Up to 2K
  • Up to 3 reference images
  • 9 aspect ratios
  • Loads your own LoRA
  • Create Image
  • Edit Image

About FLUX.2 Klein 4B LoRA

FLUX.2 Klein 4B LoRA edit takes a prompt, one to three image_urls and up to three loras, and returns quickly.

Call it with the model name black-forest-labs/flux-2-klein-4b-lora/edit on POST /jobs/createTask, from $0.0204.

Introduction

FLUX.2 Klein 4B LoRA Image edit changes or combines up to three source images with a written instruction on Black Forest Labs' FLUX.2 [klein] 4B, with up to three of your own LoRA files loaded. Keep the shape of your first image with auto, or choose one of nine ratios and a 1k or 2k size tier.

Choose a mode by starting material

What you haveMode
one to three pictures to change or combineFLUX.2 Klein 4B LoRA Image edit
a written description onlyFLUX.2 Klein 4B LoRA Text to image

Key features

Edits that follow the instruction

Change light, clothes or setting and keep faces and pose. In our tests the distilled build followed our edit instructions closely.

Restyle with a LoRA

Load a style LoRA and ask for a redraw: a diner photo came back as a colored-pencil drawing with the woman and her dress kept.

Up to three sources

Combine a portrait with an outfit or a location. Name the sources as image 1, image 2 and image 3; faces can drift a little when you combine them.

Request parameters

ParameterRequiredDescription
aspect_ratioNoThe shape of the frame: wide, square or tall. auto · 1:1 · 16:9 · 9:16 · 4:3 · 3:4 · 3:2 · 2:3 · 21:9 · 9:21 · Default: auto
image_urlsYesPhotos to edit or combine. Say in the prompt what each one adds.
lorasNoAdd LoRA weights compatible with this model to guide its style or character. Default: []
promptYesDescribe what you want to make.
resolutionNoChoose an available output size. 1k · 2k · Default: 1k
seedNoUse the same seed and settings for more controlled comparisons. ≥ 0 · ≤ 2147483647

Pricing

Prices are in USD and charged to your PopNow balance. When a task is accepted, we reserve the maximum quoted amount from your PopNow balance. On completion, we charge for actual usage, never more than the hold, and release the remainder. If the task fails, the hold is released.

OptionUSD per image
Standard$0.0204

Send the same request body to POST /jobs/quote to see the estimated and maximum USD charge before running. A quote does not run the task or charge your balance.

Use cases

Outfit and setting swaps

Put a person from one photo into a dress from another and a new place, in one request. Name the portrait as image 1 and the outfit as image 2, and say where the scene happens.

Reframing and relighting

Pick a wider ratio than the source and describe what should fill the new space, or keep auto and move a daytime photo to blue hour with one sentence about the light.

Prompt guide & pro tips

Protect first, change second

Open with what must stay (face, hair, pose), then describe the change. Short, concrete instructions work best.

Use auto to keep the shape

Auto keeps the first source's shape at about one megapixel. Choose a ratio only when you want the frame recomposed.

Compare against no LoRA

Run the same prompt and seed without the LoRA. If the results look identical, check that the LoRA was trained for FLUX.2 [klein] 4B and review its trigger phrase. LoRAs for other base models, including FLUX.1 and the 9B Klein models, may load without an error but have no visible effect here.

Use direct, public links

The link must download the .safetensors file itself.

API quick start

Call the FLUX.2 Klein 4B LoRA API in three steps

  1. Create an API key. Sign in to PopNow and create a key in the API console. Keys start with sk-popnow-. API calls are billed in USD from your PopNow balance.
  2. Send the request. POST /jobs/createTask with model black-forest-labs/flux-2-klein-4b-lora/edit and an input object that follows the parameter table. The response returns a task ID straight away.
  3. Get the result. Poll GET /jobs/recordInfo with the task ID, or pass a callBackUrl and we post the result to it. Download the output links when the task succeeds.
# 1. Create the task. Keep the Idempotency-Key if you retry after a network error.
export IDEMPOTENCY_KEY="$(uuidgen)"
curl -X POST https://api.popnow.ai/api/v1/jobs/createTask \
  -H "Authorization: Bearer $POPNOW_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $IDEMPOTENCY_KEY" \
  -d '{
  "model": "black-forest-labs/flux-2-klein-4b-lora/edit",
  "input": {
    "prompt": "A ceramic teapot on a linen cloth, soft window light, muted palette",
    "image_urls": [
      "https://media.popnow.ai/influencer/examples/marco.webp"
    ],
    "aspect_ratio": "auto",
    "resolution": "1k"
  }
}'

# 2. Copy data.taskId from the response, then poll until state is succeeded, failed, canceled or expired.
TASK_ID="TASK_ID_FROM_RESPONSE"
curl "https://api.popnow.ai/api/v1/jobs/recordInfo?taskId=$TASK_ID" \
  -H "Authorization: Bearer $POPNOW_API_KEY"

Replace the prompt and any links with your own. The API tab has the response, polling and callback reference.

About the FLUX.2 Klein 4B LoRA Edit Image endpoint

It is well suited to redrawing a photo in an illustration style while keeping the person and setting.

A restyle and one scene change, such as daytime to blue hour, can be combined in one instruction.

Text in the frame is unreliable at this size, so avoid edits that depend on readable signs.

Hold the seed while tuning strength so results stay comparable.

Because results return in seconds, you can show users several seeds side by side and let them pick before upscaling elsewhere.

LoRAs made for Klein 9B or FLUX.1 load without errors but have no effect, so tag stored LoRAs by base model.

Because each edit returns in seconds, a good UX is to render three seeds at once and let the user choose, instead of asking them to rewrite the prompt.

In our diner test, a coloured pencil LoRA redrew a daytime photo as a blue-hour drawing while her face, the counter and the window framing carried over.

Typical latency is a few seconds, so this endpoint can sit behind a live preview that re-renders whenever the user changes the instruction.

FLUX.2 Klein 4B LoRA API questions

How much does the FLUX.2 Klein 4B LoRA API cost?

FLUX.2 Klein 4B LoRA starts at $0.0204 per image with Edit Image, its lowest-priced task. API usage is charged in USD to your PopNow balance. When a task is accepted, we reserve the maximum quoted amount from your PopNow balance. On completion, we charge for actual usage, never more than the hold, and release the remainder. If the task fails, the hold is released.

What are the limits of the FLUX.2 Klein 4B LoRA · Edit Image API?

Resolutions: 1K · 2K; Aspect ratios: auto · 1:1 · 16:9 · 9:16 · 4:3 · 3:4 +4; Reference images: 3; Prompt length (characters): 5,000; Largest upload: 10 MB. Requests outside these limits are rejected before anything is charged.

More about FLUX.2 Klein 4B LoRA