Model parameters
- Model IDs:
sora-2(Sora 2) andsora-2-pro(Sora 2 Pro) - Pricing: Check the model marketplace for current prices.
- Endpoint:
https://geekai.co/api/v1/videos/generations - Parameters: Video generation API
- Authentication: Get an API key
These models do not support the following common video generation parameters:
negative_promptimage_tailwith_audioaspect_ratioresolution(usesizeinstead)qualityfpswatermark
size values:
720x12801280x7201024x1792(Sora 2 Pro only)1792x1024(Sora 2 Pro only)
image in place of OpenAI’s input_reference to provide a single reference image, either as a URL or as Base64-encoded image data.
Use duration in place of OpenAI’s seconds to set the video length. Supported values are 4 (default), 8, and 12 seconds.
Model pricing
Sora 2 and Sora 2 Pro are billed per second of generated video. The rate depends on the output size:
When using a discounted GeekAI route, multiply the list price by the route’s price multiplier. For example, on the speed-prioritized high-availability route with a multiplier of
0.8, a four-second Sora 2 clip costs 0.75 x 4 x 0.8 = 2.4 yuan. At the same size, Sora 2 Pro costs 2.25 x 4 x 0.8 = 7.2 yuan. Apply the same calculation to other configurations.
Content restrictions
The Sora API enforces the following restrictions:- No adult content: only material suitable for viewers under 18 is allowed. A setting to change this restriction is planned for the future.
- Copyrighted characters and music are rejected.
- Real people, including public figures, cannot be generated.
- Input images containing human faces are currently rejected.
Text to video
Generate a video from a text description:Image to video
A reference image guides generation and serves as the first frame. This helps preserve the look of a brand asset, character, or setting. The image must match the target video’s dimensions and resolution:Asynchronous tasks
Video generation can take some time. For longer requests, use GeekAI’s asynchronous generation mode. The video generation API defaults toasync: false: the request waits for the finished video. Set async to true to receive a task ID instead, then poll for the generation status.
Create a video generation task
task_status to determine whether generation has finished. The four possible values are:
pending: The task has been created and is waiting to be processed.running: Generation is in progress.succeed: Generation succeeded and the result is available.failed: Generation failed, for example because of a content policy violation or another error.
task_status is succeed, then read the generated video URL:
