Flux Kontext
Context-aware image generation and editing
Flux Kontext
Fast, context-aware image generation with advanced controls.
Model ID
flux-kontext
Price
$0.03-0.06/image
Speed
10-15 seconds
Type
Image
Quality Modes
| Mode | Price | Description |
|---|---|---|
pro | $0.03 | Fast, cost-effective |
max | $0.06 | Higher quality output |
Parameters
For common parameters (request_type, callback_url), see Request Format.
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
mode | string | Yes | - | pro or max |
prompt | string | Yes | - | Image description (max 10,000 characters) |
image_url | string | No | - | Reference image for editing |
aspect_ratio | string | Yes | 16:9 | Output ratio. Options: 21:9, 16:9, 4:3, 1:1, 3:4, 9:16 |
output_format | string | No | jpeg | jpeg or png |
promptUpsampling | boolean | No | false | AI prompt enhancement |
enableTranslation | boolean | No | true | Auto-translate prompts |
safetyTolerance | integer | No | 2 | Content moderation (0-2) |
watermark | string | No | - | Custom watermark text |
Examples
Text to Image
Image Editing
Tips
- Polling: Wait 8 seconds, then poll every 3 seconds
- Timeout: Set max wait to 2 minutes
- Use
profor fast iterations,maxfor final output