Create Dub
POST /api/v2/dubs
One call to upload and dub. Send the video (or a URL to it) and the dub starts immediately. Two input modes:
a) Upload a file (multipart/form-data) — streams straight through to storage;
max 1 GB per file:
curl -X POST https://dublab.app/api/v2/dubs \
-H "apikey: YOUR_API_KEY" \
-F source_lang=en \
-F dest_lang=tr \
-F "file=@my-video.mp4;type=video/mp4"b) Point at a URL (application/json) — we fetch it server-side (no upload):
curl -X POST https://dublab.app/api/v2/dubs \
-H "apikey: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"source_url": "https://example.com/my-video.mp4", "dest_lang": "tr"}'Parameters (form field or JSON key):
| Field | Type | Required | Description |
|---|---|---|---|
| file | binary | one of file/source_url | The video/audio to dub (multipart only, ≤ 1 GB) |
| source_url | string | one of file/source_url | Public http/https URL we fetch server-side |
| dest_lang | string | Yes | Target language code (see Languages) |
| source_lang | string | No | Source code or "auto" (default auto) |
| name | string | No | Display name (defaults to the filename / URL basename) |
| duration | number | No | Duration hint in seconds (billing uses server-measured length) |
| is_studio_quality | boolean | No | true for studio quality (2× credits) |
Response (201):
{
"id": "ce14fea7-9c5b-...",
"dubbing_id": "ce14fea7-9c5b-...",
"project_id": "c13d6b57-...",
"name": "my-video.mp4",
"type": "video/mp4",
"source_lang": "en",
"dest_lang": "tr",
"external_status_id": 2,
"progress_percentage": 0,
"external_error_message": null,
"duration": 0,
"measured_duration": null,
"is_studio_quality": false,
"source": "api",
"created_at": "2026-07-15T03:16:25.687Z",
"outputs": {}
}
The dub is now queued. Poll GET /api/v2/dubs/{id} for
external_status_id (reaches 5 when complete) — the outputs map fills in with
download links once it's done.
Possible errors: 400 (missing dest_lang, no file/source_url, or an
unreachable/blocked source_url), 402 (no credits), 413 (file over 1 GB),
401 (bad key), 502 (backend unavailable — the response includes the id).
Billing: credits are charged once, when the dub completes, against the server-measured duration — never the
durationyou send.