seedinteger
Random seed (0-2147483647) for reproducible results. Omit for a random seed.
alibaba/wan/2.7/video-editAlibaba Wan 2.7 video editing model.
Try the model
Customize your input with more control.
PNG, JPEG, WebP, or GIF · 20 MiB maximum each
What would you like to do next?
Select an example to load its inputs and result into the playground.
{
"prompt": "Change the video to an 8-bit pixel style",
"video": "https://static.sandbase.ai/examples/d2517981-e23d-4629-a811-791107b46f0d/input/776801b8-88cf-4cfe-8ae6-b3b3f695f1e3.mp4"
}{
"images": [
"https://static.sandbase.ai/examples/9d304d2f-bc79-4e10-895b-7f9feb28fe82/input/255e6684-4e13-4b95-9841-ae954e4713a4.webp"
],
"prompt": "Make the horse-headed character in the video wear the striped sweater from the image",
"video": "https://static.sandbase.ai/examples/9d304d2f-bc79-4e10-895b-7f9feb28fe82/input/6dfddb1c-4c34-48a6-a270-e605bc44cb6c.mp4"
}{
"prompt": "Remove the train from the video. Keep everything else the same.",
"video": "https://static.sandbase.ai/examples/cd7590b7-af00-4d8b-87d1-58170e9b07db/input/5adb4529-4fd8-4595-922d-4c4198496cc9.mp4"
}{
"prompt": "Change the background season to a snowy winter, with snow covering the trees. Keep the river the same.",
"video": "https://static.sandbase.ai/examples/f69f7e20-129d-4d5a-b109-f23772cb979b/input/b20d1ce4-7267-4dd3-ae9e-d09498d0d211.mp4"
}{
"prompt": "Keep the character's voice and tone. Change the left girl's line to: \"Mom, what color is this?\", and change the right girl's line to: \"It's green, baby\"",
"video": "https://static.sandbase.ai/examples/29baa5d7-a124-48b7-91f8-c617e222fd79/input/e4ee5497-9a40-477e-9d6f-f0680cf46210.mp4"
}{
"images": [
"https://static.sandbase.ai/examples/27df96ad-5550-452c-9d92-b0a530e5eb65/input/f88104ef-3e5f-4c9e-ab4b-bf8d6b35879f.png"
],
"prompt": "Reference the special effects of the video and apply them to the woman in the image, with the scene set on a street.",
"video": "https://static.sandbase.ai/examples/27df96ad-5550-452c-9d92-b0a530e5eb65/input/173d05e0-a5ab-485f-9a75-fe20bf0e5f13.mp4"
}Change an existing clip with a sentence: restyle it, swap an object or outfit, or rework the background. The edit is carried through every frame so motion and timing from the source are kept. Optional reference images guide the new look.
| Field | Type | Default | Notes |
|---|---|---|---|
prompt | string, required | — | Up to 50,000 characters. |
video | video URL, required | — | Source clip, Video 1 in the prompt. |
images | image URL[] | — | Optional reference images, Image 1, Image 2, … |
audio_setting | auto / origin | auto | auto regenerates audio to match the edit; origin keeps the source track. |
duration | 0 / 2 / 3 / 4 / 5 / 6 / 7 / 8 / 9 / 10 | 0 | 0 keeps the source length; 2–10 trims or sets the output length. |
resolution | 720p / 1080p | 720p | Sets the per-second rate. |
seed | integer | random | Fix it to compare prompt changes. |
You pay for output seconds: $0.10 at 720p and $0.15 at 1080p, the same as Alibaba's list price. With duration: 0 the output matches the source, so you pay for the source length; the quote before submission assumes 5 seconds and the final charge uses the measured length. Input video is not metered separately.
| Output | 720p | 1080p |
|---|---|---|
5s source, duration: 0 | $0.50 | $0.75 |
10s source, duration: 0 | $1.00 | $1.50 |
Any source, duration: 3 | $0.30 | $0.45 |
Failed runs are not charged.
duration before running the full clip.alibaba/wan/2.7/video-extend.Other Wan 2.7 endpoints: alibaba/wan/2.7/text-to-video, alibaba/wan/2.7/image-to-video, alibaba/wan/2.7/reference-to-video, alibaba/wan/2.7/video-extend, alibaba/wan/3.0/video (newer, up to 30s).
Start building
Submit this model through the SandBase Unified Run API.
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1/run" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"model": "alibaba/wan/2.7/video-edit",
"duration": 0,
"resolution": "720p",
"audio_setting": "auto"
}
SANDBASE_JSON
)
run_id=$(printf '%s' "$result" | jq -r .id)
for attempt in $(seq 1 120); do
status=$(printf '%s' "$result" | jq -r .status)
case "$status" in completed|failed|timeout) break ;; esac
sleep 2
result=$(curl --fail-with-body --silent \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
"https://api.sandbase.ai/v1/run/$run_id")
done
status=$(printf '%s' "$result" | jq -r .status)
[ "$status" = completed ] || { echo "Generation ended: $status" >&2; exit 1; }
printf '%s\n' "$result"Create a SandBase API key and set it in your server environment. All requests use Bearer authentication.
export SANDBASE_API_KEY="YOUR_API_KEY"Keep the key on your server. Do not expose it in browser code or commit it to a repository.
POST to /v1/run with this model ID and its inputs. The request example above includes submission and polling.
Use the returned run ID to poll until the status is completed, failed or timeout. Read output only after completed.
curl "https://api.sandbase.ai/v1/run/$RUN_ID" \
-H "Authorization: Bearer $SANDBASE_API_KEY"Pass a publicly accessible file URL in the model’s image, video or audio field. Supported formats and limits are shown beside each Playground input.
Use the upload or replace control on supported image fields in the Playground. Video URL fields accept a hosted driving video; they do not imply video-upload support.
seedintegerRandom seed (0-2147483647) for reproducible results. Omit for a random seed.
videostringrequiredThe URL of the input video to edit.
imagesarrayReference images to guide the video editing.
promptstringrequiredThe editing instruction describing what changes to make.
Default: ""
durationintegerOutput video duration in seconds. 0 means match input video duration. When set (2-10), truncates from the start.
Default: 0
Possible values: 0, 2, 3, 4, 5, 6, 7, 8, 9, 10
resolutionstringThe resolution of the output video.
Default: "720p"
Possible values: "720p", "1080p"
audio_settingstringAudio handling. 'auto': model decides whether to regenerate audio. 'origin': preserve original audio from input video.
Default: "auto"
Possible values: "auto", "origin"
{
"model": "alibaba/wan/2.7/video-edit",
"duration": 0,
"resolution": "720p",
"audio_setting": "auto"
}A completed run exposes its result in output. The following is the model’s saved example, not a new generation.
[
{
"poster": "https://static.sandbase.ai/examples/posters/4f56fc5e6f0961e6af9e.jpg",
"source": "Alibaba Cloud",
"source_url": "https://www.alibabacloud.com/help/en/model-studio/wan-video-editing-guide",
"url": "https://static.sandbase.ai/examples/d2517981-e23d-4629-a811-791107b46f0d/output/19789c99-8591-4882-a1d4-25574df39dec.mp4"
}
]