Products/YouTube/YouTube Transcript/Use case

YouTube Transcript Use case

YouTube Transcript API for RAG pipelines

LlamaIndex's YoutubeTranscriptReader and LangChain's YoutubeLoader both wrap the youtube_transcript_api library, and that library is blocked on most cloud server IPs. This API returns the same kind of data, timed segments plus a joined text field, over HTTP, with residential proxy handling built in, so a RAG ingestion job running on a cloud server does not have to solve the IP block itself.

  • youtube_transcript_api, the library LlamaIndex and LangChain wrap, is blocked on most cloud IPs: GitHub issue #303 alone has 187 comments, and the research reviewed found 87 issues matching blocked, RequestBlocked or IpBlocked, 40 of them opened in 2026.
  • JSON output carries timed segments, a joined text field and a wordCount, ready to chunk for embeddings.
  • One call can take a single video, a batch of up to 25 videos over POST, or a channel URL with maxVideos, or a playlist URL, on the Apify actor.
  • preferManual (default true) prefers the creator's own captions over an auto-generated track when both exist, and isAutoGenerated on each item says which one you got, which matters for RAG answers that need to cite the source track.
  • listLanguages true adds availableLanguages to an item, so a multilingual knowledge base can decide which language track to ingest instead of guessing.

2 USD / 1,000 transcripts, pay as you go. Videos without captions return a free NO_TRANSCRIPT row, never billed.

Example

Example
curl "https://api.vakitek.co.uk/v1/youtube/transcript?video=dQw4w9WgXcQ&format=json" \
  -H "X-API-Key: $VAKITEK_API_KEY"

Questions

Does this replace youtube_transcript_api in my RAG pipeline?

It replaces the network call, not your chunking or embedding code. You still get timed segments and plain text; the difference is that the request runs through a residential proxy path instead of your server's own IP.

What happens when a video has no captions?

You get a NO_TRANSCRIPT row and nothing is charged for it, so a bulk ingestion job can skip it and move on.

Can I pull a whole channel for a knowledge base?

Yes, on the Apify actor: put the channel URL in urls and set maxVideos. The API endpoint batches up to 25 videos per POST call; a whole channel or playlist in one call needs the actor.

Does the response tell me which language or caption track I got?

Yes. Every item carries language and isAutoGenerated, and setting listLanguages true adds the full list of tracks the video offers, useful when a RAG pipeline needs to record provenance alongside the embedded text.