Skip to main content
POST
WAN 2.7 - Edit video

Authorizations

x-magnific-api-key
string
header
required

Your Magnific API key. Required for authentication. Learn how to obtain an API key

Body

application/json

Edit an existing video using WAN 2.7. Supports three modes:

  • Instruction-based editing: provide prompt with editing instructions (e.g., "change the sky to sunset")
  • Reference-image editing: provide prompt and image_urls to apply visual references to the video
  • Style transfer: provide prompt and image_urls with style reference images to transfer artistic styles
video_url
string<uri>
required

URL of the input video to edit. Must be publicly accessible.

Supported formats: MP4, MOV Duration: 2-10 seconds Dimensions: 240-4096px per side, aspect ratio between 1:8 and 8:1 Maximum file size: 100MB

Example:

"https://example.com/input-video.mp4"

webhook_url
string<uri>

Optional callback URL that will receive asynchronous notifications whenever the task changes status. The payload sent to this URL is the same as the corresponding GET endpoint response, but without the data field.

Example:

"https://www.example.com/webhook"

prompt
string

Editing instructions describing the desired changes. For reference-image or style-transfer modes, describe how the reference images should be applied.

Maximum string length: 5000
Example:

"Change the background to a futuristic cityscape with neon lights"

negative_prompt
string

Elements to avoid in the edited video.

Maximum string length: 500
Example:

"watermark, text, distortion, blurry"

image_urls
string<uri>[]

Reference images for editing or style transfer. Up to 3 images.

Supported formats: JPEG, PNG, BMP, WEBP Dimensions: 240-8000px per side Maximum file size: 20MB each

Maximum array length: 3
Example:
aspect_ratio
enum<string>

Output video aspect ratio for editing. If not specified, the aspect ratio of the input video is preserved.

  • 16:9: Landscape (widescreen)
  • 9:16: Portrait (vertical, mobile-optimized)
  • 1:1: Square
  • 4:3: Standard landscape
  • 3:4: Standard portrait
Available options:
16:9,
9:16,
1:1,
4:3,
3:4
resolution
enum<string>
default:1080P

Output video resolution:

  • 720P: 720p HD (1280x720)
  • 1080P: 1080p Full HD (1920x1080)
Available options:
720P,
1080P
duration
integer
default:0

Duration of the output video in seconds. Set to 0 to preserve the full duration of the input video.

Required range: 0 <= x <= 10
Example:

0

seed
integer

Random seed for reproducible generation. Use the same seed with identical parameters to reproduce results. Leave unset for random seed.

Required range: 0 <= x <= 2147483647
Example:

12345

additional_settings
object

Additional settings for video editing.

Response

OK - The task exists and the status is returned

data
object
required
Example: