Flux Fill Pro API
Inpaint with a mask or outpaint to extend the canvas.
Integrate Flux Fill Pro with a single API call — one key, one unified endpoint, and shared billing across every model on Apiframe.
model: "flux-fill-pro" What's special about Flux Fill Pro
- Image-to-image editing and reference-image support.
- Fast turnaround — about 15s per generation on average.
- Pay-as-you-go pricing with no Black Forest Labs account required — you only pay for successful generations.
- One API key, unified billing, idempotency and webhooks across every Apiframe model.
Made with Flux Fill Pro
A few outputs generated through the Flux Fill Pro API on Apiframe.
Overview
- Endpoint
- POST /v2/images/edit
- Model ID
- flux-fill-pro
- Params key
- fluxFillParams
- Modality
- image
- Provider
- Black Forest Labs
- Pricing
- Pay-as-you-go
- Avg. completion
- ~15s
Capabilities
Quick start
Send a single POST /v2/images/edit request with your API key to
generate with Flux Fill Pro. The call returns a jobId you can poll or
receive via webhook.
curl -X POST https://api.apiframe.ai/v2/images/edit \
-H "X-API-Key: afk_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"prompt": "a sleek silver sports car on a coastal highway at sunset, hyper-realistic",
"model": "flux-fill-pro",
"fluxFillParams": {
"image": "https://example.com/input.jpg",
"mode": "inpaint",
"mask": "https://example.com/input.jpg",
"outpaint": "Zoom out 1.5x"
}
}'import requests
response = requests.post(
"https://api.apiframe.ai/v2/images/edit",
headers={
"X-API-Key": "afk_your_api_key_here",
"Content-Type": "application/json",
},
json={
"prompt": "a sleek silver sports car on a coastal highway at sunset, hyper-realistic",
"model": "flux-fill-pro",
"fluxFillParams": {
"image": "https://example.com/input.jpg",
"mode": "inpaint",
"mask": "https://example.com/input.jpg",
"outpaint": "Zoom out 1.5x"
}
},
)
print(response.json()) # { "jobId": "...", "status": "QUEUED" }const response = await fetch("https://api.apiframe.ai/v2/images/edit", {
method: "POST",
headers: {
"X-API-Key": "afk_your_api_key_here",
"Content-Type": "application/json",
},
body: JSON.stringify({
"prompt": "a sleek silver sports car on a coastal highway at sunset, hyper-realistic",
"model": "flux-fill-pro",
"fluxFillParams": {
"image": "https://example.com/input.jpg",
"mode": "inpaint",
"mask": "https://example.com/input.jpg",
"outpaint": "Zoom out 1.5x"
}
}),
});
const { jobId } = await response.json();
console.log(jobId);Response & job lifecycle
Generation is asynchronous. A successful submission returns 202 Accepted
with a jobId. Poll GET /v2/jobs/{id} (or supply a
webhook_url) until the status is COMPLETED; the
result field then holds the output URL(s).
1. Submission response (202)
{
"jobId": "b2c3d4e5-f6a7-8901-bcde-f23456789012",
"status": "QUEUED"
}2. Poll for the result
curl https://api.apiframe.ai/v2/jobs/JOB_ID \
-H "X-API-Key: afk_your_api_key_here"import requests, time
while True:
job = requests.get(
"https://api.apiframe.ai/v2/jobs/JOB_ID",
headers={"X-API-Key": "afk_your_api_key_here"},
).json()
if job["status"] in ("COMPLETED", "FAILED"):
break
time.sleep(2)
print(job["result"])let job;
do {
await new Promise((r) => setTimeout(r, 2000));
job = await fetch("https://api.apiframe.ai/v2/jobs/JOB_ID", {
headers: { "X-API-Key": "afk_your_api_key_here" },
}).then((r) => r.json());
} while (job.status !== "COMPLETED" && job.status !== "FAILED");
console.log(job.result);Input schema
Request parameters accepted by the Flux Fill Pro endpoint. Model-specific options are nested under the params object shown below.
| Parameter | Type | Required | Default | Allowed / range | Description |
|---|---|---|---|---|---|
| prompt | string | required | — | — | Text description of what to generate. |
| model | string | required | "flux-fill-pro" | "flux-fill-pro" | The model identifier for this endpoint. |
| fluxFillParams.image | string (URL) | optional | — | — | Source image (URL) |
| fluxFillParams.mode | string | optional | "inpaint" | "inpaint", "outpaint" | Mode |
| fluxFillParams.mask | string (URL) | optional | — | — | White = repaint, black = keep. Required for inpaint. |
| fluxFillParams.outpaint | string | optional | "Zoom out 1.5x" | "Zoom out 1.5x", "Zoom out 2x", "Make square", "Left outpaint", "Right outpaint", "Top outpaint", "Bottom outpaint" | Required for outpaint mode. |
| fluxFillParams.prompt | string | optional | — | — | Prompt |
| fluxFillParams.prompt_upsampling | boolean | optional | false | — | Prompt upsampling |
| fluxFillParams.steps | number | optional | 50 | min 1, max 50, step 1 | Steps |
| fluxFillParams.guidance | number | optional | 3 | min 2, max 5, step 0.1 | Guidance |
| fluxFillParams.safety_tolerance | number | optional | 2 | min 1, max 6, step 1 | 1 = strictest, 6 = most permissive. |
| fluxFillParams.output_format | string | optional | "jpg" | "jpg", "png" | Output format |
| fluxFillParams.seed | number | optional | — | step 1 | Reuse a number to reproduce the same result. |
Frequently Asked Questions
Common questions about the Flux Fill Pro API.
Is there an API for Flux Fill Pro?
Yes. Apiframe exposes Flux Fill Pro through a single REST endpoint (`POST /v2/images/edit` with `model: "flux-fill-pro"`). You get one unified API, key, and billing across every supported model — no separate Black Forest Labs account required.
How much does the Flux Fill Pro API cost?
Flux Fill Pro uses simple pay-as-you-go pricing on Apiframe — you only pay for successful generations. See the pricing page for plans and volume discounts.
How do I call the Flux Fill Pro API?
Send a POST request to `/v2/images/edit` with your `X-API-Key` and a JSON body containing `model: "flux-fill-pro"`. The call returns a `jobId`; poll `GET /v2/jobs/{id}` or use a webhook to receive the result.
What parameters does Flux Fill Pro support?
Flux Fill Pro accepts 11 model-specific parameters (nested under `fluxFillParams`) plus the common `prompt` and `webhook_url` fields. See the input schema above for the full list with types and defaults.
Still have questions?
Start building with the Flux Fill Pro API
Get your API key and integrate Flux Fill Pro in minutes — Pay-as-you-go.
Questions? Join our Discord or contact sales.