I’m attempting to create videos longer than 12 seconds since OpenAI has recently released the ability to create input ‘15’ and ‘20’ for duration, along with a video extension workflow.
Unfortunately, I’m receiving a 400 error stating that my input of 16 seconds is an invalid integer when extending a video, and only the old 4, 8, and 12 values are accepted. Wondering if anyone else has run into this issue.
The API reference for videos.create() has not changed:
It is only extend that has different options, and you will note that 15 of your first paragraph is not one of them:
Create an extension of a completed video.
Args:
prompt: Updated text prompt that directs the extension generation.
seconds: Length of the newly generated extension segment in seconds (allowed values: 4,
8, 12, 16, 20).
You will need to update the OpenAI library you use to one from within the last 3 days to get that 16 passed to the extend endpoint. Since you are getting a 400, and there has been no big announcement about “extend”, it may be that this update is anticipating features not actually present yet on the API for everyone (like some “audio” methods on Responses that were taken back out of the reference and libraries after a month, for audio “coming soon” that has not been delivered for a year).