Alibaba
Wan 2.7 Video
wan2.7-video/image-to-video
Alibaba's WAN series video generation models support text-to-video, image-to-video, and reference-guided video, with multiple reference inputs maintaining character and product consistency across shots.
Try wan2.7-video/image-to-video
Input
Showcases
View all showcasesOutput
videoPricing
wan2.7-video/image-to-video per second
| Specifications | Unit Price |
|---|---|
| 720P | $0.100 |
| 1080P | $0.167 |
Overview
wan2.7-video/image-to-video is an image-driven video generation model in the Alibaba WAN video series, accessed through the unified HiAPI.ai interface. It generates video starting from an image and also supports guidance from reference images/reference clips, allowing the visual content and camera movement to be controlled via prompts. Output resolution can be 720P or 1080P, each generation lasts from 2 to 15 seconds, and it supports combined inputs of first frame, last frame, driving audio, and an opening clip. It is suitable for developers who need to produce short videos from existing image assets, such as for advertising creatives, e-commerce showcases, and storyboard previews.
Key Features
- Image-driven generation with first/last frame control — You can specify both the first-frame and last-frame images to constrain the starting and ending composition of the shot, reducing regeneration costs caused by randomness.
- Reference clips and driving audio participate in generation — In addition to first and last frames, you can also pass in an opening clip and driving audio, giving the generated result a basis in motion rhythm and audio-visual alignment.
- Adjustable duration and resolution — Each generation can be set to last between 2 and 15 seconds, and the output resolution can be 720P or 1080P, adapting to different delivery requirements.
Capabilities
Image-to-video generation: Uses one or more images as the visual basis and generates video together with a text prompt of up to 5000 characters, making it suitable for turning existing visual assets into dynamic content.
Combined first-frame and last-frame control: You can specify both the first and last frames in a single request, and can also add an opening clip as the starting reference to define the starting and ending images of the shot.
Driving audio input: Supports passing in driving audio as a media input, so the generated video aligns in rhythm with the given audio material, reducing the need for later audio syncing.
Prompt extension and negative prompting: prompt_extend enables automatic prompt expansion, negative_prompt lets you declare visual elements to avoid, and seed allows reproducing the same result.
Parameterized resolution and duration: Output resolution and duration are both request parameters, so 720P/1080P and clip lengths of 2 to 15 seconds can be switched by scenario within the same interface.
Use Cases
- E-commerce and brands: generating dynamic showcases from product images — Input a product hero image and display requirements to produce a several-second product motion clip for detail pages, feed advertising, and social media assets.
- Content teams: turning character or scene images into shot clips — Use a character design image as the first frame or reference to generate short shots that match the storyboard description, for short films, animation previews, and creative pitches.
- Design teams: transition shots constrained by first and last frames — Provide both the starting and ending images to generate a transition clip between them, for title sequences, transitions, and visual concept presentations.
- Audio material owners: audio-driven visual generation — Pass in audio material and a visual description to generate video segments that match the rhythm of the sound, for short music videos and voice-over content.
Limitations and Selection Advice
The maximum duration per generation is 15 seconds; longer narratives require segmented generation and post-production splicing, and cross-segment consistency depends on prompt and reference material control. Output resolution is available in two tiers, 720P and 1080P; higher quality requirements need separate evaluation. Media inputs are limited to three items, and each type can appear only once. If the task is mainly text-based ideation and does not require an image basis, consider a text-to-video model from the same series; when ultra-long continuous shots are needed, this model is not a suitable choice.
Frequently asked questions
View all FAQs →-
Does Wan 2.7 Image to Video require an input image?
Yes. wan2.7-video/image-to-video is an image-to-video route. The image establishes the subject and opening composition; the prompt directs motion, camera, and environmental change.
-
Which durations and resolutions does Wan 2.7 Image to Video support?
The current HiAPI contract supports 2–15s at 720P or 1080P. Check the page controls and API docs for the current options.
-
How is Wan 2.7 Image to Video billed?
Billing follows output duration and the selected tier. The page follows the global display unit, while the successful task record contains the final charge.
-
How can I improve subject consistency?
Use a clear, unobstructed source with a complete composition. Describe the main action and camera first, then name the appearance, material, and background relationships that must remain stable. Validate a short clip first.
Create a generation task
https://api.hiapi.ai/v1/tasks Headers
AuthorizationstringRequiredAccount API key. Required on every request. Example: Bearer YOUR_HIAPI_API_KEY. Get your API key
Content-TypestringOptionalThe request body is always parsed as JSON; when sent, only application/json (optionally with charset) is accepted — any other value returns 415. Example: application/json.
Idempotency-KeystringOptionalIdempotency key, up to 255 bytes. Retries with the same key from the same account create the task only once; replays return the original taskId.
On network timeouts or client retries, the same key creates the task only once — no double charges (scope: the API key's account). Use a business-unique identifier as the key (e.g. "order-42"); replays return the original taskId, and keys expire 24 hours after the first request. See the Unified Async API overview for the full scenario matrix.
Body
modelstringRequiredCurrent fixed value: wan2.7-video/image-to-video
routestringOptionalCurrent fixed value: default
inputobjectRequired
Business parameters for wan2.7-video/image-to-video and route default — see the parameter table below.
seedintegerOptionalmin 0max 2147483647Random seed used to control the randomness of the generated result; takes an integer value. When other parameters are identical, the same seed can reproduce similar results.
mediaarrayRequiredminItems 1maxItems 3
Media input array that carries the various assets required for image-to-video generation; elements are objects with url and type, and the supported types are first_frame, last_frame, driving_audio, and first_clip, each of which may appear at most once.
Array [ object ]
Array items
urlstringRequiredThe address of the media asset, taking a public URL, an OSS URL, or a supported base64 data URI string.
typestringRequiredThe type of this media asset, taking a string, used to identify its role in the generation process (such as first frame, last frame, driving audio, first clip).
first_framelast_framedriving_audiofirst_clippromptstringRequiredmaxLength 5000The text prompt for image-to-video generation, describing the desired visual content and dynamic effects of the generated video.
durationintegerOptionalDefault: 5min 2max 15The duration of the generated video in seconds, taking an integer value, default 5.
watermarkbooleanOptionalDefault: falseWhether to add a watermark to the generated video, taking a boolean value, default false.
resolutionstringOptionalDefault: "1080P"The resolution of the generated video, taking a string; billing is calculated per second and the unit price depends on this value, default 1080P.
720P1080Pprompt_extendbooleanOptionalDefault: trueWhether to enable prompt extension; when enabled, the model automatically expands the input prompt, taking a boolean value, default true.
negative_promptstringOptionalDefault: ""maxLength 500The negative prompt, used to describe content that should not appear in the generated video, default empty string.
callbackobjectOptional
Terminal-state notification config. When omitted, no callback is delivered — poll the task yourself. See the callback note below.
Provide callback.url when creating a task and HiAPI POSTs to your service once the task reaches a terminal state — no polling needed. The callback payload mirrors the task detail structure; signature verification, delivery retries and idempotency are documented on the Unified Async API overview page.
urlstringRequiredRequired when callback is present. A POST is sent to this URL once the task reaches a terminal state; must be a valid http(s) URL.
whenstringOptionalDefault: "final"Only final is supported today — notified on both success and fail.
finalstoragestringOptionalDefault: "temp"Artifact storage tier: temp (default, retained about 7 days) or persistent (long-term, billed by size). Insufficient balance or exceeding the storage cap silently downgrades to temp; the effective tier is shown in the task detail response.
temppersistentRequest examples
# Submit an async task; returns a taskId immediately (no waiting for generation)
curl -X POST "https://api.hiapi.ai/v1/tasks" \
-H "Authorization: Bearer $HIAPI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "wan2.7-video/image-to-video",
"input": {
"media": "…",
"prompt": "…",
"duration": 5,
"watermark": false,
"resolution": "1080P",
"prompt_extend": true,
"negative_prompt": ""
}
}' const res = await fetch("https://api.hiapi.ai/v1/tasks", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.HIAPI_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
model: "wan2.7-video/image-to-video",
input: {
"media": "…",
"prompt": "…",
"duration": 5,
"watermark": false,
"resolution": "1080P",
"prompt_extend": true,
"negative_prompt": ""
}
}),
});
const task = await res.json();
// { code: 200, message: "success", data: { taskId } } import os, requests
res = requests.post(
"https://api.hiapi.ai/v1/tasks",
headers={"Authorization": f"Bearer {os.environ['HIAPI_API_KEY']}"},
json={
"model": "wan2.7-video/image-to-video",
"input": {
"media": "…",
"prompt": "…",
"duration": 5,
"watermark": False,
"resolution": "1080P",
"prompt_extend": True,
"negative_prompt": ""
}
},
)
print(res.json()) # { code, message, data: { taskId } } 200 OK
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-01HZTQ8BX2N3GM3YFK4Z9D7VQR"
}
} 400 Bad Request
{
"code": 400,
"message": "invalid request",
"data": null,
"error_code": "INVALID_REQUEST"
} Get task detail
https://api.hiapi.ai/v1/tasks/:id Response fields
taskIdstringRequiredTask ID, always prefixed with tk-hiapi-.
modelstringRequiredResolved full model name. Tasks submitted with the route parameter return base@route (e.g. gpt-image-2/text-to-image@ext); otherwise identical to the name passed at creation.
routestringOptionalPresent only when the task was submitted with an explicit route parameter; echoes the submitted value.
statusstringRequiredTask status.
queued Queued, not started yet.
handling Being processed.
archiving Processing finished, artifacts being prepared.
success Terminal: completed, artifacts available (output returned).
fail Terminal: failed (error returned).
After submission, check status: success and fail are terminal, everything else is non-terminal. Poll every 1–3 seconds until terminal. On success, download artifacts from output[].url and transfer them before expireAt; pass storage: "persistent" at creation time when long-term retention is needed.
creatednumberRequiredTask creation time (Unix seconds).
completednumberRequiredUnix seconds when the task reached a terminal state; fixed to 0 while not terminal.
outputarrayOptional
Present only when status == success. Artifact list — always an array; a single task may return multiple types at once (e.g. video + first_frame).
Array [ object ]
Array items
urlstringRequiredArtifact URL, directly downloadable.
typestringRequiredCurrent possible values: video, image, audio, first_frame, last_frame, thumbnail; more may be added later.
expireAtnumberRequiredUnix seconds until which the artifact remains accessible; download or transfer before it expires.
errorobjectOptional
Present only when status == fail.
codestringRequiredBusiness error code.
messagestringRequiredError description.
Response examples
Success
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-01HZTQ8BX2N3GM3YFK4Z9D7VQR",
"model": "happyhorse-1-0",
"status": "success",
"created": 1777282033,
"completed": 1777282099,
"output": [
{
"url": "https://cdn.hiapi.ai/tasks/.../video.mp4",
"type": "video",
"expireAt": 1777886899
}
]
}
} Processing (non-terminal)
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-...",
"model": "happyhorse-1-0",
"status": "archiving",
"created": 1777282033,
"completed": 0
}
} Failed
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-...",
"model": "happyhorse-1-0",
"status": "fail",
"created": 1777282033,
"completed": 1777282099,
"error": {
"code": "TASK_FAILED",
"message": "task failed"
}
}
} Articles
View all articles →Related Models
View all models →Same Type
-
Runway Gen 4.5 Runway $0.172 /second -
HappyHorse 1.0 Alibaba $0.168 /second -
Gemini Omni Google -- -
Veo 3.1 Google $0.290 /second -
HeyGen Avatar V HeyGen $0.150 /second -
FLUX 3 Max Black Forest Labs $0.061 /second -
Grok Imagine 1.5 xAI $0.011 /second -
Hailuo 2.3 MiniMax $0.270 /video -
FLUX 3 Video Black Forest Labs $0.090 /second -
Kandinsky 6.0 Pro $1.93 /video -
Kling 3.0 Turbo Kuaishou $0.130 /second -
Creatify Boreal Creatify $0.015 /second
Same Provider
-
Wan 2.7 Image Alibaba $0.035 /image -
Wan 3.0 Video Alibaba $0.040 /second -
Wan 2.6 Flash Alibaba $0.043 /second -
Qwen Image 3.0 Alibaba $0.036 /image -
Qwen Image 2.1 Alibaba $0.020 /image -
HappyHorse 1.1 Alibaba $0.160 /second -
HappyHorse 1.0 Alibaba $0.168 /second -
Z-Image Alibaba $0.008 /image -
Qwen Image 2.0 Alibaba $0.042 /image -
Qwen Audio 3.0 TTS Alibaba $0.030 /1,000 characters



