---
title: "Burn styled captions into a video"
method: POST
path: "/v1/studio/captions"
tags: ["Captions"]
---

# Burn styled captions into a video

`POST /v1/studio/captions`

## Request

- Base URL: `https://apihub.co.il`
- URL: `https://apihub.co.il/v1/studio/captions`
- Auth: HTTP bearer

Transcribes the speech (99 languages incl. Hebrew, word-exact timing) and burns animated captions into the video: classic, Hormozi, karaoke, one-word, news, neon, typewriter and more — or your own style (font, size, colours, outline, box, position, animation). Pass `transcript_id` to reuse a transcript, or `captions` to burn your edited text.

**Billing:** Per second of output (≤720p / 1080p tiers; audio and images cheaper) + transcription seconds when captions or silence removal transcribe automatically + the voice clean-up per second of output when asked for (`audio.denoise` / `enhance`, off by default) and only when it found noise to reduce or enhanced the voice (`auto` on a clean recording is free) + effect seconds for a heavy engine effect in `effects` (its seconds on screen × its measured weight — GET /v1/effects). Failed renders are not charged. · **Rate limit:** 30/min · **Asynchronous**

## Headers

- `Idempotency-Key` string
- `X-Tag` string
- `x-wait-ms` integer

## Request body

- object
  - `hook` object
    - `at` object: Start at a word (instead of a time)
      - `edge` 'start' | 'end', required: The moment the word starts, or the moment it ends
      - `word` string, required: The word's id (w0001…)
      - `offset_ms` number: Shift in ms, applied after the cuts (default 0)
    - `id` string: Your name for the element; the render report uses it
    - `text` string, required: The hook, e.g. “3 טעויות שכולם עושים בשיווק”
    - `start` number: seconds (default 0) — or anchor it with `at` / `during`
    - `style` union: Preset id (GET /v1/studio/hook-styles) or overrides. In the text, *word* = accent colour, ~word~ = struck through, \n = a smaller second line
      - 'box_red' | 'yellow' | 'black' | 'outline' | 'clean' | 'type' | 'punch' | 'glitch' | 'marker' | 'words' | 'box' | 'counter' | 'shake' | 'rise' | 'strike' | 'blur' | 'flash' | 'look-clean' | 'look-bold-lime' | 'look-night' | 'look-warm'
      - object
        - `x` number
        - `y` number
        - `font` string
        - `size` number
        - `color` string
        - `margin` number
        - `preset` 'box_red' | 'yellow' | 'black' | 'outline' | 'clean' | 'type' | 'punch' | 'glitch' | 'marker' | 'words' | 'box' | 'counter' | 'shake' | 'rise' | 'strike' | 'blur' | 'flash' | 'look-clean' | 'look-bold-lime' | 'look-night' | 'look-warm'
        - `rotate` number
        - `shadow` number
        - `weight` integer
        - `outline` number
        - `position` 'top' | 'center' | 'bottom'
        - `animation` 'pop' | 'slide' | 'fade' | 'typewriter' | 'none' | 'punch' | 'glitch' | 'marker' | 'words' | 'box' | 'counter' | 'shake' | 'rise' | 'strike' | 'blur' | 'flash'
        - `uppercase` boolean
        - `background` string, nullable
        - `side_margin` number
        - `accent_color` string
        - `shadow_color` string
        - `outline_color` string
        - `letter_spacing` number
        - `max_chars_per_line` integer
    - `during` object: Start and end with a stretch of words (instead of a time and a duration)
      - `to` string, required: Id of the last word
      - `from` string, required: Id of the first word
      - `pad_end_ms` number: End this much later (default 0)
      - `pad_start_ms` number: Start this much earlier (default 0)
    - `subtext` string: Optional smaller second line
    - `duration` number: seconds on screen (default 3.5) — not with `during`
  - `trim` object
    - `end` number: seconds
    - `start` number: seconds
  - `fonts` object[]: Your brand fonts: up to 4 fonts from your brand kit, each { family, url } (the url as the brand kit gives it — your own files only). A caption, hook or text style may then name `family` as its `font`. Text a font cannot draw (Hebrew words in a Latin-only font) is set in the nearest built-in font, and the render's `warnings` say so
    - `url` string, uri, required
    - `latin` boolean
    - `arabic` boolean
    - `family` string, required
    - `hebrew` boolean
    - `category` 'sans' | 'serif' | 'display' | 'handwriting' | 'rounded'
    - `cyrillic` boolean
  - `style` union: A preset id (GET /v1/studio/caption-styles) or a style object; `preset` + fields overrides a preset. A retired preset still works: it renders as the default with a warning
    - 'classic' | 'hormozi' | 'tiktok' | 'karaoke' | 'one-word' | 'marker' | 'news' | 'neon' | 'quiet' | 'pop' | 'typewriter' | 'bounce' | 'underline' | 'elegant' | 'handwritten' | 'comic' | 'sticker' | 'drama' | 'cinema' | 'shadow' | 'lime' | 'retro' | 'scale' | 'bubble' | 'sport' | 'minimal' | 'slide' | 'volt' | 'neon-glow' | 'marker-tape' | 'keyword-pop' | 'keyword-box' | 'editorial' | 'poster' | 'broadcast' | 'soft' | 'cards' | 'cards-bold' | 'cards-neon' | 'kinetic-pop' | 'fire' | 'gold' | 'glass' | 'vhs' | 'candy' | 'look-clean' | 'look-bold-lime' | 'look-night' | 'look-warm'
    - object
      - `x` number
      - `y` number
      - `font` string
      - `glow` number
      - `mode` 'line' | 'cards'
      - `size` number
      - `skew` number
      - `color` string
      - `fonts` string[]
      - `anchor` 'top' | 'center' | 'bottom'
      - `hollow` boolean
      - `italic` boolean
      - `margin` number
      - `preset` 'classic' | 'hormozi' | 'tiktok' | 'karaoke' | 'one-word' | 'marker' | 'news' | 'neon' | 'quiet' | 'pop' | 'typewriter' | 'bounce' | 'underline' | 'elegant' | 'handwritten' | 'comic' | 'sticker' | 'drama' | 'cinema' | 'shadow' | 'lime' | 'retro' | 'scale' | 'bubble' | 'sport' | 'minimal' | 'slide' | 'volt' | 'neon-glow' | 'marker-tape' | 'keyword-pop' | 'keyword-box' | 'editorial' | 'poster' | 'broadcast' | 'soft' | 'cards' | 'cards-bold' | 'cards-neon' | 'kinetic-pop' | 'fire' | 'gold' | 'glass' | 'vhs' | 'candy' | 'look-clean' | 'look-bold-lime' | 'look-night' | 'look-warm'
      - `shadow` number
      - `weight` integer
      - `outline` number
      - `palette` object[]
        - `color` string, required: Text colour of the card
        - `background` string, nullable: Box behind the whole card (null = none)
      - `grouping` integer
      - `keywords` string[]
      - `position` 'bottom' | 'center' | 'top'
      - `animation` 'none' | 'fade' | 'highlight' | 'karaoke' | 'pop' | 'bounce' | 'typewriter' | 'slide' | 'word'
      - `max_lines` integer
      - `max_words` integer
      - `uppercase` boolean
      - `background` string, nullable
      - `past_color` string, nullable
      - `side_margin` number
      - `word_radius` number
      - `active_color` string
      - `active_scale` number
      - `shadow_color` string
      - `active_rotate` number
      - `keyword_color` string
      - `keyword_scale` number
      - `outline_color` string
      - `future_opacity` number
      - `letter_spacing` number
      - `underline_color` string
      - `word_background` string, nullable
      - `active_underline` number
      - `active_background` string, nullable
      - `background_radius` number
      - `emphasize_numbers` boolean
      - `keyword_background` string, nullable
      - `max_chars_per_line` integer
      - `keyword_active_color` string
  - `words` object[]: Your own timed words (ms) instead of a transcript
    - `id` string: Stable id (w0001…), as GET /v1/speech/transcripts/{id} returns it — anchors and cues name words by it
    - `end` number, required: ms
    - `keep` boolean: Never drop this word from the captions: a cut that leaves only a sliver of it shows it at the join (a word of your own script)
    - `text` string, required
    - `start` number, required: ms
    - `spoken` string: What was said, when the displayed text differs ("3,000" vs "three thousand")
    - `speaker` string, nullable
  - `output` object
    - `fit` 'crop' | 'blur' | 'pad': When the aspect ratio changes: crop the edges, blurred copy behind, or solid bars
    - `fps` number
    - `format` 'mp4' | 'webm' | 'mov' | 'gif' | 'mp3' | 'wav' | 'm4a' | 'jpg' | 'png'
    - `quality` 'draft' | 'standard' | 'high': high (default) = best picture; draft renders fastest for previews
    - `background` string: Bar colour for fit=pad
    - `resolution` '480' | '720' | '1080' | 'source': Short side in pixels (1080 = Full HD). `source` keeps the input size, max 1080
    - `aspect_ratio` 'original' | '9:16' | '16:9' | '1:1' | '4:5' | '4:3': 9:16 for Reels/TikTok/Shorts, 1:1 or 4:5 for feed, 16:9 for YouTube
  - `lead_ms` number: The highlight of a word switches this many ms before the word's frame (default: one output frame)
  - `brand_id` string: A brand of yours (GET /v1/brands): its logo (at its corner), colours, fonts and caption style fill what this request leaves out — anything you set here wins. `default` = your default brand
  - `captions` object[]: Edited captions (ms). Get them from GET /v1/speech/transcripts/{id}/captions, fix the text, send them back
    - `end` number, required: ms
    - `text` string, required
    - `start` number, required: ms
    - `words` object[]
      - `id` string: Stable id (w0001…), as GET /v1/speech/transcripts/{id} returns it — anchors and cues name words by it
      - `end` number, required: ms
      - `keep` boolean: Never drop this word from the captions: a cut that leaves only a sliver of it shows it at the join (a word of your own script)
      - `text` string, required
      - `start` number, required: ms
      - `spoken` string: What was said, when the displayed text differs ("3,000" vs "three thousand")
      - `speaker` string, nullable
  - `keyterms` string[]: Names and terms to recognise correctly (brands, people)
  - `video_url` string, uri, required: Public URL of the source video (mp4, mov, webm, mkv…) — or the `url` of a previous render
  - `language_code` string: Spoken language for automatic transcription, e.g. `he`, `en`. Omit to detect
  - `speech_models` string[]
  - `transcript_id` string: Reuse a transcript from /v1/speech/transcripts (no transcription charge). Omit to transcribe automatically
  - `caption_language` string: Write the captions in this language (two letters, e.g. `en`, `he`, `ru`) when the video is spoken in another: the speech is translated sentence by sentence, each line keeps its sentence's time span (one small text-model call on your account, billed at the POST /v1/ai/text rate). Omit = the spoken language. Ignored when you send `captions` of your own or the spoken language is the same. Word-by-word karaoke becomes an even sweep over each translated line

## Response `200`

Completed (or 202 while processing)

- object
  - `id` string: Execution id — stable across internal retries; use it with GET /v1/executions/{id}
  - `status` 'pending' | 'processing' | 'completed' | 'partial' | 'failed' | 'cancelled' | 'timeout'
  - `operation` string
  - `tag` string, nullable: Your X-Tag, if sent
  - `created_at` string, date-time
  - `completed_at` string, date-time, nullable
  - `output` object: Operation result (see each operation). While a Studio render is processing: `stage` (queued · transcribing · downloading · preparing · cleaning_voice · mixing_audio · rendering · finishing), `phase` (the engine's: download · prepare · voice · audio · encode · qa · upload, or null), `progress` (a percent, 0–100) and `progress_fraction` (0–1), `eta_seconds` (seconds left, never below 0) and `estimate_seconds`
  - `error` string, nullable
  - `usage` object
    - `credits_charged` number, nullable
    - `credits_reserved` number
    - `estimated_credits` number
    - `cost_source` 'provider_reported' | 'calculated' | 'estimated' | 'null', nullable
    - `provider_usage` object, nullable: Normalised consumption, e.g. { VIDEO_SECOND: 22.4 }
  - `balance` object
    - `available` number
    - `reserved` number

## Other responses

- `202`: Processing — poll GET /v1/executions/{id}
- `400`: Invalid input
- `402`: Insufficient credits / project budget
- `404`: Resource not found (or not yours)
- `429`: Rate limited
- `503`: Service temporarily paused

---

[API](https://skmtc.dev/apihub/apis/apihub-one-api-for-chat-image-video-ai.md) · [All operations](https://skmtc.dev/apihub/apis/apihub-one-api-for-chat-image-video-ai/llms.txt) · [OpenAPI document](https://skmtc.dev/apihub/apis/apihub-one-api-for-chat-image-video-ai/revisions/a8caa42835ce?raw)
