How to get a YouTube video's captions as SRT or VTT files with Python or curl, pick the right language track, fix overlapping cues, and handle the case where translation fails. Output shown is from real runs.
A tested Python recipe for summarising long YouTube videos with any LLM - fetch timestamped segments, chunk without cutting captions, map-reduce the notes, and turn every cited time into a link that opens the video at that moment.
Why the Python youtube-transcript-api library works on your laptop but raises RequestBlocked or IpBlocked on AWS, GCP and serverless, which fixes actually work, and a tested fallback that only calls a hosted API when YouTube blocks you.
A practical guide to fetching YouTube transcripts from code: why DIY scrapers get IP-blocked on servers, working Python, Node.js and curl examples, languages and translation, SRT/VTT, playlists, and chunking transcripts for LLMs.