Skip to content

Hailuo Standard Text to Video ​

Endpoint ​

POST /videos/generations

Full URL: https://modelfold.ai/v1/videos/generations

Authentication: every request must include the Authorization: Bearer <API_KEY> header.

Send model parameters directly in the JSON body. Do not wrap them in input. This request waits for generation to finish and returns data[].url; supported media models also offer async jobs, polling and callbacks. Replace example media URLs with your own publicly accessible files. See API gateway for billing and errors.

Input parameters for the generation task

Request Parameters ​

Body (application/json) ​

ParameterTypeRequiredDescription
modelstringYesThe model name to use for generation. Required field.
- Must be hailuo/02-text-to-video-standard for this endpoint Default:"hailuo/02-text-to-video-standard"。 Allowed values:hailuo/02-text-to-video-standard。 Example:hailuo/02-text-to-video-standard。
promptstringYesPrompt required by the ModelFold gateway; at most 2000 characters. Text description for video generation (Max length: 1500 characters) maxLength: 1500. Example:A llama and a raccoon battle it out in an intense table tennis match, inside a roaring Olympic stadium. Slow-mo, wild angles, full comedy mode.。
durationstringYesRequired. Video duration in seconds: 6 or 10. Allowed values:6 / 10。 Example:6。
prompt_optimizerbooleanNoWhether to use the model's prompt optimizer (Boolean value (true/false)) Example:true。
nsfw_checkerbooleanNoDefaults to false. When false, no additional content filtering is applied and results are returned directly by the model.

Request Example ​

bash
curl -X POST "https://modelfold.ai/v1/videos/generations" \
  -H "Authorization: Bearer $MODELFOLD_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "hailuo/02-text-to-video-standard",
  "prompt": "A llama and a raccoon battle it out in an intense table tennis match, inside a roaring Olympic stadium. Slow-mo, wild angles, full comedy mode.",
  "duration": "6"
}'
json
{
  "model": "hailuo/02-text-to-video-standard",
  "prompt": "A llama and a raccoon battle it out in an intense table tennis match, inside a roaring Olympic stadium. Slow-mo, wild angles, full comedy mode.",
  "duration": "6"
}

Response ​

200 — Generation completed. usage contains actual billing details; result URLs are illustrative. ​

json
{
  "ok": true,
  "created": 1792134000,
  "data": [
    {
      "url": "https://modelfold.ai/uploads/outputs/result.mp4"
    }
  ],
  "usage": {}
}

ModelFold — one API for all the best AI models.