Text and image to video
Start from a prompt, or animate a single first-frame image. Provide both and the prompt steers the motion.
Alibaba's Happy Horse 1.0 video model through one unified API. Text-to-video and image-to-video at up to 1080p with synchronized audio, async jobs, and webhooks.
Integrate Happy Horse 1.0 with a single API call — one key, one unified endpoint, and shared billing across every model on Apiframe.
model: "happyhorse-1.0" Start from a prompt, or animate a single first-frame image. Provide both and the prompt steers the motion.
Every clip ships with a matching soundtrack generated automatically — no separate audio pass.
Choose 720p or 1080p and any duration from 3 to 15 seconds, billed per second.
Example prompts you can run through the Happy Horse 1.0 API on Apiframe.
A wild horse galloping across a misty meadow at sunrise, cinematic slow motion
A neon city street at night, camera tracking a cyclist through the rain
A close-up of a hummingbird hovering over a bright red flower, golden light
Send a single POST /v2/videos/generate request with your API key to
generate with Happy Horse 1.0. The call returns a jobId you can poll or
receive via webhook.
curl -X POST https://api.apiframe.ai/v2/videos/generate \
-H "X-API-Key: afk_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"prompt": "a cinematic sunrise over a futuristic cityscape, smooth camera push-in",
"model": "happyhorse-1.0",
"happyhorse10Params": {
"image": "https://example.com/input.jpg",
"resolution": "1080p",
"aspect_ratio": "16:9",
"seed": 1
}
}'import requests
response = requests.post(
"https://api.apiframe.ai/v2/videos/generate",
headers={
"X-API-Key": "afk_your_api_key_here",
"Content-Type": "application/json",
},
json={
"prompt": "a cinematic sunrise over a futuristic cityscape, smooth camera push-in",
"model": "happyhorse-1.0",
"happyhorse10Params": {
"image": "https://example.com/input.jpg",
"resolution": "1080p",
"aspect_ratio": "16:9",
"seed": 1
}
},
)
print(response.json()) # { "jobId": "...", "status": "QUEUED" }const response = await fetch("https://api.apiframe.ai/v2/videos/generate", {
method: "POST",
headers: {
"X-API-Key": "afk_your_api_key_here",
"Content-Type": "application/json",
},
body: JSON.stringify({
"prompt": "a cinematic sunrise over a futuristic cityscape, smooth camera push-in",
"model": "happyhorse-1.0",
"happyhorse10Params": {
"image": "https://example.com/input.jpg",
"resolution": "1080p",
"aspect_ratio": "16:9",
"seed": 1
}
}),
});
const { jobId } = await response.json();
console.log(jobId);Generation is asynchronous. A successful submission returns 202 Accepted with a jobId. Poll GET /v2/jobs/{id} (or supply a webhook_url) until the status is COMPLETED; the result field then holds the output URL(s).
{
"jobId": "b2c3d4e5-f6a7-8901-bcde-f23456789012",
"status": "QUEUED"
}curl https://api.apiframe.ai/v2/jobs/JOB_ID \
-H "X-API-Key: afk_your_api_key_here"import requests, time
while True:
job = requests.get(
"https://api.apiframe.ai/v2/jobs/JOB_ID",
headers={"X-API-Key": "afk_your_api_key_here"},
).json()
if job["status"] in ("COMPLETED", "FAILED"):
break
time.sleep(2)
print(job["result"])let job;
do {
await new Promise((r) => setTimeout(r, 2000));
job = await fetch("https://api.apiframe.ai/v2/jobs/JOB_ID", {
headers: { "X-API-Key": "afk_your_api_key_here" },
}).then((r) => r.json());
} while (job.status !== "COMPLETED" && job.status !== "FAILED");
console.log(job.result);Request parameters accepted by the Happy Horse 1.0 endpoint. Model-specific options are nested under the params object shown below.
| Parameter | Type | Required | Default | Allowed / range | Description |
|---|---|---|---|---|---|
| prompt | string | required | — | — | Text description of what to generate. |
| model | string | required | "happyhorse-1.0" | "happyhorse-1.0" | The model identifier for this endpoint. |
| happyhorse10Params.image | string (URL) | optional | — | — | Provide an image to animate (image-to-video); omit for text-to-video. |
| happyhorse10Params.resolution | string | optional | "1080p" | "720p", "1080p" | Resolution |
| happyhorse10Params.aspect_ratio | string | optional | "16:9" | "16:9", "9:16", "1:1", "4:3", "3:4" | Used for text-to-video (and reference-to-video on 1.1); ignored when animating an image. |
| happyhorse10Params.seed | number | optional | — | step 1 | Reuse a number to reproduce the same result. |
Common questions about the Happy Horse 1.0 API.
Omit the image for text-to-video and use aspect_ratio to set the shape. Provide happyhorse10Params.image to animate it as the first frame — the output then adopts the image’s aspect ratio.
Pricing is per second of output: 24 credits/second at 720p and 48 credits/second at 1080p. A 6-second 1080p clip is 288 credits.
Requests are served across Replicate and Alibaba Cloud (DashScope) with automatic failover, so you only manage one Apiframe key.
Still have questions?
Get your API key and integrate Happy Horse 1.0 in minutes — Pay-as-you-go.
Questions? Join our Discord or contact sales.