| Model ID | Description |
|---|---|
happyhorse-1.1-i2v | HappyHorse v1.1 Image-to-Video |
happyhorse-1.0-i2v | HappyHorse v1.0 Image-to-Video |
https://platform.dataeyes.ai/aliAuthorization header using the Bearer scheme.Authorization: Bearer sk-xxxxsk-your-api-keyPOST. The response returns a task_id.GET using the task_id until the status is SUCCEEDED or FAILED.POST /api/v1/services/aigc/video-generation/video-synthesis| Header | Value |
|---|---|
Content-Type | application/json |
Authorization | Bearer sk-xxxx |
X-DashScope-Async | enable |
| Field | Type | Required | Description |
|---|---|---|---|
model | string | Yes | Model identifier. One of happyhorse-1.1-i2v or happyhorse-1.0-i2v. |
input | object | Yes | Input specification containing the prompt and media. |
input.prompt | string | No | Text prompt describing desired video content. Maximum 5,000 non-Chinese characters or 2,500 Chinese characters. Unlike the text-to-video API, this field is optional for image-to-video. |
input.media | array | Yes | Array containing exactly 1 media element specifying the first frame image. |
input.media[].type | string | Yes | Fixed value: "first_frame". |
input.media[].url | string | Yes | Public URL (HTTP or HTTPS) to the image, or a Base64-encoded data URI in the format data:{MIME};base64,{data}. |
parameters | object | No | Generation parameters (see below). |
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
resolution | string | No | "1080P" | Output resolution. Accepted values: 720P, 1080P. The model auto-scales total pixel count to match the target resolution. Output aspect ratio follows the input first frame image. |
duration | integer | No | 5 | Video duration in seconds. Range: [3, 15]. |
watermark | boolean | No | true | Whether to include a watermark on the generated video. |
seed | integer | No | (random) | Random seed for reproducibility. Range: [0, 2147483647]. |
Note: The ratioparameter is not supported for image-to-video generation. The output aspect ratio is determined automatically by the input first frame image.
| Constraint | Requirement |
|---|---|
| Supported formats | JPEG, JPG, PNG, WEBP |
| Minimum dimensions | Width >= 300 px, Height >= 300 px |
| Aspect ratio | Between 1:2.5 and 2.5:1 |
| Maximum file size | 20 MB |
| Format | MIME Type |
|---|---|
| JPEG / JPG | image/jpeg |
| PNG | image/png |
| WEBP | image/webp |
{
"request_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"output": {
"task_id": "ab123456-cd78-ef90-1234-567890abcdef",
"task_status": "PENDING"
}
}GET /api/v1/tasks/{task_id}| Header | Value |
|---|---|
Authorization | Bearer sk-xxxx |
| Parameter | Type | Description |
|---|---|---|
task_id | string | The task ID returned from Step 1. |
{
"request_id": "f0e1d2c3-b4a5-6789-0abc-def123456789",
"output": {
"task_id": "ab123456-cd78-ef90-1234-567890abcdef",
"task_status": "SUCCEEDED",
"video_url": "https://cdn.example.com/generated-video.mp4"
},
"usage": {
"duration": 5,
"input_video_duration": 0,
"output_video_duration": 5,
"video_count": 1,
"SR": 0
}
}| Field | Type | Description |
|---|---|---|
duration | integer | Requested video duration in seconds. |
input_video_duration | integer | Input video duration. Fixed 0 for image-to-video tasks. |
output_video_duration | integer | Actual output video duration in seconds. |
video_count | integer | Number of videos generated. Fixed 1. |
SR | integer | Super-resolution flag. |
| Status | Description |
|---|---|
PENDING | Task has been accepted and is queued for processing. |
RUNNING | Task is actively generating the video. |
SUCCEEDED | Video generation completed successfully. The video_url field is populated. |
FAILED | Task failed. Check the error message in the response for details. |
CANCELED | Task was canceled before completion. |
UNKNOWN | Task status could not be determined. |
ratio parameter is not supported for i2v tasks (unlike text-to-video). The model reads the dimensions of the provided image and generates a video matching that aspect ratio. The resolution parameter controls the total pixel count (720P or 1080P), but the aspect ratio always follows the input image.input.prompt field is optional for image-to-video generation. If omitted, the model will infer motion and content from the first frame image alone. Providing a prompt can help guide the generated motion and scene evolution.X-DashScope-Async: enable header is required on the creation request. Omitting it will result in an error.input.media array must contain exactly one element with type set to "first_frame".data:{MIME};base64,{data} with the correct MIME type for the image format.ratio parameter (used in text-to-video) is not applicable to image-to-video and will be ignored or cause an error if provided.| Error Code | HTTP Status | Description |
|---|---|---|
InvalidApiKey | 401 | The API key is missing, malformed, or invalid. Verify the Authorization header value. |
InvalidParameter | 400 | One or more request parameters are invalid. Check field values, image constraints, and required fields. |
Throttling | 429 | Request rate limit exceeded. Reduce request frequency and retry after a brief delay. |