Media

Video generation

Text and image to video, and stock-footage edits.

All video endpoints share the same auth (sk_…). Each provider charges credits up-front and refunds on failure.

POST/api/v1/video— Veo / Meta AI / Meta Muse / Omni Flash / Omni 1.2 / Google Vids / Seedance

Single endpoint that fans out to multiple providers based on model. All durations are inclusive of audio; failures are refunded automatically.

Veo 3.1 family (Google, 60-120 s, 8 s fixed clip):

FieldTypeRequiredDescription
promptstringyesEnglish, 10-2000 chars.
modelstringnoveo-3.1-fast (default, 7,500 cr) / veo-3.1-lite (9,100 cr) / veo-3.1 (17,000 cr, HQ).
resolutionstringno720p (default) / 1080p (~1.5× cr).
aspect_ratiostringno16:9 (default) or 9:16 (portrait, for Reels/Shorts). Every Veo tier accepts both.
durationnumbernoFixed at 8 s for the Veo 3.1 family. Leave it out or send 8. With mode_image: "ingredient" any other value is a 400; otherwise it is ignored.
image_base64stringnoLegacy single-image alias for ref_images[0] (base64 data URI).
ref_imagesstring[]noReference images as base64 data URIs (or http(s) URLs). frame mode: up to 2 (ordered [start, end]). ingredient mode: up to 3 on every Veo tier.
mode_imagestringnoframe (default) — first image = start frame, second = end frame. ingredient — subject/style references. Supported across all Veo 3.1 variants.

Omni Flash (model: "omniflash", 16:9 / 9:16). Duration-tiered, and a 360p draft size at half the credits:

Duration360p draft720p
4 s2,3444,688
6 s3,1256,250
8 s (default)3,9077,813
10 s4,6889,375

360p exists to make iteration cheap: five drafts cost less than one 720p render. There is no size above 720p on this model.

Fields: prompt, model: "omniflash", aspect_ratio (16:9 / 9:16), resolution (360p / 720p, default 720p), duration (4 / 6 / 8 / 10), ref_images (optional, up to 7 base64 data URIs or http(s) URLs). Images are always used as references (visual context); mode_image is ignored on Omni Flash, so there is no start / end frame mode.

Omni 1.2 (model: "omni-1.2", 16:9 / 9:16) — the newer Omni Flash: same fields, same up to 7 references and the same 360p draft at half price, with any whole length from 3 to 15 seconds, priced at 1.5× Omni Flash:

Duration360p draft720p
3 s2,9305,859
4 s3,5167,032
6 s4,6889,375
8 s (default)5,86011,720
10 s7,03214,063
12 s8,20416,407
15 s9,96119,922

Fields: prompt, model: "omni-1.2" (omni_flash_12 is accepted too), aspect_ratio, resolution (360p / 720p), duration (whole number 3-15, default 8), ref_images (optional, up to 7). Clips longer than 10 s can take longer to start.

Google Vids (model: "google-vids", 16:9 / 9:16) — 900 credits per second, 1080p at 1.5×:

Duration720p1080p
3 s2,7004,050
5 s (default)4,5006,750
8 s7,20010,800
10 s9,00013,500
15 s13,50020,250

Fields: prompt, model: "google-vids", aspect_ratio (16:9 / 9:16), resolution (720p / 1080p), duration (any whole number 3-15, default 5), ref_images (optional, up to 3 subject/style references), mode_image: "frame" with a single image to start the clip from it. No end frame and no voice: either is a 400.

Meta Muse (model: "meta-muse") — 1,200 credits per second, any whole length from 1 to 60 seconds, with sound. The longest single clip on the API.

DurationCredits
5 s6,000
8 s (default)9,600
15 s18,000
30 s36,000
60 s72,000
FieldTypeRequiredDescription
promptstringyes10-2000 chars.
modelstringyesmeta-muse
durationnumbernoWhole number 1-60, default 8. Anything else is a 400 (it is not rounded, because the price follows the length).
aspect_ratiostringno16:9 (default) / 9:16 / 1:1 / 4:3 / 3:4 / 21:9. Another value is a 400.
start_framestringnoOne image (base64 data URI or http(s) URL) used as the opening frame.
ref_imagesstring[]no1 to 3 images. One image is the opening frame; two or three are references, used in the order given. Not together with start_frame.

There is no resolution (the model chooses it; the field is ignored and absent from the response). voice, end_frame, reference_video and a count other than 1 are a 400. All validation errors are returned before any credit is taken.

A short clip usually answers 200 with video_url. A longer one answers 202 with status: "processing" and a task_id after about 150 seconds: poll GET /api/v1/video?task_id=... until it returns completed (with video_url) or failed (credits refunded). The success body carries image_mode: "start_frame", "references" or null.

cURL
curl -X POST "https://www.dubvoice.ai/api/v1/video" \
  -H "Authorization: Bearer sk_..." \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "a paper boat drifting down a rainy street, slow push in, cinematic",
    "model": "meta-muse",
    "aspect_ratio": "9:16",
    "duration": 30
  }'

Seedance 2.0 and 2.5 (model: "seedance-2.0", "seedance-2.0-fast", "seedance-2.5" or "seedance-2.5-variant") — priced per second by resolution, with or without sound at the same price. One model covers text to video, opening and closing frames, and reference images: send no images, images with mode_image: "frame", or images with mode_image: "reference".

ModelLength480p720p1080p4K
seedance-2.04-15 s19,000/s40,900/s101,100/s210,000/s
seedance-2.0-fast4-15 s16,900/s36,400/s——
seedance-2.54-30 s30,200/s65,300/s (68,100/s with references)160,000/s (167,500/s with references)—
seedance-2.5-variant4-30 s31,500/s68,000/s (70,800/s with references)166,400/s (174,200/s with references)—

A 5-second 720p clip is 204,500 credits on 2.0, 182,000 on 2.0 Fast, 326,500 on 2.5 and 340,000 on 2.5 Variant.

FieldTypeRequiredDescription
promptstringyes10-2000 chars.
modelstringyesOne of the four ids above.
durationnumbernoWhole seconds in the model's range, default 5. Anything else is a 400.
resolutionstringno480p / 720p (default) / 1080p / 4k (2.0 only). Fast stops at 720p. Another value is a 400.
aspect_ratiostringno16:9 (default) / 9:16 / 1:1 / 4:3 / 3:4 / 21:9 / adaptive.
audiobooleannoGenerate sound with the clip. Default true; it does not change the price.
ref_imagesstring[]noBase64 data URIs or http(s) URLs. With mode_image: "frame" (default): one opening frame, or an opening and a closing frame. With mode_image: "reference": up to 9 images that guide the look (not on seedance-2.0-fast).
mode_imagestringnoframe or reference.

Seedance renders take a few minutes, so the response is always 202 with status: "processing" and a task_id. Poll GET /api/v1/video?task_id=... every 10 seconds until it returns completed (with video_url) or failed (credits refunded). All validation happens before any credit is taken.

cURL
curl -X POST "https://www.dubvoice.ai/api/v1/video" \
  -H "Authorization: Bearer sk_..." \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "a red fox runs through fresh snow at sunrise, tracking shot",
    "model": "seedance-2.0",
    "duration": 5,
    "resolution": "720p",
    "aspect_ratio": "16:9",
    "audio": true
  }'

Meta AI (model: "meta") — flat 2,000 credits per clip, the cheapest video model here.

FieldTypeRequiredDescription
promptstringyesEnglish scene description.
modelstringyesmeta
aspect_ratiostringno16:9 (default) / 9:16 / 1:1.
resolutionstringno720p (default) / 480p.
start_framestringnoBase64 data URI or http(s) URL. Supplying it switches Meta to image-to-video.
end_framestringnoOptional second frame — Meta interpolates from start to end.

duration is ignored: Meta returns its own clip length, which is why it prices flat. Meta does not use ref_images — pass start_frame / end_frame instead (ref_images[0] and [1] are accepted as a fallback so callers reusing the Omni Flash shape still work).

cURL
curl -X POST "https://www.dubvoice.ai/api/v1/video" \
  -H "Authorization: Bearer sk_..." \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "waves crashing on a rocky shore at dawn, cinematic",
    "model": "meta",
    "aspect_ratio": "9:16",
    "resolution": "720p"
  }'

POST/api/video/grok— Grok Imagine

xAI Grok video. Renders synchronously (~60-120 s) and returns the final file_url; refunds credits automatically on failure.

FieldTypeDefaultNotes
promptstring—English, 10-5000 chars
durationnumber66, 10 or 15 seconds only — 15 or more becomes 15 s, 10 to 14 becomes 10 s, anything lower becomes 6 s.
resolutionstring480p480p / 720p / 1080p
aspect_ratiostring16:916:9, 9:16, 1:1, 2:3, 3:2
image_base64string—data:image/... URI — auto-switches to image-to-video.
image_urlstring—Public http(s) URL — same effect as image_base64.
ref_imagesstring[]—With first_frame: true: 1 to 3 frames in order. One = opening; two = opening + closing; three = opening + middle + closing. A fourth is a 400. With first_frame: false: one reference image.
first_framebooleantrueWith images: true treats them as frames of the clip (the aspect follows the first image); false uses the image as a subject/style reference instead.

Cost — flat-rate matrix (per clip, not per second):

Duration480p720p1080p
6 s3,000 cr4,000 cr6,000 cr
10 s5,000 cr5,500 cr8,250 cr
15 s7,500 cr8,250 cr12,375 cr

15 seconds is the longest single clip on the platform — every Veo 3.1 tier is fixed at 8 s.

Response:

JSON
{
  "id": "...", "status": "completed",
  "file_url": "https://...mp4",
  "credits_used": 3000, "duration": 6, "resolution": "480p", "aspect_ratio": "16:9",
  "created_at": "..."
}

POST/api/v1/stock-video— Stock-footage edit

Auto-edited video from a stock library, driven by a script + topic. Optionally re-times to a supplied narration audio. Async — returns a job_id; poll GET /api/v1/stock-video?job_id=… for the final video_url. Credits are refunded automatically on failure.

FieldTypeRequiredDescription
textstringyesScript / narration text (10 – 50,000 chars). Drives the credit cost.
topicstringyesStock library search topic (e.g. ocean waves, forest hike).
audio_urlstringnoPublic http(s) URL to narration audio (MP3/M4A/WAV). The render backend fetches it, so there is no size limit on this path. If set, the cut is re-timed to match the audio and the narration is muxed in.
audio_data_uristringnoAlternative to audio_url: base64 data:audio/*;base64,… URI. Capped at 3 MB — it travels in the request body, which the platform limits to 4.5 MB, and base64 adds a third. Use audio_url for anything longer.

Cost: 500 credits per 1,000 characters (minimum 500 cr).

cURL
curl -X POST "https://www.dubvoice.ai/api/v1/stock-video" \
  -H "Authorization: Bearer sk_..." \
  -H "Content-Type: application/json" \
  -d '{
    "text": "The Pacific is the largest and deepest ocean on Earth...",
    "topic": "ocean waves",
    "audio_url": "https://example.com/narration.mp3"
  }'

Status poll response when ready:

JSON
{
  "job_id": "abc123...",
  "status": "DONE",
  "video_url": "https://....supabase.co/storage/v1/object/public/tts-audio/videos/...mp4"
}

The first completed poll may return a relative video_url (/api/text-to-stock-video/download?job_id=...) — prefix it with https://www.dubvoice.ai to download. Later polls return the storage URL shown above.

Status values: QUEUED → PROCESSING → DONE (or ERROR).

Search docs

Find a page or an endpoint