Bir Omni videosu oluşturun
POST /v1/videos ile CometAPI üzerinden beta bir Omni video görevi oluşturun, ardından görevi yoklayın ve tamamlanan MP4 dosyasını indirin.
id değerini saklayın ve görev terminal bir duruma ulaşana kadar görevi yoklayın.
Beta
POST /v1/videos multipart/form-data kullanır; skaler kontrolleri form alanları olarak iletin.
Bir giriş modu seçin
model=omni-fast kullanın.
Süre, oran ve çözünürlük ayarlayın
Omni, üretim kararlılığı girişe ve seçilen rotaya göre değişebildiği için beta olarak işaretlenmiştir. İlk isteği küçük tutun, ardından belirli bir render süresine veya kare boyutuna güvenmeden önce tamamlanan videoyu inceleyin.aspect_ratio ve resolution değerlerini üretim tercihleri olarak değerlendirin ve nihai piksel boyutlarına bağlı kalmadan önce indirilen MP4 dosyasını doğrulayın.
Görev akışı
Görevi oluşturun
id değerini saklayın.Görevi yoklayın
status değeri completed veya failed olana kadar Bir Omni videosunu alın çağrısını yapın.Sonucu indirin
completed olduğunda, MP4 dosyasını indirmek için Omni video içeriğini alın çağrısını yapın.Yetkilendirmeler
Bearer authentication. Use your CometAPI API key.
Gövde
Omni model ID for this endpoint. Use omni-fast for text-to-video.
omni-fast "omni-fast"
Text prompt that describes the video to generate.
"Ocean waves rolling onto a sandy beach at golden hour"
Requested clip duration in seconds. Start with 4 while this endpoint is beta.
"4"
Output aspect ratio preference. 16:9 and 9:16 are the most predictable; 1:1 can be accepted but may render as landscape.
16:9, 9:16, 1:1 "16:9"
Output resolution preference. Start with 720p. 1080p can be accepted but current production output may normalize to 720p.
"720p"
Yanıt
Task accepted. Store the returned id and poll GET /v1/videos/{task_id}.
Task ID. Use this value with retrieve and content endpoints.
"task_example"
Object type. Video tasks return video.
"video"
Model ID used for the task.
"omni-fast"
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 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.