Skip to content

HappyHorse-1-1 reference-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 used for generation. This endpoint must use happyhorse-1-1/reference-to-video. Default:"happyhorse-1-1/reference-to-video"。 Allowed values:happyhorse-1-1/reference-to-video。 Example:happyhorse-1-1/reference-to-video。
promptstringYesPrompt required by the ModelFold gateway; at most 2000 characters. A description of the desired elements and visual style for the generated video. Input in any language is supported. Up to 5,000 characters. Use "[Image 1]", "[Image 2]" to refer to the images in reference_image, in the same order. When using a reference, specify the object in the image, such as "the woman in a red qipao in [Image 1]". maxLength: 2000. Example:A cat running on the grass。
reference_imagearray&lt;string&gt;YesThe URL of a reference image.
Image requirements:
1. Formats: JPEG, JPG, PNG, WEBP.
2. Resolution: The shortest side must be at least 400 pixels. A clear image with a resolution of 720P or higher is recommended. Avoid using images that are too small, blurry, or overly compressed, as this can degrade the output quality.
3. Maximum file size: 20 MB. maxItems: 9.
resolutionstringNoThe resolution tier of the generated video.
Options: 720p; 1080p Default:"1080p"。 Allowed values:720p / 1080p。 Example:1080p。
aspect_ratiostringNoThe aspect ratio of the generated video.
Options: 16:9; 9:16; 3:4; 4:3; 4:5; 5:4; 1:1; 9:21; 21:9 Default:"16:9"。 Allowed values:16:9 / 9:16 / 3:4 / 4:3 / 4:5 / 5:4 / 1:1 / 9:21 / 21:9。 Example:16:9。
durationnumberNoThe duration of the generated video, in seconds. Value range: An integer from 3 to 15. Default:5。 minimum: 3. maximum: 15. Example:5。

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": "happyhorse-1-1/reference-to-video",
  "prompt": "A cat running on the grass",
  "reference_image": [
    "https://example.com/reference.png"
  ],
  "resolution": "1080p",
  "aspect_ratio": "16:9",
  "duration": 5
}'
json
{
  "model": "happyhorse-1-1/reference-to-video",
  "prompt": "A cat running on the grass",
  "reference_image": [
    "https://example.com/reference.png"
  ],
  "resolution": "1080p",
  "aspect_ratio": "16:9",
  "duration": 5
}

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.