FLUX.1 Kontext [dev]
bfl/flux-2/kontext/devFlux 2 Kontext Dev by BFL - AI-powered image editing, style transfer, and transformation. Edit photos with natural language instructions, remove backgrounds, change styles, and enhance images effortlessly.
- Base price
- $0.0013USD / run
- Execution
- async
- Model type
- image
- Input fields
- 7
Try the model
Playground
PNG, JPEG, WebP, or GIF · 20 MiB maximum
Your output will appear here
Complete the inputs, then click Run.
Specifications
Pricing
- Base price
- $0.0013 / run
Context & modalities
- Input
- Schema-defined
- Output
- image
Capabilities
- Chat
- Not supported
- Vision
- Not supported
- Reasoning
- Not supported
- Structured output
- Not supported
- Function calling
- Not supported
- Audio input
- Not supported
Access
- Provider
- BFL
- Model ID
- bfl/flux-2/kontext/dev
- Execution
- async
- API
- Unified Run API
- Endpoint
- /v1/run
API README
FLUX.1 Kontext [dev]
FLUX.1 Kontext [dev] edits and enhances photos from natural-language instructions. A required image supplies the visual foundation and a required prompt communicates the revision, creating a direct path from an existing asset to an updated one.
Guidance can be adjusted from 1 to 20 and inference steps from 10 to 50. The model also offers resolution modes including automatic, input-matched, square, landscape, and portrait choices, plus JPEG or PNG export and seed control.
Highlights
Photo-first revision. Begin with a required image so the edit remains connected to an existing asset.
Written creative direction. Use a required prompt to describe the change or enhancement in natural language.
Broad refinement controls. Tune guidance from 1–20 and inference steps from 10–50 for the intended generation pass.
Resolution and export choices. Select an automatic, input-matched, or fixed resolution mode, then export JPEG or PNG with an optional seed.
Pricing
| Billing unit | Price |
|---|---|
| Per request | $0.00125 |
When to Use
| ✅ Good fit | ❌ Consider alternatives |
|---|---|
| The model's named workflow matches the source material and intended output | A different input modality or model route is required |
| A managed asynchronous result is suitable for the production pipeline | A synchronous, interactive editor is essential |
| The documented controls cover the required duration, framing, or format | The project needs controls outside this endpoint's schema |
| Creative iteration benefits from a repeatable request structure | Exact deterministic pixels, frames, geometry, or samples are mandatory |
| A finished downloadable media asset is the desired deliverable | Editable source layers or a native project file are required |
Prompt Guide
For image-conditioned generation, state the intended result first, then add the subject or source treatment, progression, style, and delivery constraints. Keep one creative variable per phrase, use the documented field names for controls, and change one setting at a time when comparing results.
{
"image": "https://example.com/start-frame.png",
"output_format": "jpeg",
"prompt": "Change the setting to a day time, add a lot of people walking the sidewalk while maintaining the same style of the painting"
}
Technical Specs
| Spec | Value |
|---|---|
| Model ID | bfl/flux-2/kontext/dev |
| Inputs | guidance_scale, image, num_inference_steps, output_format, prompt, resolution_mode, seed |
| Required inputs | prompt, image |
| Output fields | content_type, url |
| Execution | Async (submit, then poll for result) |
| Output Format | jpeg / png |
Related Models
bfl/flux-2/kontext/max/multi— Compare this concrete local family route.bfl/flux-2/kontext/max/text-to-image— Compare this concrete local family route.bfl/flux-2/kontext/pro/multi— Compare this concrete local family route.
Start building
Send your first request
OpenAI-compatible endpoint with unified authentication and usage tracking.
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1/run" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"model": "bfl/flux-2/kontext/dev",
"image": "https://static.sandbase.ai/examples/bfl/flux-2/kontext/dev/input_image_0.webp",
"prompt": "Change the setting to a day time, add a lot of people walking the sidewalk while maintaining the same style of the painting",
"output_format": "jpeg",
"guidance_scale": 2.5,
"resolution_mode": "match_input",
"num_inference_steps": 28
}
SANDBASE_JSON
)
run_id=$(printf '%s' "$result" | jq -r .id)
for attempt in $(seq 1 120); do
status=$(printf '%s' "$result" | jq -r .status)
case "$status" in completed|failed|timeout) break ;; esac
sleep 2
result=$(curl --fail-with-body --silent \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
"https://api.sandbase.ai/v1/run/$run_id")
done
status=$(printf '%s' "$result" | jq -r .status)
[ "$status" = completed ] || { echo "Generation ended: $status" >&2; exit 1; }
printf '%s\n' "$result"Choose your model
Compare models
| Model | Context | Input / 1M | Output / 1M | Released |
|---|---|---|---|---|
FLUX.1 Kontext [dev]This model BFL | — | — | — | May 28, 2025 |
BFL | — | — | — | May 28, 2026 |
BFL | — | — | — | May 21, 2026 |
BFL | — | — | — | May 14, 2026 |
BFL | — | — | — | Mar 17, 2026 |
BFL | — | — | — | Mar 17, 2026 |
