Skip to main content
AI

Happy-Horse Video Generation

Happy-Horse supports text-to-video, image-to-video, multi-reference video generation, and video editing. Use the unified video generation endpoint to submit a task, then poll the task ID until a result URL is available.

Supported Models

ModelUse case
happy-horse-720pText-to-video, image-to-video, and multi-reference generation at 720p.
happy-horse-1080pText-to-video, image-to-video, and multi-reference generation at 1080p.
happy-horse-edit-720pVideo editing at 720p.
happy-horse-edit-1080pVideo editing at 1080p.

Endpoint

POST /v1/video/generations
GET /v1/videos/{task_id}

Authentication

Authorization: Bearer sk-***
Content-Type: application/json

Request Parameters

ParameterTypeRequiredDescription
modelstringYesOne of the Happy-Horse public model IDs.
promptstringYesPrompt text. Maximum source limit: 2500 characters.
aspect_ratiostringNo16:9, 9:16, 1:1, 4:3, or 3:4.
durationintegerConditionalOutput seconds. Source range: 3 to 15.
seedintegerNoRandom seed from 0 to 2147483647.
imagestringConditionalSingle publicly accessible source image URL.
imagesstring[]Conditional1 to 9 public reference image URLs.
videostringConditionalSource video URL for edit models.
reference_image_urlsstring[]NoReference images for video editing.
audio_settingstringNoauto or origin; default follows the upstream provider.

Text-To-Video Example

curl -X POST "{BASE_URL}/v1/video/generations" \
-H "Authorization: Bearer sk-***" \
-H "Content-Type: application/json" \
-d '{
"model": "happy-horse-720p",
"prompt": "A cinematic wide shot of a white horse running across a misty grassland at sunrise, realistic motion, soft rim light.",
"duration": 4,
"aspect_ratio": "16:9",
"size": "720p",
"seed": 12345
}'

Image-To-Video Example

curl -X POST "{BASE_URL}/v1/video/generations" \
-H "Authorization: Bearer sk-***" \
-H "Content-Type: application/json" \
-d '{
"model": "happy-horse-1080p",
"prompt": "Animate the subject naturally, with subtle camera push-in and realistic cloth movement.",
"image": "https://example.com/source-frame.png",
"duration": 6,
"size": "1080p",
"seed": 67890
}'

Multi-Reference Example

curl -X POST "{BASE_URL}/v1/video/generations" \
-H "Authorization: Bearer sk-***" \
-H "Content-Type: application/json" \
-d '{
"model": "happy-horse-1080p",
"prompt": "character1 rides character2 through a futuristic city street, keep both identities consistent.",
"images": [
"https://example.com/character1.png",
"https://example.com/character2.png"
],
"duration": 8,
"aspect_ratio": "9:16",
"seed": 24680
}'

Video Editing Example

curl -X POST "{BASE_URL}/v1/video/generations" \
-H "Authorization: Bearer sk-***" \
-H "Content-Type: application/json" \
-d '{
"model": "happy-horse-edit-720p",
"prompt": "Change the actor jacket into a red leather jacket while preserving motion, face identity, camera movement, and background.",
"video": "https://example.com/source-video.mp4",
"reference_image_urls": [
"https://example.com/jacket-reference.png"
],
"duration": 4,
"size": "720p"
}'

Query Task Status

curl "{BASE_URL}/v1/videos/task_xxx" \
-H "Authorization: Bearer sk-***"
{
"id": "task_xxx",
"task_id": "task_xxx",
"object": "video.generation.job",
"model": "happy-horse-720p",
"status": "completed",
"progress": 100,
"video_url": "https://example.com/output.mp4"
}

Poll every 2 to 5 seconds. Stop when status is completed or failed.

Billing Notes

Happy-Horse billing depends on model tier, output resolution, output seconds, and operation type. Video editing can include source video handling. Use the current product pricing surface as the final price source.

Common Errors

  • Passing an edit model without video.
  • Requesting a duration outside 3 to 15.
  • Sending private or expired media URLs.
  • Passing more than 9 reference images.
  • Using a 720p model while requesting a 1080p size.