wan-2-7-image
Alibaba Wan 2.7 Image on reAPI — async text-to-image, editing, multi-image reference, interactive region edits, and group series, with text-to-image up to 4K on the Pro tier.
Alibaba's Wan image model on reAPI — one async endpoint for generation and
editing. Text-to-image, image editing, multi-image reference fusion,
interactive region edits (bbox_list), and group series. Two tiers:
wan2.7-image (1K / 2K) and wan2.7-image-pro (text-to-image up to 4K).
Submit returns a task_id; poll until ready. See current pricing on the
model page.
Quick example
curl https://reapi.ai/api/v1/images/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "wan2.7-image-pro",
"prompt": "a flower shop with delicate windows and a beautiful wooden door, blossoms out front",
"size": "16:9",
"resolution": "2K",
"n": 1
}'import requests
resp = requests.post(
"https://reapi.ai/api/v1/images/generations",
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
json={
"model": "wan2.7-image-pro",
"prompt": "a flower shop with delicate windows and a beautiful wooden door, blossoms out front",
"size": "16:9",
"resolution": "2K",
"n": 1,
},
timeout=30,
)
print(resp.json())const r = await fetch("https://reapi.ai/api/v1/images/generations", {
method: "POST",
headers: {
Authorization: "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
model: "wan2.7-image-pro",
prompt: "a flower shop with delicate windows and a beautiful wooden door, blossoms out front",
size: "16:9",
resolution: "2K",
n: 1,
}),
});
console.log(await r.json());package main
import (
"bytes"
"encoding/json"
"fmt"
"io"
"net/http"
)
func main() {
body, _ := json.Marshal(map[string]any{
"model": "wan2.7-image-pro",
"prompt": "a flower shop with delicate windows and a beautiful wooden door, blossoms out front",
"size": "16:9",
"resolution": "2K",
"n": 1,
})
req, _ := http.NewRequest("POST",
"https://reapi.ai/api/v1/images/generations", bytes.NewReader(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
resp, _ := http.DefaultClient.Do(req)
defer resp.Body.Close()
out, _ := io.ReadAll(resp.Body)
fmt.Println(string(out))
}Submit response
{
"id": "task_018f5a3a1b6e7d9f8c2b4d6e8f0a2c4e",
"model": "wan2.7-image-pro",
"status": "processing",
"created_at": 1735000000
}Poll GET /api/v1/tasks/{id} (see the Tasks reference) until
status === "completed". The completed payload's output.image_urls holds the
generated image URLs.
Authentication
Every call needs a Bearer token. Generate keys at reapi.ai/settings/apikeys.
Authorization: Bearer YOUR_API_KEYEndpoint
POST /api/v1/images/generations
GET /api/v1/tasks/{id}Submission is async. The POST returns immediately with a task_id; the task
endpoint returns the same envelope until completion. Polling does not consume
credits.
Tiers
Two model ids share one parameter shape:
| Model id | Tier | Resolution |
|---|---|---|
wan2.7-image | Standard | 1K / 2K (all modes) |
wan2.7-image-pro | Pro | text-to-image up to 4K; editing and group modes up to 2K |
Pick Pro for hero / print-grade detail and 4K; Standard for fast everyday work.
Modes
There is no mode field — the mode is implicit in the request shape:
- Text-to-image — no
image_urls.promptis required. - Editing / multi-image reference — pass
image_urls.promptis optional (recommended). The output aspect ratio follows the last input image. - Interactive region editing — add
bbox_listto target exact regions. - Group series — set
enable_sequential: truefor a consistent connected set; raises thencap to 12.
Request body
model — string, required
One of wan2.7-image or wan2.7-image-pro.
prompt — string
Up to 5,000 characters. Required for text-to-image (no image_urls);
optional but recommended in editing mode.
image_urls — array, optional
Reference images for editing / multi-image fusion. Public HTTPS URLs only —
base64 / data: URIs are rejected at the gateway. Up to 9 images. Passing
any image switches the request to editing mode.
n — integer, default 1
Images per call. Range [1, 4] normally; up to [1, 12] when
enable_sequential is true. Billed per generated image.
size — string
Output sizing. Polymorphic per the model:
- a gear keyword —
1K/2K/4K - an aspect ratio —
1:1,16:9,9:16,4:3,3:4,3:2,2:3 - a pixel value —
1024x1024
Pair an aspect ratio here with the quality gear in resolution.
resolution — string
Quality gear: 1K / 2K / 4K (case-insensitive).
4K is wan2.7-image-pro text-to-image only. In editing and group modes,
and on the wan2.7-image (standard) tier, the maximum is 2K.
negative_prompt — string, optional
What to keep out of the image, e.g. "blurry, distorted, low quality".
watermark — boolean, default false
Set true to add an AI-generated watermark to the bottom-right corner.
seed — integer, optional
Range [0, 2147483647]. The same seed with the same parameters yields a
similar, stable result.
thinking_mode — boolean, default true
Enables extra reasoning for higher image quality. Only effective for text-to-image with no reference image and outside group mode; ignored otherwise.
enable_sequential — boolean, default false
Turns on group mode — a consistent, connected series in one call. Raises the
n cap to 12. In group mode thinking_mode and color_palette do not apply.
bbox_list — array, optional
Interactive-edit regions. A list parallel to image_urls — one entry per input
image — where each entry is a list of up to two boxes, and each box is
[x1, y1, x2, y2] in absolute pixels with origin at the top-left. Use [] for
an image you are not boxing.
{
"image_urls": [
"https://example.com/clock.webp",
"https://example.com/desk.webp"
],
"bbox_list": [
[],
[[989, 515, 1138, 681]]
]
}color_palette — array, optional
Steer the image toward a custom palette. 3-10 items of { hex, ratio } where
ratio is a percentage string and all ratios sum to 100.00%. Non-group mode
only.
{
"color_palette": [
{ "hex": "#C2D1E6", "ratio": "23.51%" },
{ "hex": "#636574", "ratio": "76.49%" }
]
}Pricing
Wan 2.7 Image bills a flat rate per successfully generated image,
independent of resolution and aspect ratio. Total charge is the per-image rate
times n:
credits = ceil(per_image_usd × n × 1000)where 1 credit = $0.001 USD. The Pro tier carries a higher per-image rate than
Standard. Failed and rejected requests are not charged.
The exact per-image credit cost for each tier surfaces on the model page and through the playground estimator before submit.
Response
The poll envelope returns image URLs in output.image_urls:
{
"id": "task_019dfd44b7fd74168541552a3260a623",
"model": "wan2.7-image-pro",
"status": "completed",
"output": {
"image_urls": [
"https://cdn.reapi.ai/...png"
]
}
}For a group-mode request (enable_sequential: true, n > 1), image_urls
holds the full series in order. Mirror the URLs to your own storage if you need
long-term retention.
Errors
Failures return the standard reAPI envelope { error: { code, message, request_id } }. Common cases:
- Invalid input (out-of-range
n, 4K requested in edit/group mode, abbox_listwhose length does not matchimage_urls, a non-HTTPS media URL) →400. - Insufficient credits →
402. - Rate limited →
429.
See the full catalog at /docs/api/errors.
Tips
- The mode is decided by your inputs, not a flag — omit
image_urlsfor pure generation, include it to edit. - For precise edits, prefer
bbox_listover describing the location in the prompt — boxed regions composite with matched lighting and perspective. - For storyboards and comic panels, use group mode (
enable_sequential: true) so the series stays on-model in one call instead of stitching separate requests. - Reach for
wan2.7-image-proatresolution: "4K"(text-to-image) when the asset goes to print or a retina display; usewan2.7-imagefor fast drafts.