Image models › Qwen
Qwen 2.1 - Image to Image
Qwen 2.1 - Image to Image
image Qwen price on request
Request
POST https://app.video-blade.com/api/v1/generations
X-API-Key: vb_…
Content-Type: application/json
{
"callback_url": "https://your-app.example/callbacks/video-blade",
"input": {
"image_urls": "\u2026",
"prompt": "\u2026"
},
"model": "qwen2-1-image-to-image"
}
Input parameters
| Name | Type | Required | Description |
|---|---|---|---|
image_urls |
array | required | Reference images, given as an array of 1 to 10 http(s) URLs. Required. The order of the array is the order the prompt refers to ("the first image", "the second image"). JPEG, PNG and WebP are supported, up to 30MB and 25MP each, and every URL must be directly retrievable with a GET — a reference the origin refuses with 4xx, or whose domain does not resolve, fails the request with 400. More than 10 entries returns 422. The more references you supply the less detail each individual one keeps, so stay within 4 when fidelity matters. When combining several people or objects into a single picture, |
prompt |
string | required | The prompt describing the result you want. Required. Any language is supported, up to 5000 characters; longer input returns 422. When `mask_url` is supplied, use it to describe what should be generated inside the white area of the mask. |
mask_url |
string | optional | Inpainting mask that switches the request into local-edit mode. A black and white image where **white marks the area to change and black is kept unchanged**, with a few pixels of feathering along the boundary. It must be used with exactly one entry in `image_urls`, otherwise the request returns 422. The mask should have the same aspect ratio as that reference image; a mask of a different size is scaled to it. In local-edit mode the output ratio follows the reference image, so `aspect_ratio` and `enhance_prompt` are ignored and reported in the `ignored` field of the result. It cannot be combine |
aspect_ratio |
string | optional | Output aspect ratio. Defaults to `auto`, which takes the aspect ratio of the first reference image and snaps it to the nearest supported ratio. The actual pixel size also depends on `resolution` — see the aspect ratio table above. Ignored in local-edit mode. Values: auto, 1:1, 4:3, 3:4, 3:2, 2:3, 16:9, 9:16, 21:9, 9:21Default:
auto |
resolution |
string | optional | Output resolution tier. `1K` is the faster option; `2K` produces four times the pixels and takes considerably longer, up to about 3 minutes with reference images. Only `1K` and `2K` are accepted — any other value, including `4K`, returns 422. Values: 1K, 2KDefault:
1K |
background |
string | optional | Background type. transparent outputs a PNG or WebP with a real alpha channel and cannot be used with JPEG. When using transparent, describe only the subject — prompts that mention a background, scene, surface, etc. may produce a non-transparent result. Values: opaque, transparentDefault:
opaque |
output_format |
string | optional | Output image format. `png` (default) and `webp` both carry an alpha channel and can be used with `background: transparent`. `jpeg` has no alpha channel and cannot be combined with a transparent background. Values: png, webp, jpegDefault:
png |
enhance_prompt |
boolean | optional | Rewrites the prompt into a fuller scene description before generating, which noticeably improves quality. Enabled by default (also when the parameter is omitted); pass false to turn it off. Default:
True |
seed |
integer | optional | The random seed. Omit it to generate with a random seed; the seed actually used is returned with the result. Passing the same seed together with the same prompt and parameters reproduces the same image within the same service version. |
nsfw_checker |
boolean | optional | Defaults to false. You can set it to false based on your needs. If set to false, our content filtering will be disabled, and all results will be returned directly by the model itself. Note: There is no guarantee that everything can be filtered out; if you are not satisfied with the results, you will need to make your own arrangements. |
Pricing
Price on request; the charge is settled from actual consumption with the image coefficient ×2.0. See Pricing & tokens.