{
  "openapi": "3.0.1",
  "info": {
    "title": "Add Subtitles to Video – Auto Captions, Burn SRT (Whisper)",
    "description": "Add subtitles to video automatically: Whisper auto captions in 99 languages burned into MP4, or burn your own SRT/VTT. TikTok-style word highlight, uppercase, box, colours, font size, position. Get MP4 + SRT + VTT links. From $0.04 per video minute.",
    "version": "0.1",
    "x-build-id": "A3EYKeLykEujeHTjh"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/gazidev~video-auto-subtitles/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-gazidev-video-auto-subtitles",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/gazidev~video-auto-subtitles/runs": {
      "post": {
        "operationId": "runs-sync-gazidev-video-auto-subtitles",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/gazidev~video-auto-subtitles/run-sync": {
      "post": {
        "operationId": "run-sync-gazidev-video-auto-subtitles",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "videoUrls": {
            "title": "Video file URLs",
            "type": "array",
            "description": "Direct links to video files: MP4, MOV, WebM, MKV, M4V, AVI (your CDN, S3/R2/GCS bucket, Dropbox or Google Drive file shared as 'Anyone with the link'). To burn your own subtitles for a video, put both links on one line: `https://…/video.mp4 | https://…/subtitles.srt`. **YouTube, TikTok, Instagram, Facebook, X, Vimeo… page links are rejected**: their terms of service forbid downloading. Only submit videos you have the right to edit.",
            "default": [
              "https://upload.wikimedia.org/wikipedia/commons/b/b8/The_Numbers_Are_In-_Where_Does_2021_Rank_for_Global_Temperatures_Live_Shots_%28SVS14069_-_Gavin_Canned_Interview_pt_2%29.webm"
            ],
            "items": {
              "type": "string"
            }
          },
          "subtitleUrls": {
            "title": "Your SRT / VTT subtitle URLs (optional)",
            "type": "array",
            "description": "Burn existing subtitles instead of auto-transcribing (cheaper, no Whisper). Matched to `Video file URLs` **by position**: the 1st subtitle URL goes with the 1st video, and so on. Use `-` for a video that should be auto-transcribed. Leave empty to auto-caption every video.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "captionStyle": {
            "title": "Caption style preset",
            "enum": [
              "classic",
              "boxed",
              "social",
              "bold-yellow"
            ],
            "type": "string",
            "description": "`classic`: white bold text with a black outline at the bottom, up to 2 lines. `boxed`: white text on a semi-transparent black box (YouTube/Netflix look). `social`: TikTok/Reels/Shorts style, 3 big UPPERCASE words in the middle with the spoken word highlighted in yellow. `bold-yellow`: big yellow Anton font, uppercase, lower third. Every option below overrides the preset.",
            "default": "classic"
          },
          "fontName": {
            "title": "Font",
            "enum": [
              "Poppins",
              "Anton",
              "Bebas Neue",
              "Noto Sans",
              "DejaVu Sans",
              "Liberation Sans",
              "Noto Serif"
            ],
            "type": "string",
            "description": "Empty = preset font. Non-Latin scripts (Arabic, Cyrillic, Hindi, Chinese, Japanese, Korean…) automatically fall back to Noto fonts."
          },
          "fontSize": {
            "title": "Font size (px at 1080p)",
            "minimum": 10,
            "maximum": 300,
            "type": "integer",
            "description": "Text height in pixels for a 1080-pixel short side (1920×1080 or 1080×1920); scaled automatically for 720p/480p. Presets: classic 62, boxed 56, social 96, bold-yellow 80."
          },
          "position": {
            "title": "Position",
            "enum": [
              "bottom",
              "middle",
              "top"
            ],
            "type": "string",
            "description": "Where the captions sit. Empty = preset (bottom; middle for `social`)."
          },
          "marginPercent": {
            "title": "Distance from the edge (% of height)",
            "minimum": 0,
            "maximum": 45,
            "type": "integer",
            "description": "For bottom/top captions. Raise to ~18–25 for TikTok/Reels so captions stay above the app's buttons and description."
          },
          "maxWordsPerLine": {
            "title": "Max words per line",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Presets: classic/boxed 6, social 3, bold-yellow 4. Applies to auto captions and to your own SRT/VTT (long cues are split)."
          },
          "maxLines": {
            "title": "Max lines per caption",
            "minimum": 1,
            "maximum": 3,
            "type": "integer",
            "description": "1–3. Presets: classic/boxed/bold-yellow 2, social 1."
          },
          "uppercase": {
            "title": "UPPERCASE text",
            "type": "boolean",
            "description": "Social-media style capital letters. Empty = preset (on for `social` and `bold-yellow`)."
          },
          "bold": {
            "title": "Bold",
            "type": "boolean",
            "description": "Empty = preset."
          },
          "textColor": {
            "title": "Text colour",
            "type": "string",
            "description": "Hex like `#FFFFFF` or a name: white, yellow, red, green, blue, cyan, magenta, pink, orange, purple, lime, black."
          },
          "highlightColor": {
            "title": "Spoken-word highlight colour",
            "type": "string",
            "description": "Karaoke-style: the word being spoken is drawn in this colour (auto captions only; uses Whisper word timestamps). `#FFE600` in the `social` preset. Type `none` to turn it off."
          },
          "outlineColor": {
            "title": "Outline colour",
            "type": "string",
            "description": "Text border colour (hex or name)."
          },
          "outlineWidth": {
            "title": "Outline width (px at 1080p)",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "0 = no outline. Presets: classic 3.5, social 6, bold-yellow 5."
          },
          "backgroundBox": {
            "title": "Background box",
            "type": "boolean",
            "description": "Draw a box behind the text (on in `boxed`)."
          },
          "boxColor": {
            "title": "Box colour",
            "type": "string",
            "description": "Hex or name; default black."
          },
          "boxOpacity": {
            "title": "Box opacity (%)",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "0 = invisible, 100 = solid. Preset 65."
          },
          "model": {
            "title": "Whisper model (auto captions)",
            "enum": [
              "tiny",
              "base",
              "small"
            ],
            "type": "string",
            "description": "`base` (default): good for clear speech. `tiny`: fastest, clean English. `small`: most accurate for accents, noise and non-English; billed as `transcribed-minute-small`.",
            "default": "base"
          },
          "language": {
            "title": "Spoken language",
            "type": "string",
            "description": "`auto` detects the language. Or force a code to avoid mistakes on short or noisy clips: en, es, de, fr, pt, it, nl, pl, tr, ru, uk, ar, hi, ja, ko, zh, id, vi… (99 languages).",
            "default": "auto"
          },
          "task": {
            "title": "Subtitle language",
            "enum": [
              "transcribe",
              "translate"
            ],
            "type": "string",
            "description": "`transcribe`: subtitles in the spoken language. `translate`: English subtitles for a video in any language (same price).",
            "default": "transcribe"
          },
          "initialPrompt": {
            "title": "Vocabulary hint",
            "type": "string",
            "description": "Optional names and jargon to spell correctly, e.g. `Apify, Kubernetes, Dr. Nguyen`."
          },
          "maxResolution": {
            "title": "Max output resolution",
            "enum": [
              "1080",
              "720",
              "480"
            ],
            "type": "string",
            "description": "Short side of the output MP4 (1080 = 1920×1080 or 1080×1920 vertical). Larger videos (4K) are scaled down; smaller ones are never upscaled. Up to 720p is billed as `burned-minute`, above as `burned-minute-1080p`.",
            "default": "1080"
          },
          "videoQuality": {
            "title": "Video quality",
            "enum": [
              "high",
              "balanced",
              "small"
            ],
            "type": "string",
            "description": "H.264 quality of the re-encoded MP4 (subtitles are burned into the picture, so the video is always re-encoded). `balanced` looks like the source at a normal file size.",
            "default": "balanced"
          },
          "maxFps": {
            "title": "Max frame rate",
            "minimum": 10,
            "maximum": 60,
            "type": "integer",
            "description": "Videos above this frame rate (e.g. 60 fps) are converted to it.",
            "default": 30
          },
          "maxDurationMinutes": {
            "title": "Max duration per video (minutes)",
            "minimum": 1,
            "maximum": 180,
            "type": "integer",
            "description": "Longer videos are cut at this length (or skipped, see below). You pay only for the minutes in the output video.",
            "default": 30
          },
          "longVideoHandling": {
            "title": "Videos longer than max duration",
            "enum": [
              "truncate",
              "skip"
            ],
            "type": "string",
            "description": "`truncate`: subtitle the first N minutes (`truncated: true`). `skip`: free error row.",
            "default": "truncate"
          },
          "maxFileSizeMB": {
            "title": "Max file size (MB)",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Larger downloads are stopped (free error row).",
            "default": 2000
          },
          "downloadTimeoutSecs": {
            "title": "Download timeout (seconds)",
            "minimum": 30,
            "maximum": 3600,
            "type": "integer",
            "description": "Maximum time to download one video. Retried on network errors and HTTP 429/5xx.",
            "default": 900
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}