{
  "openapi": "3.0.1",
  "info": {
    "title": "YouTube Video Details Scraper With Subtitles & Translations",
    "description": "YouTube Video Details Scraper With Subtitles & Translations extracts video details, subtitles, transcripts, translations, titles, descriptions, channels, views, likes, comments, timestamps, and metadata. Ideal for content research, SEO, competitor analysis, and multilingual insights.",
    "version": "0.1",
    "x-build-id": "kpqOIZQzxAPIH8NOS"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapio~youtube-video-details-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapio-youtube-video-details-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/scrapio~youtube-video-details-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapio-youtube-video-details-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/scrapio~youtube-video-details-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapio-youtube-video-details-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": [
          "startUrls"
        ],
        "properties": {
          "startUrls": {
            "title": "🎬 YouTube Video URLs or IDs",
            "type": "array",
            "description": "One entry per video. Accepts `https://www.youtube.com/watch?v=ID`, `https://youtu.be/ID`, `/shorts/ID`, `/live/ID`, `/embed/ID` and bare 11-character video IDs.\n\nPlaylist and channel URLs are **rejected with a reason** instead of silently producing a malformed row.\n\nExample: `dQw4w9WgXcQ` and `https://youtu.be/jNQXAC9IVRw`.",
            "items": {
              "type": "string"
            }
          },
          "subtitlesLanguage": {
            "title": "🌐 Subtitle Language",
            "type": "string",
            "description": "ISO code of the caption track you want, e.g. `en`, `en-US`, `es`, `de`, `pt-BR`, `hi`, `ja`. Matching is exact first, then case-insensitive, then base-language (`en` also matches `en-US`).\n\nLeave empty to use the video's own language, then English, then the first track available.\n\nExample: `es` → the Spanish track when the video has one.",
            "default": ""
          },
          "captionSource": {
            "title": "🎙️ Human vs Auto-Generated Captions",
            "enum": [
              "human_first",
              "auto_first",
              "human_only",
              "auto_only"
            ],
            "type": "string",
            "description": "Which caption pool to read from. `human_first` (default) prefers creator-uploaded subtitles and falls back to YouTube's speech recognition. `auto_first` inverts that. The `_only` options never fall back and instead return a reason.\n\nExample: `auto_only` on a video whose only track is a creator upload → `transcript: null`, `noTranscriptReason: no_auto_captions_available`.",
            "default": "human_first"
          },
          "subtitlesFormat": {
            "title": "📦 Subtitle Output Format",
            "enum": [
              "timestamped",
              "plaintext",
              "srt",
              "vtt"
            ],
            "type": "string",
            "description": "`timestamped` and `plaintext` are always produced (`transcript` and `transcriptText`). Choosing `srt` or `vtt` additionally downloads that exact format **natively from YouTube** into `transcriptSrt` / `transcriptVtt` — nothing is transcoded here.\n\nExample: `srt` → a ready-to-use `.srt` body you can save straight to disk.",
            "default": "timestamped"
          },
          "translateTranscriptTo": {
            "title": "🌍 Auto-Translate Transcript To",
            "type": "string",
            "description": "ISO code for a **second** transcript translated by YouTube's own `tlang` parameter — no third-party translation service and no API key. The original-language transcript is still returned alongside it.\n\nExample: `es` → `translatedTranscript` and `translatedTranscriptText` in Spanish, with `translatedToLanguage: \"es\"`.\n\nLeave empty to skip translation. If translation is impossible you get `noTranslationReason` instead of a silent blank.",
            "default": ""
          },
          "allowLanguageFallback": {
            "title": "↩️ Fall Back To Another Language",
            "type": "boolean",
            "description": "When the requested **Subtitle Language** does not exist on a video: `true` (default) picks the best available track instead; `false` returns `transcript: null` with `noTranscriptReason: language_not_available`.\n\nSet this to `false` when you only want rows in one specific language.",
            "default": true
          },
          "skipVideosWithoutTranscript": {
            "title": "🚫 Skip Videos With No Captions",
            "type": "boolean",
            "description": "`true` drops videos that have no usable caption track entirely — no dataset row, no charge. `false` (default) still returns the full metadata row with `hasTranscript: false` and a `noTranscriptReason`.",
            "default": false
          },
          "includeChannelLogo": {
            "title": "🖼️ Fetch Channel Avatar",
            "type": "boolean",
            "description": "Fills `channel.logo` by loading the channel's About page (~1.9 MB). Results are cached per channel within a run, so ten videos from one channel cost one request, not ten. Turn this off for the fastest possible runs.",
            "default": true
          },
          "proxyConfiguration": {
            "title": "🔗 Proxy",
            "type": "object",
            "description": "YouTube bot-walls datacenter and container-native IPs hard on repeated video extractions — measured 1 of 8 videos on datacenter versus 7 of 8 on residential. The default below is therefore **Apify RESIDENTIAL**, which costs more per GB but is the only route with a workable success rate.\n\nIf a request is bot-walled the Actor escalates the route (direct → datacenter → residential) and rotates the session rather than just sleeping.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}