Sora Videos Generation API
POSThttps://api.acedata.cloud/sora/videos
This API can generate videos by inputting prompt words and first and last frame images.
Related Products
Sora - Ace Data Cloud
Sora video generation platform, directly interfaces with this API, high-speed and stable availability.
Request Headers
acceptstring
Specify the format of the response returned by the server. If not specified, the default format is `application/json`; if specified as `application/x-ndjson`, the response will be returned in a block-streaming format of JSON separated by newline characters.
Please select
authorizationstring
Bearer token
Request Body
sizestring
Video size/resolution. Version 1.0: `small` (standard definition) or `large` (high definition, only supported by `sora-2-pro`); Version 2.0: pixel resolution, such as `720x1280`, `1280x720`, `1024x1792`, or `1792x1024`, default is `720x1280`.
Please select
durationinteger
Video duration (seconds). Version 1.0: `sora-2` supports 10 or 15 seconds, `sora-2-pro` supports 10, 15, or 25 seconds; Version 2.0: supports 4, 8, or 12 seconds. Default values: Version 1.0 is 15, Version 2.0 is 4.
Please select
orientationstring
Video orientation, applicable only to version 1.0. `landscape` is horizontal (16:9), `portrait` is vertical (9:16).
Please select
promptstringRequired parameter
Describe the text prompts for the video content to be generated.
character_endinteger
The seconds at which the character appears at the end of the video, applicable only to version 1.0. Required when providing `character_url`. The difference between `character_end` and `character_start` must be between 1 and 3 seconds.
character_urlstring
The video URL containing the characters to be used is only applicable for version 1.0. Real people must not appear in the video, otherwise the task will fail.
character_startinteger
The seconds at which the character starts appearing in the video, applicable only to version 1.0. Required when providing `character_url`.
modelstringRequired parameter
Models used for generating videos. `sora-2` is the standard model, while `sora-2-pro` is the high-quality model that supports longer video durations.
versionstring
The API version used. Version 1.0 supports the `duration` (10/15/25 seconds), `orientation`, `size` (`small`/`large`), `image_urls`, and `character` parameters; version 2.0 supports `duration` (4/8/12 seconds), pixel-based `size` (such as `720x1280`), and `image_urls` (with the first image as a reference).
Please select
image_urlsarray
Array of reference image URLs for guiding video generation. Version 1.0 supports multiple images; Version 2.0 only uses the first image, and the image size should be consistent with the `size` parameter. Please do not include images of real people or existing American brand logos, as this may result in task failure.
callback_urlstring
The callback URL that will be called after the video generation is complete.
asyncboolean
Whether to process in asynchronous mode. When set to `true`, the interface immediately returns `task_id`, without the need to provide `callback_url`, and then the result can be obtained by polling the corresponding task query interface; if `callback_url` is also provided, the result will be pushed to that callback address.
Please select
Response

Integration guide
Kind reminder: For streaming requests, the above code may not be fully applicable. Please refer to the integration documentation for changes.
Sora Video Generation
Allow Use General Balance
When 'Allow General Balance' is enabled, the general balance is used automatically if an app's balance is insufficient.