{
  "openapi": "3.0.1",
  "info": {
    "title": "Auto Captions & Lyric Video Maker - TikTok Subtitles, Karaoke",
    "description": "Add animated captions to videos (TikTok-style word highlight, karaoke or classic subtitles burned in) and turn songs into lyric videos with lyrics synced to the singing. MP4 + SRT/VTT out. $0.06 per output minute (720p).",
    "version": "1.0",
    "x-build-id": "XO3lEinzIM7cafafx"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/kantolabs~auto-captions-lyric-video/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-kantolabs-auto-captions-lyric-video",
        "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/kantolabs~auto-captions-lyric-video/runs": {
      "post": {
        "operationId": "runs-sync-kantolabs-auto-captions-lyric-video",
        "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/kantolabs~auto-captions-lyric-video/run-sync": {
      "post": {
        "operationId": "run-sync-kantolabs-auto-captions-lyric-video",
        "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": {
          "mode": {
            "title": "What to make",
            "enum": [
              "captions",
              "lyricVideo"
            ],
            "type": "string",
            "description": "'captions' = burn animated captions into your video(s). 'lyricVideo' = turn a song (or any audio) into a video with the lyrics/words on an image or colour background.",
            "default": "captions"
          },
          "videoUrls": {
            "title": "Video URLs (captions mode)",
            "type": "array",
            "description": "Direct links to your video files (MP4, MOV, WEBM, MKV, AVI...), one per line. Your storage, S3/R2/GCS (public or pre-signed), CDNs, Dropbox and Google Drive share links work. Pages of YouTube, TikTok, Instagram and other platforms are refused (their terms forbid downloading).",
            "default": [
              "https://api.apify.com/v2/key-value-stores/aXcXwfChlioPWAUJv/records/sample-vertical-talk.mp4?signature=105QVevs72w3z5gMQzgIJ"
            ],
            "items": {
              "type": "string"
            }
          },
          "captionStyle": {
            "title": "Caption style",
            "enum": [
              "tiktok",
              "karaoke",
              "classic"
            ],
            "type": "string",
            "description": "'tiktok' = 1-6 big words at a time, the spoken word highlighted (Shorts/Reels/TikTok look). 'karaoke' = full subtitle line, words light up as they are spoken. 'classic' = plain two-line subtitles.",
            "default": "tiktok"
          },
          "subtitleUrls": {
            "title": "Your own SRT/VTT files (optional)",
            "type": "array",
            "description": "Optional. Links to SRT or VTT files, in the same order as the videos (leave empty to transcribe automatically). With your own file the text and timing are used as-is; word highlighting is then estimated within each subtitle line.",
            "items": {
              "type": "string"
            }
          },
          "subtitleText": {
            "title": "Or paste SRT/VTT text (optional, first video)",
            "type": "string",
            "description": "Optional. Paste the content of an SRT or VTT file to burn it into the first video instead of transcribing."
          },
          "audioUrl": {
            "title": "Song / audio URL (lyric video mode)",
            "type": "string",
            "description": "Direct link to the song or audio (MP3, WAV, M4A, AAC, OGG, OPUS, FLAC) - or a video, whose sound is used. One song per run."
          },
          "lyrics": {
            "title": "Lyrics (optional)",
            "type": "string",
            "description": "Paste the lyrics, one sung line per line, written out in full as sung (repeat the chorus each time it is sung). They are timed to the singing automatically. Lines like [Chorus] are ignored. Leave empty to transcribe the words from the audio."
          },
          "lyricStyle": {
            "title": "Lyric style",
            "enum": [
              "karaoke",
              "lines",
              "tiktok"
            ],
            "type": "string",
            "description": "'karaoke' = the current line fills with colour word by word, next line previewed underneath. 'lines' = line by line, no word fill. 'tiktok' = a few big words at a time with the sung word highlighted.",
            "default": "karaoke"
          },
          "songTitle": {
            "title": "Title card: song title (optional)",
            "type": "string",
            "description": "Shown at the start, before the first lyric (only if the intro is at least 2 seconds long)."
          },
          "artist": {
            "title": "Title card: artist (optional)",
            "type": "string",
            "description": "Shown under the title at the start."
          },
          "aspectRatio": {
            "title": "Aspect ratio",
            "enum": [
              "16:9",
              "9:16",
              "1:1",
              "4:5"
            ],
            "type": "string",
            "description": "Shape of the lyric video. 16:9 for YouTube, 9:16 for Shorts/Reels/TikTok, 1:1 or 4:5 for feeds. (Captions mode keeps your video's own shape.)",
            "default": "16:9"
          },
          "backgroundUrl": {
            "title": "Background image or video URL (optional)",
            "type": "string",
            "description": "Direct link to a JPG/PNG/WEBP image (or a short video, which is looped). It is cropped to fill the frame. Leave empty to use the colour/gradient below."
          },
          "backgroundColor": {
            "title": "Background colour",
            "pattern": "^#?[0-9a-fA-F]{6}$",
            "type": "string",
            "description": "Hex colour used when no background image is given, e.g. #1B1F3B.",
            "default": "#1B1F3B"
          },
          "backgroundColor2": {
            "title": "Gradient second colour (optional)",
            "pattern": "^(#?[0-9a-fA-F]{6})?$",
            "type": "string",
            "description": "Optional hex colour; with it the background is a diagonal gradient from the first colour to this one, e.g. #7B2FF7."
          },
          "backgroundZoom": {
            "title": "Slow zoom on the background",
            "type": "boolean",
            "description": "A slow push-in on the background over the whole song (Ken Burns). Turn off for a still background (renders faster, same price).",
            "default": true
          },
          "backgroundDim": {
            "title": "Darken background image (%)",
            "minimum": 0,
            "maximum": 85,
            "type": "integer",
            "description": "Darkens a background image so the words stay readable. 0 = original image.",
            "default": 35
          },
          "font": {
            "title": "Font",
            "enum": [
              "auto",
              "montserrat",
              "inter",
              "bebas-neue",
              "noto-sans"
            ],
            "type": "string",
            "description": "'auto' = Montserrat ExtraBold for TikTok/karaoke/lyrics, Inter for classic subtitles. Chinese, Japanese and Korean always use Noto Sans CJK; other scripts (Arabic, Hindi, Thai, Cyrillic...) fall back to Noto Sans automatically.",
            "default": "auto"
          },
          "fontSize": {
            "title": "Font size (%)",
            "minimum": 50,
            "maximum": 200,
            "type": "integer",
            "description": "100 = our tuned default for the style and frame size. 50-200.",
            "default": 100
          },
          "textColor": {
            "title": "Text colour",
            "pattern": "^#?[0-9a-fA-F]{6}$",
            "type": "string",
            "description": "Hex colour of the words, e.g. #FFFFFF.",
            "default": "#FFFFFF"
          },
          "highlightColor": {
            "title": "Highlight colour",
            "pattern": "^#?[0-9a-fA-F]{6}$",
            "type": "string",
            "description": "Hex colour of the word being spoken/sung (TikTok, karaoke and lyric styles), e.g. #FFD60A yellow, #39FF14 green.",
            "default": "#FFD60A"
          },
          "outlineColor": {
            "title": "Outline colour",
            "pattern": "^#?[0-9a-fA-F]{6}$",
            "type": "string",
            "description": "Hex colour of the outline and shadow around the letters, e.g. #000000.",
            "default": "#000000"
          },
          "position": {
            "title": "Position",
            "enum": [
              "auto",
              "bottom",
              "lower-third",
              "middle",
              "top"
            ],
            "type": "string",
            "description": "'auto' = lower third on vertical video (clear of the TikTok/Reels buttons), bottom on landscape, centre for lyric videos.",
            "default": "auto"
          },
          "uppercase": {
            "title": "UPPERCASE text",
            "type": "boolean",
            "description": "Show the words in capitals (the SRT/VTT files keep normal case).",
            "default": false
          },
          "wordsPerLine": {
            "title": "Words at a time (TikTok style)",
            "minimum": 1,
            "maximum": 6,
            "type": "integer",
            "description": "Maximum words shown together in the TikTok style. 1 = one word at a time.",
            "default": 3
          },
          "resolution": {
            "title": "Output resolution",
            "enum": [
              "720p",
              "1080p"
            ],
            "type": "string",
            "description": "720p (short side 720 px) is sharp on phones and cheapest. 1080p costs more per minute. Videos are never upscaled: a 720p source stays 720p and is charged as 720p.",
            "default": "720p"
          },
          "language": {
            "title": "Spoken / sung language",
            "pattern": "^(auto|[a-zA-Z]{2,3})$",
            "type": "string",
            "description": "'auto' detects it. Or a 2-letter ISO 639-1 code (en, es, de, fr, pt, it, ja, zh, ko, ar, hi...) - recommended for short clips and songs.",
            "default": "auto"
          },
          "wordTimestamps": {
            "title": "Include word timings in the results",
            "type": "boolean",
            "description": "Also return the start and end time of every word in the dataset item.",
            "default": false
          },
          "maxDurationMinutes": {
            "title": "Max duration per video (minutes)",
            "minimum": 1,
            "maximum": 120,
            "type": "integer",
            "description": "Longer inputs are skipped (free). Up to 120 minutes.",
            "default": 30
          },
          "maxFileSizeMb": {
            "title": "Max file size (MB)",
            "minimum": 1,
            "maximum": 4000,
            "type": "integer",
            "description": "Larger files are skipped (free).",
            "default": 2000
          },
          "downloadTimeoutSecs": {
            "title": "Download timeout (seconds)",
            "minimum": 10,
            "maximum": 3600,
            "type": "integer",
            "description": "Give up on a file that does not download within this time (free).",
            "default": 600
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}