Caption video (one call)
caption_videoPREFER THIS for 'add/burn subtitles to this video'. One call runs transcribe -> optional translate -> burn and returns the finished MP4 link plus SRT, VTT, JSON transcript, and credits charged. Source: sourceUrl (public https link: direct file, chat attachment URL, Google Drive or Dropbox share link; YouTube is refused) or fileId (from create_upload / import_url / upload_base64). Price is exactly the sum of the steps, no surcharge: transcribe 1 + burn 4 credits per audio minute (+2 with translateTo); 1 credit = 1 cent; call quote with operation caption first if unsure. Over-limit input (2048 MB fileId, 80 MB sourceUrl, 3 h) fails with 422 limit_exceeded and charged:false; failed jobs refund automatically. wait (default true) blocks up to waitSeconds (default 45, max 50) and returns the finished result; if it is still running you get status queued/running, the job id, step, progress (0-100), eta_seconds and pollAfterSeconds: poll get_job after pollAfterSeconds, or pass webhookUrl / notifyEmail. If it fails after transcribing, resume_job reuses the transcript and charges only the rest. Use platform (tiktok, instagram_reels, youtube_shorts, youtube, ...; see list_platforms) so captions stay clear of the app UI. Person wants to check the text first? Pass review:true: it transcribes now and returns reviewUrl; the burn is charged only on approval. To fix the text yourself, use transcribe -> edit_transcript -> burn_captions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| wait | No | Block until done, up to waitSeconds. Default true. | |
| fileId | No | Id from create_upload, import_url, or upload_base64. | |
| preset | No | Caption style preset id or name (list_presets), or your own saved preset as custom:cp_... (save_custom_preset). Default Clarity. | |
| review | No | Human review first: transcribes now, returns reviewUrl for the person; the burn runs and is charged only when they approve. Not with translateTo. | |
| autoFit | No | Default true: caption size, words per caption (4 on 9:16, 5 on 1:1, 7 on 16:9), and a default safe zone follow the video shape, so text reads the same at 720p and 1080p and stays clear of app UI. Pass false only when the user wants the preset's exact fixed pixel sizes. Same price. | |
| glossary | No | Names and brand terms to spell correctly, e.g. ['AwesomeVideo']. | |
| language | No | Spoken language (BCP-47, e.g. es, en). Omit for auto-detect. | |
| platform | No | Target platform: tiktok, instagram_reels, youtube_shorts, youtube, ... (aliases reels, shorts). Keeps captions clear of the app UI. Same price. | |
| faceAvoid | No | true = move captions off faces (samples faces at 2 fps, same price; result.faceAvoid.faceLayout). Shortcut for styleOverrides.faceAvoid. | |
| sourceUrl | No | Public link to the video/audio. Direct https file, chat attachment URL, Google Drive or Dropbox share link. Not YouTube. | |
| maxCredits | No | Refuse the job if it would cost more than this many credits. | |
| webhookUrl | No | Public https URL, POSTed a signed JSON body when the job finishes. | |
| audioVisual | No | Audio-only input (mp3/m4a/wav...): render the web editor's audio export (visualizer + captions) on the server, same price as the burn. On a video input it returns 422 audio_visual_needs_audio_input (not charged). Omit it on audio to get the default bars. | |
| notifyEmail | No | Email when the job finishes. Free. | |
| translateTo | No | Burn subtitles translated to this language (ISO 639-1, e.g. en). Adds 2 credits/min. | |
| waitSeconds | No | Default 45, max 50. | |
| instructions | No | review only: note shown to the reviewer. | |
| brandPresetId | No | Saved brand preset (font, colors, position, logo). | |
| highlightColor | No | #RRGGBB for highlightWords. Default #FACC15. | |
| highlightWords | No | Shortcut: words or phrases to color in every caption (accent/case-insensitive), e.g. ["AwesomeVideo", "gratis"]. Maps to styleOverrides.wordHighlights rule {id:"custom", words, color}. Same price. | |
| idempotencyKey | No | Same key returns the same job instead of charging twice. | |
| styleOverrides | No | Per-call style changes deep-merged onto the preset (same fields as list_presets style; null removes a field), validated with the renderer schema and bundled fonts. Example {"fontSize":72,"maxWordsPerCaption":2,"wordEntrance":"bounce"}. Same price. No need to save_custom_preset. Every field with examples: get_style_reference. | |
| durationSeconds | No |