{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Transcript Scraper: Channels, Playlists & Search",
    "description": "Get YouTube transcripts (captions and subtitles) as plain text, timestamped segments or SRT for videos, Shorts, whole channels, playlists and searches. Pick the language, fall back to auto-generated captions, and get title, channel, publish date, views and duration with each one.",
    "version": "0.1",
    "x-build-id": "aAwYw2gP563zLzL6a"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/wulfcare~youtube-transcript-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-wulfcare-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/wulfcare~youtube-transcript-scraper/runs": {
      "post": {
        "operationId": "runs-sync-wulfcare-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/wulfcare~youtube-transcript-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-wulfcare-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": {
          "urls": {
            "title": "Videos, channels or playlists",
            "type": "array",
            "description": "Any mix of video URLs (watch, youtu.be, Shorts, live, embed), 11-character video ids, channel URLs (@handle, /channel/UC..., /c/..., /user/...) and playlist URLs. Channels and playlists are expanded into their videos, newest first, up to the limit below.",
            "items": {
              "type": "string"
            }
          },
          "searchQueries": {
            "title": "YouTube searches",
            "type": "array",
            "description": "Optional. Transcripts of the videos YouTube lists for each search term (videos only, YouTube's relevance order).",
            "items": {
              "type": "string"
            }
          },
          "maxVideosPerSource": {
            "title": "Max videos per channel, playlist or search",
            "minimum": 0,
            "type": "integer",
            "description": "0 = all of them. Single video URLs are always fetched.",
            "default": 20
          },
          "channelTabs": {
            "title": "Channel tabs",
            "type": "array",
            "description": "Which of a channel's tabs to take videos from. Each tab counts as its own source for the limit above.",
            "items": {
              "type": "string",
              "enum": [
                "videos",
                "shorts",
                "streams"
              ],
              "enumTitles": [
                "Videos",
                "Shorts",
                "Live (past streams)"
              ]
            },
            "default": [
              "videos"
            ]
          },
          "languages": {
            "title": "Transcript language",
            "type": "array",
            "description": "Language codes in order of preference (en, es, pt-BR, ja...). \"en\" also matches en-US and en-GB. Captions uploaded by the creator are used before auto-generated ones in the same language. Leave empty to always get the video's original (spoken) language.",
            "default": [
              "en"
            ],
            "items": {
              "type": "string"
            }
          },
          "ifLanguageMissing": {
            "title": "If a video has none of these languages",
            "enum": [
              "original",
              "skip"
            ],
            "type": "string",
            "description": "Every row says which language it's in (language, isAutoGenerated) and lists all the video's caption languages (availableLanguages).",
            "default": "original"
          },
          "includeAutoGenerated": {
            "title": "Use auto-generated captions",
            "type": "boolean",
            "description": "Most videos only have YouTube's automatic (speech recognition) captions. Turn off to accept only captions made by a person.",
            "default": true
          },
          "includeSegments": {
            "title": "Timestamped segments",
            "type": "boolean",
            "description": "segments: [{start, duration, text}] in seconds, as shown on screen. The full transcript is always in text.",
            "default": true
          },
          "includeSrt": {
            "title": "SRT subtitles",
            "type": "boolean",
            "description": "Adds the transcript as an .srt subtitle file (srt field), ready for video editors and players.",
            "default": false
          },
          "includePublishDate": {
            "title": "Publish date and category",
            "type": "boolean",
            "description": "publishedAt and category, from one extra request per video. Off makes big runs about twice as fast: YouTube limits how many videos one IP address may ask for per minute.",
            "default": true
          },
          "includeDescription": {
            "title": "Video description",
            "type": "boolean",
            "description": "The full description text. Title, channel, duration, views, keywords and thumbnail are always included.",
            "default": true
          },
          "maxConcurrency": {
            "title": "Videos at a time",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Videos processed at once. YouTube lets each IP address fetch roughly 40-75 videos a minute, so a bigger proxy pool speeds up big runs more than this does.",
            "default": 5
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "YouTube refuses transcripts to IP addresses it distrusts, which includes many datacenter IPs. The run finds IPs YouTube accepts and keeps using them. If a run reports that every IP was refused, choose residential proxy.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}