Sample - OpenAI API
POST/videos/extensionsDeprecated

Create a video extension

Creates an extension of a completed video. Provide the source video, an updated prompt, and an extension length through seconds; the request can use JSON or multipart form data, and the operation is deprecated. The response represents a video job whose lifecycle you can monitor through its status and progress.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

3 body fields

Parameters for extending a completed video, supplied as JSON or multipart form data.

videoobjectrequired
Reference to the completed video to extend.
promptstringrequired
Updated text prompt that directs the extension generation.
secondsstringrequired
Length of the newly generated extension segment in seconds (allowed values: 4, 8, 12, 16, 20).
Allowed:4812

3 status codes
200Returns a video job containing its identifier, model, lifecycle `status`, `progress`, creation and completion timestamps, expiration timestamp, prompt, resolution, duration, source video reference, and any error details.
idstringrequired
Unique identifier for the video job.
objectstringrequired
The object type, which is always `video`.
Allowed:videoDefault:video
modelstringrequired
The video generation model that produced the job.
statusstringrequired
Current lifecycle status of the video job.
Allowed:queuedin_progresscompletedfailed
progressintegerrequired
Approximate completion percentage for the generation task.
created_atintegerrequired
Unix timestamp (seconds) for when the job was created.
completed_atintegerrequired
Unix timestamp (seconds) for when the job completed, if finished.
expires_atintegerrequired
Unix timestamp (seconds) for when the downloadable assets expire, if set.
promptstringrequired
The prompt that was used to generate the video.
sizestringrequired
The resolution of the generated video.
Allowed:720x12801280x7201024x17921792x1024
secondsstringrequired
Duration of the generated clip in seconds. For extensions, this is the stitched total duration.
remixed_from_video_idstringrequired
Identifier of the source video if this video is a remix.
errorobjectrequired
Error payload that explains why generation failed, if applicable.
429Returned when the request rate exceeds the allowed limit. A `slow_down` error indicates that traffic increased too quickly; reduce the request rate and increase it gradually.

One documented failure

  • slow_down

    Your request rate increased too quickly. Please reduce the request rate and gradually increase it again.

    Traffic increased too quickly

errorobjectrequired
503Returned when the service is temporarily unavailable. A `server_is_overloaded` error indicates that the requested model is temporarily overloaded; retry after a brief delay.

One documented failure

  • server_is_overloaded

    The model is temporarily overloaded. Please retry your request after a brief delay.

    The requested model is temporarily overloaded

errorobjectrequired

Error handling

A 429 is returned when the request rate exceeds the allowed limit; reduce your request rate before retrying. A 503 is returned when the service or requested model is temporarily unavailable; retry after a brief delay. video, prompt, and seconds are required, prompt must contain 1 to 32,000 characters, and seconds must be one of 4, 8, or 12.