Sora 2
Provider list prices: no platform markup, pay-as-you-go. These are official list prices. Logged-in customers may see effective prices including workspace discounts on /console/pricing.
Use Sora 2 in 30 seconds
Asynchronous job API: create a task and poll it, or hold the request open with Prefer: wait. POST /v1/videos
import time
import requests
BASE = "https://synthorai.io/v1"
HEADERS = {"Authorization": "Bearer sk-syn-..."}
# 1) create the video generation job (POST /v1/videos)
task = requests.post(
f"{BASE}/videos",
headers=HEADERS,
json={
"model": "sora-2",
"prompt": "a watercolor lighthouse at dawn, waves rolling in, camera pulling back",
"resolution": "720p",
"duration": 5,
},
).json()
# 2) poll the job until it reaches a terminal state
while task["status"] in ("queued", "in_progress"):
time.sleep(5)
task = requests.get(f"{BASE}/videos/{task['id']}", headers=HEADERS).json()
# 3) completed → signed video URL (valid ~24h — download and store it promptly)
if task["status"] == "completed":
print(task["data"][0]["url"])
else:
print(task["error"])const HEADERS = {
Authorization: "Bearer sk-syn-...",
"Content-Type": "application/json",
};
interface VideoTask {
id: string;
status: "queued" | "in_progress" | "completed" | "failed" | "cancelled";
data?: Array<{ url: string }>;
error?: { code: string; message: string };
}
// 1) create the video generation job (POST /v1/videos)
const created = await fetch("https://synthorai.io/v1/videos", {
method: "POST",
headers: HEADERS,
body: JSON.stringify({
model: "sora-2",
prompt: "a watercolor lighthouse at dawn, waves rolling in, camera pulling back",
resolution: "720p",
duration: 5,
}),
});
let task = (await created.json()) as VideoTask;
// 2) poll the job until it reaches a terminal state
while (task.status === "queued" || task.status === "in_progress") {
await new Promise((r) => setTimeout(r, 5000));
const res = await fetch(`https://synthorai.io/v1/videos/${task.id}`, { headers: HEADERS });
task = (await res.json()) as VideoTask;
}
// 3) completed → signed video URL (valid ~24h — download and store it promptly)
if (task.status === "completed") console.log(task.data?.[0]?.url);
else console.error(task.error);# Create the job; "Prefer: wait" holds the request up to 60s and returns the
# completed task when generation finishes in time (else the queued task).
curl https://synthorai.io/v1/videos \
-H "Authorization: Bearer sk-syn-..." \
-H "Content-Type: application/json" \
-H "Prefer: wait=60" \
-d '{
"model": "sora-2",
"prompt": "a watercolor lighthouse at dawn, waves rolling in, camera pulling back",
"resolution": "720p",
"duration": 5
}'
# Still queued / in_progress? Poll until completed → data[0].url (valid ~24h).
curl https://synthorai.io/v1/videos/vid_9f2e8c1a4b7d \
-H "Authorization: Bearer sk-syn-..."package main
import (
"bytes"
"encoding/json"
"fmt"
"net/http"
"time"
)
const base = "https://synthorai.io/v1"
type videoTask struct {
ID string `json:"id"`
Status string `json:"status"`
Data []struct {
URL string `json:"url"`
} `json:"data"`
}
func call(method, url string, body []byte) (t videoTask) {
req, _ := http.NewRequest(method, url, bytes.NewReader(body))
req.Header.Set("Authorization", "Bearer sk-syn-...")
req.Header.Set("Content-Type", "application/json")
resp, _ := http.DefaultClient.Do(req)
defer resp.Body.Close()
json.NewDecoder(resp.Body).Decode(&t)
return t
}
func main() {
// 1) create the video generation job (POST /v1/videos)
payload, _ := json.Marshal(map[string]any{
"model": "sora-2",
"prompt": "a watercolor lighthouse at dawn, waves rolling in, camera pulling back",
"resolution": "720p",
"duration": 5,
})
task := call("POST", base+"/videos", payload)
// 2) poll the job until it reaches a terminal state
for task.Status == "queued" || task.Status == "in_progress" {
time.Sleep(5 * time.Second)
task = call("GET", base+"/videos/"+task.ID, nil)
}
// 3) completed → signed video URL (valid ~24h — download and store promptly)
if task.Status == "completed" {
fmt.Println(task.Data[0].URL)
}
}import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
// JDK built-in HttpClient — no extra dependency needed.
HttpClient http = HttpClient.newHttpClient();
// 1) create the job; "Prefer: wait=60" holds the request up to 60s and
// returns the completed task when generation finishes in time
HttpRequest create = HttpRequest.newBuilder(URI.create("https://synthorai.io/v1/videos"))
.header("Authorization", "Bearer sk-syn-...")
.header("Content-Type", "application/json")
.header("Prefer", "wait=60")
.POST(HttpRequest.BodyPublishers.ofString("""
{"model": "sora-2",
"prompt": "a watercolor lighthouse at dawn, waves rolling in, camera pulling back",
"resolution": "720p", "duration": 5}"""))
.build();
String task = http.send(create, HttpResponse.BodyHandlers.ofString()).body();
System.out.println(task); // {"id":"vid_…","status":…} — completed → data[0].url
// 2) still queued / in_progress? Poll GET https://synthorai.io/v1/videos/{id} until the
// status turns completed, then download data[0].url (valid ~24h).About Sora 2
Sora 2 is OpenAI's video generation model that produces short clips together with synchronized audio — dialogue, sound effects, and music generated alongside the visuals.
- It creates video from a text prompt or from a reference image, in a controllable, physically grounded style.
- Synthorai serves Sora 2 through the asynchronous /v1/videos job API — create a task, then poll it (or hold the request open with Prefer: wait) until the signed video URL is ready — at 720p, 24 fps, 4 to 12 seconds, in 16:9 or 9:16, and bills per output second.
Specs & limits
| Modalities | text + image → video |
| Features | vision |
| Resolution | 720p |
| Clip length | 4-12 s |
| Frame rate | 24 fps |
| Aspect ratios | 16:9 · 9:16 |
| Video inputs | text-to-video · image-to-video (single reference image) |
| Native audio | Yes — generates sound |
| Format | .mp4 |
| Notable | OpenAI's Sora 2 video model, which generates video together with synchronized audio (dialogue, sound effects, and music). Synthorai serves it via the async /v1/videos job API at 720p, 24 fps, 4-12 s, 16:9 or 9:16, and bills per output second. |
FAQ
Is the Sora 2 API free to try?
Yes: new accounts get 10 trial calls and up to $1 in free credit, no card required. That's enough to try Sora 2 against your real workload before adding a payment method.
What is Sora 2 best at?
OpenAI video model with synchronized audio, plus text-to-video and image-to-video and 720p, 24 fps, 4-12 seconds. See the About section for the full picture from the vendor's own release notes.
How much does Sora 2 cost?
Sora 2 costs $0.1 per second of generated video on Synthorai. Only successful generations are billed: pay-as-you-go, no platform markup, no subscription.
How do I generate videos with the Sora 2 API?
POST to /v1/videos on Synthorai with model="sora-2" to create an asynchronous job, then poll the task — or hold the request open with a Prefer: wait header — until the video URL is ready. No vendor SDK is needed.
How do I get access to Sora 2?
Point your existing OpenAI SDK at base_url="https://synthorai.io/v1", set model="sora-2", and you're done. One API key covers every model on the gateway.