YouTube API

YouTube Video transcript API

Caption transcript for a video or Short by URL or id, with start/end timestamps per segment.

POST/v1/run/youtube.video_transcript
Uptime
100.00%
30d · 327 calls
Requests
327
30d · weekly, last 12 wks
Response
8.5s
median · 30d

Try it

Make your first request

Open in
Get a free key
Sample response
Free runs return only the first 3 results. Fund a key to get the full response.
{
  "found": true,
  "data": {
    "id": "dQw4w9WgXcQ",
    "language": "en",
    "segments": [
      {
        "start": 18.2,
        "end": 21,
        "text": "Never gonna give you up"
      },
      {
        "start": 21,
        "end": 24.4,
        "text": "Never gonna let you down"
      }
    ]
  }
}
Response interface
interface YoutubeVideoTranscriptResponse {
  data: {
    language: string;
    segments?: {
      durationSeconds: number;
      startSeconds: number;
      text: string;
    }[];
    transcript: string;
  } | null;
  found: boolean;
}

Full parameter and response reference - every field, type, and example for this endpoint.

Reference

Request, response, and price

Last verified 2026-09-14 · uptime and latency measured over 30d
POST /v1/run/youtube.video_transcript
curl -X POST https://api.getanyapi.com/v1/run/youtube.video_transcript \
  -H "Authorization: Bearer $ANYAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://www.youtube.com/watch?v=dQw4w9WgXcQ"}'
FieldTypeExample value
Request body
idstringYouTube video ID. A Short uses the same ID as any other video.
urlstring"https://www.youtube.com/watch?v=dQw4w9WgXcQ"Full YouTube video URL. Shorts (youtube.com/shorts/...), youtu.be, live, and embed URLs all work.
Response
foundbooleantrue
dataobject
data.idstring"dQw4w9WgXcQ"
data.languagestring"en"
data.segmentsarray
data.segments[].startnumber18.2
data.segments[].endnumber21
data.segments[].textstring"Never gonna give you up"
Price
Price per requestUSD$0.00125
Price /1k reqUSD$1.25

FAQ

About the YouTube Video transcript API

The AnyAPI YouTube Video transcript API returns YouTube video transcript data as normalized JSON from one POST call to /v1/run/youtube.video_transcript. Caption transcript for a video or Short by URL or id, with start/end timestamps per segment. AnyAPI routes each request across 2 sources and falls back automatically when one fails. It costs from $1.25 per 1,000 requests, in US dollars with no subscription and no monthly minimum. Over the last 30 days, 100.0% of YouTube video transcript calls through AnyAPI succeeded, with a median response time of 8.5 seconds across 327 measured calls.

It costs from $1.25 per 1,000 requests, in US dollars with no subscription and no monthly minimum. You fund one USD wallet, each call draws it down, and a failed request costs $0.

Caption transcript for a video or Short by URL or id, with start/end timestamps per segment. The response is normalized JSON with the same envelope every AnyAPI endpoint returns, so parsing a second endpoint is a change of URL and nothing else.

Over the last 30 days, 100.0% of YouTube video transcript calls through AnyAPI succeeded, with a median response time of 8.5 seconds across 327 measured calls. These are AnyAPI's own measurements of traffic through the gateway, recomputed continuously, not a published service-level target.