Generate high-quality AI images using the Flux.2 Flex model with support for up to 10 reference images.
Pricing
| Quality | Price |
|---|
| 1K | $0.04 |
| 2K | $0.06 |
Request
curl -X POST "https://api.unifically.com/flux.2-flex/generate" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"prompt": "A beautiful sunset over mountains",
"image_urls": ["https://example.com/ref1.jpg"],
"aspect_ratio": "16:9",
"quality": "2K"
}'
Parameters
Required Parameters
Text description of the image to generate
Optional Parameters
Array of reference image URLs to guide generationMaximum: 10 images
Aspect ratio of the generated imageOptions: "auto", "1:1", "4:3", "16:9", "3:2", "2:3", "9:16", "3:4"Default: "auto"
Output image quality/resolutionOptions: "1K", "2K"Default: "1K"
URL to receive webhook notification on completion
Flex-only Optional Parameters
Quality steps for generation. More steps = higher quality but longer generation time.Range: 1-50
Prompt strength. Higher value limits creativity and follows prompt more strictly.Range: 1.5-10
Response
{
"code": 200,
"data": {
"status": "processing",
"task_id": "dd55ae25-adff-47a0-9194-6a37845b58e4"
}
}
Response Fields
HTTP status code (200 for success)
Response dataUnique identifier for this generation task
Task status (e.g., “processing”)