{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Shorts Transcript Scraper - Bulk Shorts to Text",
    "description": "Transcribe YouTube Shorts to text, timestamped segments, SRT and VTT in bulk. Uses YouTube's own caption track when there is one and falls back to Whisper speech-to-text when there is not. No API key, no login, no cookies.",
    "version": "1.0",
    "x-build-id": "xyiKXZUg9zI6jE98Y"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/sauliusautomatesit~youtube-shorts-transcript-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-sauliusautomatesit-youtube-shorts-transcript-scraper",
        "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/sauliusautomatesit~youtube-shorts-transcript-scraper/runs": {
      "post": {
        "operationId": "runs-sync-sauliusautomatesit-youtube-shorts-transcript-scraper",
        "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/sauliusautomatesit~youtube-shorts-transcript-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-sauliusautomatesit-youtube-shorts-transcript-scraper",
        "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",
        "required": [
          "videoUrls"
        ],
        "properties": {
          "videoUrls": {
            "title": "YouTube Shorts URLs",
            "minItems": 1,
            "type": "array",
            "description": "YouTube Shorts URLs to transcribe — one per line, from a single link to thousands. `youtube.com/shorts/ID`, `youtu.be/ID` and `youtube.com/watch?v=ID` all work, so a Short you copied from the watch page needs no editing. Channel and playlist URLs are not single videos and will be reported as errors.",
            "items": {
              "type": "string"
            }
          },
          "language": {
            "title": "Transcript language",
            "type": "string",
            "description": "Two-letter language code (`en`, `es`, `pt`, `de`, `hi`…). Leave blank to keep the video's own language — the default, and what you want for a transcript. Setting it picks that language's caption track when the channel published one, and tells Whisper what to expect."
          },
          "allowWhisperFallback": {
            "title": "Transcribe with Whisper when a Short has no captions",
            "type": "boolean",
            "description": "On (default): Shorts without captions are transcribed with Whisper speech-to-text, charged at the higher `asr_transcript` rate. Off: those videos return a `CAPTIONS_UNAVAILABLE` error and cost you nothing — the cheapest way to run large batches, and a reasonable choice on YouTube, where most talking content is captioned already.",
            "default": true
          },
          "forceWhisper": {
            "title": "Always use Whisper, even when captions exist",
            "type": "boolean",
            "description": "Off (default): YouTube's caption track is used whenever there is one. On: every Short is transcribed with Whisper and charged at the `asr_transcript` rate — 20× the caption price. Worth it only when you have judged YouTube's auto-captions too poor for your use.",
            "default": false
          },
          "maxDurationSeconds": {
            "title": "Maximum video length (seconds)",
            "minimum": 5,
            "maximum": 1200,
            "type": "integer",
            "description": "Videos longer than this are skipped with a `DURATION_EXCEEDED` error and are not charged. A Short is at most 180 s, so the 600 s default only matters if you paste a regular YouTube video by mistake — which it will happily transcribe from captions.",
            "default": 600
          },
          "maxAsrDurationSeconds": {
            "title": "Maximum length for Whisper transcription (seconds)",
            "minimum": 5,
            "maximum": 1200,
            "type": "integer",
            "description": "Applies only to videos with no captions. Whisper costs roughly a second of CPU per 1.5 seconds of audio, so a per-video price only works up to a point; past this length a caption-less video returns `ASR_DURATION_EXCEEDED` and costs nothing. The default of 180 s is exactly the length of the longest Short. Videos **with** captions are never subject to this — they run to the full `maxDurationSeconds`.",
            "default": 180
          },
          "maxVideos": {
            "title": "Maximum videos per run",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Safety cap on how many URLs from the list are processed.",
            "default": 1000
          },
          "whisperModel": {
            "title": "Whisper model",
            "enum": [
              "tiny",
              "base",
              "small"
            ],
            "type": "string",
            "description": "Accuracy vs speed for the Whisper fallback only — videos with captions ignore this. `base` is the recommended balance.",
            "default": "base"
          },
          "beamSize": {
            "title": "Whisper beam size",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Decoding beam width for the Whisper fallback. 1 is fastest; higher is marginally more accurate and slower.",
            "default": 1
          },
          "concurrency": {
            "title": "Concurrency",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "How many videos to resolve at once. Whisper transcription is always serialised regardless of this setting, to keep the run inside its memory limit.",
            "default": 5
          },
          "includeFailedItems": {
            "title": "Include failed videos in the dataset",
            "type": "boolean",
            "description": "On (default): unavailable, private, age-restricted, too-long and non-YouTube URLs get a dataset row carrying an `error` code, so you can reconcile inputs to outputs. Failed rows are never charged.",
            "default": true
          },
          "useResidentialFallback": {
            "title": "Retry on a residential IP when YouTube refuses the request",
            "type": "boolean",
            "description": "On (default), and you should leave it on. YouTube answers datacenter addresses — including Apify Proxy's and the platform's own — with \"Sign in to confirm you're not a bot\", for videos that are perfectly public. This retries those requests through Apify's residential proxy, which is the route that works. With this off, most Shorts return `LOGIN_REQUIRED`. Only requests the cheap route already refused use residential traffic, and caption downloads stay on the cheap route.",
            "default": true
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Proxy used for the first attempt on every request. The run pins one proxy session, because YouTube binds a video's audio URL to the IP that fetched the player response.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}