Seedream 5.0 Pro jest już LIVE | Wypróbuj w Generator obrazów →

Flux Controlnet Union Pro 2.0

wavespeed-ai /

Flux ControlNet Union Pro 2.0 enables simultaneous Canny, Depth, Soft Edge, Pose, and Grayscale conditioning for precise image control. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing.

image-to-image
Wejście

Bezczynny

A robot is giving a speech.

$0.03za uruchomienie·~33 / $1

Dalej:

PrzykładyZobacz wszystkie

A robot is giving a speech.

A robot is giving a speech.

Realistic full-body shot of a detective in a classic 1940s outfit, wearing a fedora and trench coat, cigarette in mouth, standing beside a vintage car in a rain-soaked alley, warm orange streetlights casting dramatic shadows

Realistic full-body shot of a detective in a classic 1940s outfit, wearing a fedora and trench coat, cigarette in mouth, standing beside a vintage car in a rain-soaked alley, warm orange streetlights casting dramatic shadows

A write boy blowing bubbles in the park on a sunny afternoon, vivid colors, cinematic composition, sharp focus, realistic skin textures, shallow depth of field

A write boy blowing bubbles in the park on a sunny afternoon, vivid colors, cinematic composition, sharp focus, realistic skin textures, shallow depth of field

A smiling young woman in a sunlit field, wearing a flowing yellow dress, realistic lighting, bright colors, ultra-detailed face, high-resolution, photo-realistic

A smiling young woman in a sunlit field, wearing a flowing yellow dress, realistic lighting, bright colors, ultra-detailed face, high-resolution, photo-realistic

a red fox standing quietly in a foggy forest, early morning light, soft shadows, cinematic atmosphere, depth of field, ultra detailed fur, natural colors, no humans

a red fox standing quietly in a foggy forest, early morning light, soft shadows, cinematic atmosphere, depth of field, ultra detailed fur, natural colors, no humans

a single goldfish swimming inside a floating glass orb, suspended in the air, surrounded by gentle water ripples, soft glowing background, photorealistic, highly detailed, no people

a single goldfish swimming inside a floating glass orb, suspended in the air, surrounded by gentle water ripples, soft glowing background, photorealistic, highly detailed, no people

a person holding a transparent umbrella, walking in the rain, viewed from behind, city lights reflected on wet ground, night mood, soft bokeh, no face visible

a person holding a transparent umbrella, walking in the rain, viewed from behind, city lights reflected on wet ground, night mood, soft bokeh, no face visible

a girl walking alone on a beach at sunset, seen from behind, footprints in the sand, golden light reflecting on the ocean, emotional tone, no face

a girl walking alone on a beach at sunset, seen from behind, footprints in the sand, golden light reflecting on the ocean, emotional tone, no face

a person sitting by a large window in a library, reading a book, viewed from behind, warm ambient lighting, soft dust in the air, calm atmosphere, no facial features

a person sitting by a large window in a library, reading a book, viewed from behind, warm ambient lighting, soft dust in the air, calm atmosphere, no facial features

a boy riding a bicycle down a country road, viewed from behind, late afternoon, sun filtering through trees, motion blur on background, gentle atmosphere, no face visible

a boy riding a bicycle down a country road, viewed from behind, late afternoon, sun filtering through trees, motion blur on background, gentle atmosphere, no face visible

Powiązane modele

README

FLUX ControlNet Union Pro 2.0 — wavespeed-ai/flux-controlnet-union-pro-2.0

FLUX ControlNet Union Pro 2.0 is a ControlNet-guided image generation model that lets you lock in structure using a control image while still following your text prompt for style and details. Upload a control_image (e.g., pose/shape/edge-like guidance), describe what you want to create, and the model generates images that respect the control geometry—ideal for pose fidelity, layout consistency, and repeatable compositions. It also supports optional LoRAs (up to 3) to further steer style.

Key capabilities

  • ControlNet-guided generation using a required control_image
  • Strong structure fidelity: keeps pose/layout consistent across generations
  • Prompt-driven styling: change appearance, materials, lighting, and mood while keeping geometry
  • Fine control over when/how much control is applied via conditioning and guidance range
  • LoRA support (up to 3) for consistent styles or specialized looks

Use cases

  • Pose-locked character generation from a silhouette/pose control image
  • Recreating the same composition in multiple art styles for A/B creative testing
  • Storyboarding with consistent framing and character blocking
  • Product mockups with fixed layout and controllable styling
  • Batch generation with a “house style” using LoRAs while keeping geometry stable

Pricing

OutputPrice
Per image$0.03

Inputs

  • prompt (required): what to generate (subject, scene, style)
  • control_image (required): the structural guide image

Parameters

Core:

  • prompt: text instruction for content and style
  • control_image: structural guidance image
  • width / height: output size
  • num_inference_steps: sampling steps (higher can improve detail but increases latency)
  • guidance_scale: prompt adherence strength
  • seed: fixed value for reproducibility; change for variation
  • num_images: number of outputs per run
  • output_format: jpeg or png
  • enable_base64_output: return BASE64 instead of URL (API only)
  • enable_sync_mode: wait for generation and return results directly (API only)

ControlNet:

  • controlnet_conditioning_scale: strength of control_image guidance (higher = stricter structure)
  • control_guidance_start: when control starts applying (0–1 timeline)
  • control_guidance_end: when control stops applying (0–1 timeline)

LoRA (up to 3 items):

  • loras: list of LoRA entries (max 3)

  • path: owner/model-name or a direct.safetensors URL

  • scale: LoRA strength (start moderate and adjust)

Prompting guide

A reliable pattern is “structure + subject + style”:

Template: Using the control image for pose/layout, generate [subject] in [scene]. Style: [style cues]. Lighting: [lighting cues]. Keep composition consistent with the control image.

Example prompts

  • Using the control image for pose, generate a robot giving a speech at a podium, cinematic lighting, shallow depth of field, high detail, realistic materials.
  • Using the control image for layout, generate a fantasy wizard on a stage, glowing runes, volumetric fog, dramatic rim light, illustrated style.
  • Using the control image for silhouette, generate a sleek product hero shot with glossy reflections and a clean studio background.

Reference

Uwaga:Ta strona korzysta z modeli AI udostępnianych przez podmioty trzecie.

Flux Controlnet Union Pro 2.0 API — Quick start

Grab a WaveSpeedAI API key, then call POST https://api.wavespeed.ai/api/v3/wavespeed-ai/flux-controlnet-union-pro-2.0 with your input as JSON. The endpoint returns a prediction id. Start polling the result endpoint around every 2 seconds, increase the interval for long-running tasks, and stop on any terminal status. On completed, read output values from data.outputs. Examples for Flux Controlnet Union Pro 2.0 below.

HTTP example
set -euo pipefail

: "${WAVESPEED_API_KEY:?Set WAVESPEED_API_KEY}"

REQUEST_BODY=$(cat <<'JSON'
{
    "prompt": "A cinematic shot of a city at sunset, soft golden light",
    "control_image": "https://interactive-examples.mdn.mozilla.net/media/cc0-images/painted-hand-298-332.jpg",
    "size": "1024*1024",
    "num_inference_steps": 28,
    "guidance_scale": 3.5,
    "controlnet_conditioning_scale": 0.7,
    "control_guidance_start": 0,
    "control_guidance_end": 0.8,
    "seed": 0,
    "num_images": 1,
    "output_format": "jpeg"
}
JSON
)

# 1. Submit the prediction.
SUBMIT_RESPONSE=$(curl --silent --show-error --fail-with-body \
  -X POST "https://api.wavespeed.ai/api/v3/wavespeed-ai/flux-controlnet-union-pro-2.0" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $WAVESPEED_API_KEY" \
  -d "$REQUEST_BODY")

TASK=$(printf '%s' "$SUBMIT_RESPONSE" | jq 'if has("data") then .data else . end')
PREDICTION_ID=$(printf '%s' "$TASK" | jq -r '.id')
if [ -z "$PREDICTION_ID" ] || [ "$PREDICTION_ID" = "null" ]; then
  printf 'Submission response did not contain a prediction id
' >&2
  exit 1
fi
RESULT_URL=$(printf '%s' "$TASK" | jq -r '.urls.get // empty')
if [ -z "$RESULT_URL" ]; then
  RESULT_URL="https://api.wavespeed.ai/api/v3/predictions/$PREDICTION_ID/result"
fi

# 2. Poll until the prediction finishes.
while true; do
  RESPONSE=$(curl --silent --show-error --fail-with-body "$RESULT_URL" \
    -H "Authorization: Bearer $WAVESPEED_API_KEY")
  RESULT=$(printf '%s' "$RESPONSE" | jq 'if has("data") then .data else . end')
  STATUS=$(printf '%s' "$RESULT" | jq -r '.status')
  case "$STATUS" in
    completed) printf '%s\n' "$RESULT" | jq '.outputs'; break ;;
    failed|cancelled|timeout) printf '%s\n' "$RESULT" | jq . >&2; exit 1 ;;
    created|processing) sleep 2 ;;
    *) printf 'Unexpected status: %s
' "$STATUS" >&2; exit 1 ;;
  esac
done
Node.js example
const submitUrl = "https://api.wavespeed.ai/api/v3/wavespeed-ai/flux-controlnet-union-pro-2.0";
const apiKey = process.env.WAVESPEED_API_KEY;
if (!apiKey) throw new Error('Set WAVESPEED_API_KEY');

async function requestJson(url, options = {}) {
  const response = await fetch(url, options);
  if (!response.ok) throw new Error(await response.text());
  return response.json();
}

// 1. Submit the prediction.
const body = await requestJson(submitUrl, {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
        "prompt": "A cinematic shot of a city at sunset, soft golden light",
        "control_image": "https://interactive-examples.mdn.mozilla.net/media/cc0-images/painted-hand-298-332.jpg",
        "size": "1024*1024",
        "num_inference_steps": 28,
        "guidance_scale": 3.5,
        "controlnet_conditioning_scale": 0.7,
        "control_guidance_start": 0,
        "control_guidance_end": 0.8,
        "seed": 0,
        "num_images": 1,
        "output_format": "jpeg"
}),
});
const task = body.data ?? body;
if (!task.id) throw new Error("Submission response did not contain a prediction id");
const resultUrl = task.urls?.get ||
  `https://api.wavespeed.ai/api/v3/predictions/${task.id}/result`;

// 2. Poll until the prediction finishes.
while (true) {
  const resultBody = await requestJson(resultUrl, {
    headers: { "Authorization": `Bearer ${apiKey}` },
  });
  const result = resultBody.data ?? resultBody;
  if (result.status === "completed") {
    console.log(result.outputs);
    break;
  }
  if (["failed", "cancelled", "timeout"].includes(result.status)) throw new Error(JSON.stringify(result));
  if (!["created", "processing"].includes(result.status)) throw new Error("Unexpected status: " + result.status);
  await new Promise(resolve => setTimeout(resolve, 2000));
}
Python example
import json
import os
import time
from urllib.request import Request, urlopen

api_key = os.environ["WAVESPEED_API_KEY"]
headers = {"Authorization": f"Bearer {api_key}", "Content-Type": "application/json"}
payload = {
    "prompt": "A cinematic shot of a city at sunset, soft golden light",
    "control_image": "https://interactive-examples.mdn.mozilla.net/media/cc0-images/painted-hand-298-332.jpg",
    "size": "1024*1024",
    "num_inference_steps": 28,
    "guidance_scale": 3.5,
    "controlnet_conditioning_scale": 0.7,
    "control_guidance_start": 0,
    "control_guidance_end": 0.8,
    "seed": 0,
    "num_images": 1,
    "output_format": "jpeg"
}

def request_json(url, data=None):
    request = Request(url, data=data, headers=headers, method="POST" if data else "GET")
    with urlopen(request) as response:
        return json.load(response)

# 1. Submit the prediction.
body = request_json("https://api.wavespeed.ai/api/v3/wavespeed-ai/flux-controlnet-union-pro-2.0", json.dumps(payload).encode())
task = body.get("data", body)
if not task.get("id"):
    raise RuntimeError("Submission response did not contain a prediction id")
result_url = task.get("urls", {}).get("get") or f"https://api.wavespeed.ai/api/v3/predictions/{task['id']}/result"

# 2. Poll until the prediction finishes.
while True:
    result_body = request_json(result_url)
    result = result_body.get("data", result_body)
    status = result.get("status")
    if status == "completed":
        print(result.get("outputs", []))
        break
    if status in {"failed", "cancelled", "timeout"}:
        raise RuntimeError(result)
    if status not in {"created", "processing"}:
        raise RuntimeError(f"Unexpected status: {status}")
    time.sleep(2)

Flux Controlnet Union Pro 2.0 API — Frequently asked questions

What is the Flux Controlnet Union Pro 2.0 API?

Flux Controlnet Union Pro 2.0 is a WaveSpeedAI model for image editing, exposed as a REST API on WaveSpeedAI. Flux ControlNet Union Pro 2.0 enables simultaneous Canny, Depth, Soft Edge, Pose, and Grayscale conditioning for precise image control. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing. You can call it programmatically or try it from the playground above.

How do I call the Flux Controlnet Union Pro 2.0 API?

POST your input parameters to the model's REST endpoint (shown in the API tab of this playground) with your WaveSpeedAI API key in the Authorization header. Submission returns a prediction ID. Poll the result endpoint starting around every 2 seconds, increase the interval for long-running tasks, and stop on any terminal status. The playground generates production-oriented Python, JavaScript, and cURL examples with timeouts, transient-error handling, and safe GET retries. Full request/response shape is documented at https://wavespeed.ai/docs/docs-api/wavespeed-ai/flux-controlnet-union-pro-2.0.

How much does Flux Controlnet Union Pro 2.0 cost per run?

Flux Controlnet Union Pro 2.0 starts at $0.030 per run. That figure is the base price — the final charge scales with the parameters you set in the form (output size, length, count, references, or whatever knobs this model exposes), so a higher-quality or larger output costs more than a minimal one. The exact cost for your current input is shown live next to the Generate button before you submit, and the actual per-call charge is recorded on the prediction afterwards.

What inputs does Flux Controlnet Union Pro 2.0 accept?

Key inputs: `prompt`, `size`, `seed`, `guidance_scale`, `num_inference_steps`, `control_guidance_end`. The full JSON schema (types, defaults, allowed values) is rendered above the Generate button and mirrored in the API reference at https://wavespeed.ai/docs/docs-api/wavespeed-ai/flux-controlnet-union-pro-2.0.

How long does Flux Controlnet Union Pro 2.0 take to generate?

Median end-to-end generation time on WaveSpeedAI is around 7 seconds per request, based on recent successful runs. Queue time varies with global demand; live status is visible in the prediction record.

Can I use Flux Controlnet Union Pro 2.0 outputs commercially?

Commercial usage rights depend on the model's license, set by its provider (WaveSpeedAI). The license summary appears on the model card above; see WaveSpeedAI's Terms of Service for platform-level conditions.

Flux Controlnet Union Pro 2.0 | Fast Image Editing API | WaveSpeedAI