()
| 8 | |
| 9 | |
| 10 | async def main() -> None: |
| 11 | video = await client.videos.create_and_poll( |
| 12 | model="sora-2", |
| 13 | prompt="A video of the words 'Thank you' in sparkling letters", |
| 14 | ) |
| 15 | |
| 16 | if video.status == "completed": |
| 17 | print("Video successfully completed: ", video) |
| 18 | else: |
| 19 | print("Video creation failed. Status: ", video.status) |
| 20 | |
| 21 | |
| 22 | asyncio.run(main()) |