Skill 3.1.2

Implement a solution that generates videos from text prompts and reference media

Key Concepts

Sora 2 is called through the Azure OpenAI v1 videos API: videos.create starts an asynchronous job with a prompt, a size (such as 1280x720 landscape or 720x1280 portrait) and a duration in seconds; videos.retrieve polls the status (queued, in_progress, completed or failed); and videos.download_content fetches the MP4 when the job completes. Jobs expire after a limited time, so results are downloaded and stored promptly.

An input_reference image anchors the first frame, for example to animate a product photo; its resolution must match the requested size. Prompts that describe shot type, subject, action, setting, lighting and camera motion in one clear purpose give the best adherence. Because generation takes minutes, applications submit the job from a background process or queue and notify the user when the video is ready, rather than holding an HTTP request open.