Flux Controlnet
Generate images with multi-mode ControlNet support using Flux Dev. Supports canny edge detection, depth maps, and soft edge control types with optional LoRA models.
Quick Start
Requires an each::labs API key. Get one at eachlabs.ai.
curl -X POST https://api.eachlabs.ai/v1/prediction \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-d '{
"model": "flux-dev-controlnet",
"version": "0.0.1",
"input": {
"prompt": "a stunning watercolor painting of a mountain village at sunset",
"control_image": "https://example.com/village-photo.jpg",
"control_type": "depth",
"control_strength": 0.5,
"guidance_scale": 3.5,
"steps": 28
}
}'
Parameters
| Parameter |
Type |
Default |
Description |
| control_image |
string |
- |
Image to use with ControlNet |
| control_strength |
number |
0.5 |
Strength of ControlNet. Different controls work better at different strengths |
| control_type |
string |
depth |
Control mode. enum: canny, soft_edge, depth |
| depth_preprocessor |
string |
DepthAnything |
Depth preprocessor. enum: Midas, Zoe, DepthAnything, Zoe-DepthAnything |
| guidance_scale |
number |
3.5 |
Guidance scale |
| image_to_image_strength |
number |
0 |
Strength of image-to-image control. 0 means no control, 1 means full |
| lora_strength |
number |
1 |
Strength of LoRA model |
| lora_url |
string |
- |
Optional LoRA model URL (HuggingFace .safetensors or Replicate link) |
| negative_prompt |
string |
- |
Things you do not want to see in the image |
| output_format |
string |
webp |
Output format. enum: webp, jpg, png |
| output_quality |
integer |
80 |
Quality of output images, from 0 to 100 |
| prompt |
string |
- |
Text prompt for generation |
| return_preprocessed_image |
boolean |
false |
Return the preprocessed control image |
| seed |
integer |
- |
Set a seed for reproducibility |
| soft_edge_preprocessor |
string |
HED |
Soft edge preprocessor. enum: HED, TEED, PiDiNet |
| steps |
integer |
28 |
Number of steps |
Examples
Canny edge control:
curl -X POST https://api.eachlabs.ai/v1/prediction \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-d '{
"model": "flux-dev-controlnet",
"version": "0.0.1",
"input": {
"prompt": "a cyberpunk cityscape at night, neon lights, rain-slicked streets, ultra detailed",
"control_image": "https://example.com/city-skyline.jpg",
"control_type": "canny",
"control_strength": 0.6,
"guidance_scale": 4,
"steps": 30,
"output_format": "png"
}
}'
Soft edge with LoRA:
curl -X POST https://api.eachlabs.ai/v1/prediction \
-H "Content-Type: application/json" \
-H "X-API-Key: $EACHLABS_API_KEY" \
-d '{
"model": "flux-dev-controlnet",
"version": "0.0.1",
"input": {
"prompt": "anime style illustration of a girl in a flower garden, Studio Ghibli",
"control_image": "https://example.com/person-in-garden.jpg",
"control_type": "soft_edge",
"soft_edge_preprocessor": "HED",
"control_strength": 0.4,
"lora_url": "https://huggingface.co/my-org/anime-style-lora.safetensors",
"lora_strength": 0.8,
"steps": 35,
"seed": 42
}
}'
Related Models
Documentation
1---2name: flux-dev-controlnet3description: Flux Controlnet | Multi-Mode Controlled Image Generation. Generate images with canny, depth, or soft edge control using Flux Dev. Triggers: flux controlnet, controlnet, canny, depth, soft edge, controlled generation4---56# Flux Controlnet78Generate images with multi-mode ControlNet support using Flux Dev. Supports canny edge detection, depth maps, and soft edge control types with optional LoRA models.910## Quick Start1112> Requires an each::labs API key. Get one at [eachlabs.ai](https://eachlabs.ai).1314```bash15curl -X POST https://api.eachlabs.ai/v1/prediction \16 -H "Content-Type: application/json" \17 -H "X-API-Key: $EACHLABS_API_KEY" \18 -d '{19 "model": "flux-dev-controlnet",20 "version": "0.0.1",21 "input": {22 "prompt": "a stunning watercolor painting of a mountain village at sunset",23 "control_image": "https://example.com/village-photo.jpg",24 "control_type": "depth",25 "control_strength": 0.5,26 "guidance_scale": 3.5,27 "steps": 2828 }29 }'30```3132## Parameters3334| Parameter | Type | Default | Description |35|-----------|------|---------|-------------|36| control_image | string | - | Image to use with ControlNet |37| control_strength | number | 0.5 | Strength of ControlNet. Different controls work better at different strengths |38| control_type | string | depth | Control mode. enum: canny, soft_edge, depth |39| depth_preprocessor | string | DepthAnything | Depth preprocessor. enum: Midas, Zoe, DepthAnything, Zoe-DepthAnything |40| guidance_scale | number | 3.5 | Guidance scale |41| image_to_image_strength | number | 0 | Strength of image-to-image control. 0 means no control, 1 means full |42| lora_strength | number | 1 | Strength of LoRA model |43| lora_url | string | - | Optional LoRA model URL (HuggingFace .safetensors or Replicate link) |44| negative_prompt | string | - | Things you do not want to see in the image |45| output_format | string | webp | Output format. enum: webp, jpg, png |46| output_quality | integer | 80 | Quality of output images, from 0 to 100 |47| prompt | string | - | Text prompt for generation |48| return_preprocessed_image | boolean | false | Return the preprocessed control image |49| seed | integer | - | Set a seed for reproducibility |50| soft_edge_preprocessor | string | HED | Soft edge preprocessor. enum: HED, TEED, PiDiNet |51| steps | integer | 28 | Number of steps |5253## Examples5455**Canny edge control:**56```bash57curl -X POST https://api.eachlabs.ai/v1/prediction \58 -H "Content-Type: application/json" \59 -H "X-API-Key: $EACHLABS_API_KEY" \60 -d '{61 "model": "flux-dev-controlnet",62 "version": "0.0.1",63 "input": {64 "prompt": "a cyberpunk cityscape at night, neon lights, rain-slicked streets, ultra detailed",65 "control_image": "https://example.com/city-skyline.jpg",66 "control_type": "canny",67 "control_strength": 0.6,68 "guidance_scale": 4,69 "steps": 30,70 "output_format": "png"71 }72 }'73```7475**Soft edge with LoRA:**76```bash77curl -X POST https://api.eachlabs.ai/v1/prediction \78 -H "Content-Type: application/json" \79 -H "X-API-Key: $EACHLABS_API_KEY" \80 -d '{81 "model": "flux-dev-controlnet",82 "version": "0.0.1",83 "input": {84 "prompt": "anime style illustration of a girl in a flower garden, Studio Ghibli",85 "control_image": "https://example.com/person-in-garden.jpg",86 "control_type": "soft_edge",87 "soft_edge_preprocessor": "HED",88 "control_strength": 0.4,89 "lora_url": "https://huggingface.co/my-org/anime-style-lora.safetensors",90 "lora_strength": 0.8,91 "steps": 35,92 "seed": 4293 }94 }'95```9697## Related Models9899- [flux-canny-pro](../flux-canny-pro/) - Pro canny edge control100- [flux-depth-pro](../flux-depth-pro/) - Pro depth control101- [sdxl-controlnet](../sdxl-controlnet/) - SDXL-based ControlNet102103## Documentation104105- [each::labs Docs](https://docs.eachlabs.ai)106- [API Reference](https://docs.eachlabs.ai/api/overview)