{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Transcript Scraper",
    "description": "YouTube transcript scraper for videos, Shorts, playlists and channels. Get captions with timestamps, full text, SRT or VTT, in your language with auto-generated fallback, plus title, channel, date and views. No API key. Videos without captions are not charged.",
    "version": "1.0",
    "x-build-id": "XOwZ3IP8N80KFvuTi"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/groupoject~youtube-transcript-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-groupoject-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/groupoject~youtube-transcript-scraper/runs": {
      "post": {
        "operationId": "runs-sync-groupoject-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/groupoject~youtube-transcript-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-groupoject-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",
        "required": [
          "urls"
        ],
        "properties": {
          "urls": {
            "title": "YouTube URLs or video IDs",
            "type": "array",
            "description": "One entry per line. Accepts watch URLs, youtu.be links, Shorts, /live/ and /embed/ URLs, bare 11-character video IDs, playlist URLs (youtube.com/playlist?list=…), and channel URLs or handles (@handle, /channel/UC…, /c/…, /user/…). Playlists and channels are expanded up to \"Max videos per playlist or channel\".",
            "items": {
              "type": "string"
            }
          },
          "languages": {
            "title": "Preferred languages",
            "type": "array",
            "description": "Caption languages to look for, in order of preference (ISO codes such as en, es, de, pt-BR). The first one the video offers is used. \"en\" also matches regional variants such as en-GB.",
            "default": [
              "en"
            ],
            "items": {
              "type": "string"
            }
          },
          "captionType": {
            "title": "Caption type",
            "enum": [
              "any",
              "manual",
              "auto"
            ],
            "type": "string",
            "description": "Which captions to accept. \"Prefer manual\" uses creator-uploaded subtitles when they exist and falls back to YouTube's auto-generated captions.",
            "default": "any"
          },
          "fallbackToAnyLanguage": {
            "title": "Fall back to any available language",
            "type": "boolean",
            "description": "If none of the preferred languages exist, return the video's original-language captions instead of skipping the video. Turn off to get only the languages you listed.",
            "default": true
          },
          "translateTo": {
            "title": "Translate to (optional)",
            "type": "string",
            "description": "ISO code (e.g. es, fr, de) to request YouTube's built-in auto-translation of the chosen captions. YouTube frequently rate-limits translated captions; when that happens the row keeps the original-language transcript and explains why in translationError. Leave empty for no translation."
          },
          "outputFormats": {
            "title": "Output formats",
            "type": "array",
            "description": "What to include in each row: timestamped segments (start, duration, text), plain full text, an SRT subtitle string and/or a WebVTT subtitle string.",
            "items": {
              "type": "string",
              "enum": [
                "segments",
                "text",
                "srt",
                "vtt"
              ],
              "enumTitles": [
                "Timestamped segments (JSON array)",
                "Plain text",
                "SRT subtitles",
                "WebVTT subtitles"
              ]
            },
            "default": [
              "segments",
              "text"
            ]
          },
          "includeVideoMetadata": {
            "title": "Include video metadata",
            "type": "boolean",
            "description": "Add channel name and ID, publish date, category, view and like counts, duration, description, tags and thumbnail to each row.",
            "default": true
          },
          "maxVideosPerSource": {
            "title": "Max videos per playlist or channel",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Cap for each playlist URL, and for each selected content type of each channel (newest first). Single video URLs are not affected.",
            "default": 20
          },
          "channelContentTypes": {
            "title": "Channel content",
            "type": "array",
            "description": "Which channel uploads to take when you paste a channel URL: long-form videos, Shorts and/or past live streams.",
            "items": {
              "type": "string",
              "enum": [
                "videos",
                "shorts",
                "streams"
              ],
              "enumTitles": [
                "Videos",
                "Shorts",
                "Live streams"
              ]
            },
            "default": [
              "videos"
            ]
          },
          "onlyNewVideos": {
            "title": "Only new videos (monitoring)",
            "type": "boolean",
            "description": "For channel and playlist URLs, skip videos already processed in earlier runs with the same state key, so a scheduled run returns only transcripts of newly published videos. A video counts as processed once its transcript row is saved, or once YouTube confirms it has no captions (freshly uploaded videos are re-checked for auto-captions for 24 hours). Single video URLs are always fetched.",
            "default": false
          },
          "stateKey": {
            "title": "State key",
            "type": "string",
            "description": "Name of the monitor. Runs with the same key share the list of already-processed videos (stored in your named key-value store youtube-transcript-monitor-<key>). Use a different key for each separate monitor. Letters, digits and hyphens; other characters are replaced.",
            "default": "default"
          },
          "publishedAfter": {
            "title": "Published after (optional)",
            "type": "string",
            "description": "Only save channel and playlist videos published after this point: a date (2026-01-31), an ISO date-time, or a rolling window such as \"7 days\" or \"48 hours\". Leave empty for no date filter. Single video URLs are not filtered."
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many videos to fetch in parallel.",
            "default": 10
          },
          "residentialFallback": {
            "title": "Residential proxy fallback",
            "type": "boolean",
            "description": "YouTube often answers datacenter IPs with a bot check. When that happens, retry the video through Apify residential proxy automatically. Recommended.",
            "default": true
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Primary proxy. The default (Apify datacenter proxy) is tried first; residential is used as a fallback when enabled above.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}