4Z API

Create Video muse-video

Endpoint: POST https://4zapi.com/v1/videos

Text-to-Video / Image-to-Video (First Frame), outputs a 720P MP4 with sound. Asynchronous task: After submission, poll with 'Query Video muse-video', and download with 'Download Video muse-video' after completed.

Parameter Required Description
model Yes Fixed muse-video
prompt Yes Scene description, in Chinese or English, up to 4000 characters
seconds No Integer (string or number) between 4–30, default is 4; billed based on this duration. The field name is seconds, not duration
size No 1280x720 (landscape) or 720x1280 (portrait), defaults to landscape if not filled
input_reference No First frame image (Image-to-Video): image URL or data URL, supports PNG/JPEG/WebP, does not support file ID; can also upload files directly using multipart/form-data
resolution No Must be 720p, can be omitted
  • Billing: Charged based on requested seconds, pre-deducted upon submission; automatic refund for task failure; returns 400 (code is client_local_validation) for invalid parameters, no charge for unbuilt tasks.
  • Actual duration rounds up, will not be shorter than requested: 4,5→5 seconds; 6→6; 7,8→8; 9,10→10; 11–15→15; 16–20→20; 21–25→25; 26–30→30.
  • For durations over 10 seconds, segments are generated and stitched together, changing scenes at the 10th and 20th seconds.
  • Time consumption: approximately 1–2 minutes for under 10 seconds, about 3–7 minutes for 15–30 seconds; it is recommended to check every 10–20 seconds.

Parameters

  • Content-Type (header, string, required)

Request body (application/json)

  • model (string, required)
  • prompt (string, required)
  • seconds (string, required)
  • size (string, required)

Request example

{
  "model": "muse-video",
  "prompt": "金色的枫叶在微风中飘落,阳光穿过树梢,电影感",
  "seconds": "5",
  "size": "1280x720"
}