Truy xuất một video HappyHorse
Truy xuất một tác vụ video HappyHorse theo ID tác vụ, bao gồm trạng thái, tiến độ, dấu thời gian và URL video đã hoàn tất.
video_url sau khi tác vụ hoàn tất.
Kiểm tra các trường này
statuscho biết tác vụ đang ở trạng tháiqueued,in_progress,completed,failedhoặcerror.progresslà tỷ lệ phần trăm hoàn thành ở mức khái quát.video_urlxuất hiện trong các phản hồi đã hoàn tất.errorxuất hiện khi tác vụ thất bại.
Luồng polling
Tạo tác vụ trước
id được trả về.Polling theo ID tác vụ
status đạt completed, failed hoặc error.Tải xuống tệp MP4
status là completed, gọi Truy xuất nội dung video HappyHorse.Ủy quyền
Bearer authentication. Use your CometAPI API key.
Tham số đường dẫn
Task ID returned by POST /v1/videos.
Phản hồi
Current HappyHorse video task state.
Task ID. Use this value as task_id in retrieve and content requests.
"task_example"
Object type. HappyHorse video tasks return video.
"video"
Model ID used for the task.
"happyhorse-1.0"
Task lifecycle status. Poll until the value is completed, failed, or error.
queued, in_progress, completed, failed, error "queued"
Task progress as a coarse percentage.
0 <= x <= 1000
Task creation time as a Unix timestamp in seconds.
1779938152
Compatibility alias for id. The value matches id when present.
"task_example"
Task completion time as a Unix timestamp in seconds. This field appears on completed tasks.
1779938219
Temporary video delivery URL. This field appears on completed tasks.
"<temporary-video-url>"
Failure details. This field appears when the task fails.