{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Transcript Scraper: Channels, Playlists & Shorts",
    "description": "Timestamped transcripts and video metadata from YouTube videos, Shorts, whole channels, playlists and searches. Any caption language, SRT/VTT, publish dates. No login or browser; monitor channels for new uploads with only-new runs.",
    "version": "0.1",
    "x-build-id": "eCk3Nq95kOHtp3vg3"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/nextgensda~youtube-transcript-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-nextgensda-youtube-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/nextgensda~youtube-transcript-scraper/runs": {
      "post": {
        "operationId": "runs-sync-nextgensda-youtube-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/nextgensda~youtube-transcript-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-nextgensda-youtube-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",
        "properties": {
          "startUrls": {
            "title": "YouTube URLs",
            "type": "array",
            "description": "Any YouTube URL: a video (<code>watch?v=</code>, <code>youtu.be/</code>, <code>/shorts/</code>, <code>/live/</code>), a channel (<code>/@handle</code>, optionally <code>/videos</code>, <code>/shorts</code> or <code>/streams</code>), a playlist (<code>/playlist?list=</code>) or a search results page (<code>/results?search_query=</code>). Bare video ids work too.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "channels": {
            "title": "Channels",
            "type": "array",
            "description": "Channel handles (<code>@GoogleDevelopers</code>), channel URLs or <code>UC…</code> ids. Their newest videos come first.",
            "items": {
              "type": "string"
            }
          },
          "searches": {
            "title": "Search keywords",
            "type": "array",
            "description": "Search YouTube for each keyword (videos only, in YouTube's relevance order).",
            "items": {
              "type": "string"
            }
          },
          "channelTab": {
            "title": "Channel tab",
            "enum": [
              "videos",
              "shorts",
              "streams",
              "all"
            ],
            "type": "string",
            "description": "Which videos of a channel to read, unless its URL names a tab.",
            "default": "videos"
          },
          "maxVideosPerSource": {
            "title": "Max videos per channel, playlist or search",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "How many videos to read from each channel tab, playlist or search.",
            "default": 50
          },
          "maxItems": {
            "title": "Max videos in total",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "The run stops after this many video rows.",
            "default": 1000
          },
          "transcripts": {
            "title": "Fetch transcripts",
            "type": "boolean",
            "description": "Off: video metadata only (title, channel, views, duration, description, caption languages), at the lower per-video price.",
            "default": true
          },
          "language": {
            "title": "Transcript language",
            "type": "string",
            "description": "A language code like <code>en</code>, <code>de</code>, <code>es</code> or <code>pt-BR</code>. A regional code also matches its base language (<code>en-GB</code> takes <code>en</code>). Empty: the video's spoken language.",
            "default": "en"
          },
          "fallbackToOriginalLanguage": {
            "title": "Fall back to the spoken language",
            "type": "boolean",
            "description": "When a video has no captions in your language, return its spoken-language transcript (the row says which language it is). Off: such videos come without a transcript.",
            "default": true
          },
          "preferManualCaptions": {
            "title": "Prefer creator captions",
            "type": "boolean",
            "description": "Take the creator's own captions over YouTube's auto-generated ones when both exist in the language.",
            "default": true
          },
          "includeSegments": {
            "title": "Timestamped segments",
            "type": "boolean",
            "description": "The transcript as a list of <code>{start, end, text}</code> (seconds).",
            "default": true
          },
          "outputFormats": {
            "title": "Also include as",
            "type": "array",
            "description": "Extra fields with the whole transcript: plain text (<code>transcriptText</code>), <code>srt</code>, <code>vtt</code>.",
            "items": {
              "type": "string",
              "enum": [
                "text",
                "srt",
                "vtt"
              ],
              "enumTitles": [
                "Plain text",
                "SRT subtitles",
                "WebVTT subtitles"
              ]
            },
            "default": [
              "text"
            ]
          },
          "includePublishDate": {
            "title": "Exact publish date",
            "type": "boolean",
            "description": "The video's publish date and time (one small extra request per video).",
            "default": true
          },
          "skipVideosWithoutTranscript": {
            "title": "Skip videos without captions",
            "type": "boolean",
            "description": "Leave out videos that have no captions at all (about 1 in 8). They aren't charged.",
            "default": false
          },
          "onlyNew": {
            "title": "Only new videos (monitoring)",
            "type": "boolean",
            "description": "Skip videos this monitor delivered in earlier runs (remembered a year). Skipped videos aren't charged, and a channel stops being read at the first run of videos it already has. Schedule it to get every new upload of a channel.",
            "default": false
          },
          "monitorName": {
            "title": "Monitor name",
            "type": "string",
            "description": "Keep separate monitors apart (e.g. one per client). Letters, digits and dashes.",
            "default": "default"
          },
          "concurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 16,
            "type": "integer",
            "description": "Videos read at once, each through its own proxy IP.",
            "default": 4
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Apify's datacenter proxies work and cost least: YouTube refuses some of their IPs, and the actor moves to a new one each time. If too many in a row are refused, the run switches to US residential by itself.",
            "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
                  },
                  "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}