---
title: "YouTube Transcript API: Any Video, No Key · SocialToAI"
canonical: https://socialtoai.com/youtube-transcript-api/
updated: 2026-10-30
---

# YouTube transcript API

Get the full transcript of any public YouTube video by its link or ID: the language, the whole text, and every segment with its start and end time. It is YouTube's detail call with `include=transcript`, 2 credits a video (≈ $0.004–$0.0067); failed calls are free. Call it over HTTP or let your AI call it over MCP.

- Page: https://socialtoai.com/youtube-transcript-api/
- Last updated: 2026-10-30

## What you get

One object per video. The video is given by link to the video: a watch, shorts, embed, live or youtu.be link, or by its ID.

| Field | Type | Meaning |
| --- | --- | --- |
| `fields.lang` | string | The language of the transcript. |
| `fields.text` | string | The full text. |
| `fields.segments` | array | Timed segments: start, end and text. |

## The request

**cURL**

```
curl https://api.socialtoai.com/v1/detail \
  -H "Authorization: Bearer $SOCIALTOAI_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "platform": "youtube",
    "id": "dQw4w9WgXcQ",
    "include": "transcript"
  }'
```

**Python**

```
import os
import uuid
import requests

response = requests.post(
    "https://api.socialtoai.com/v1/detail",
    headers={
        "Authorization": f"Bearer {os.environ['SOCIALTOAI_API_KEY']}",
        # A new key for each request; the same one again retries it without paying twice.
        "Idempotency-Key": str(uuid.uuid4()),
    },
    json={
        "platform": "youtube",
        "id": "dQw4w9WgXcQ",
        "include": "transcript",
    },
)
print(response.json())
```

**A recorded answer (names and text removed)**

```
{
  "request_id": "req_00000000-0000-4000-8000-000000000001",
  "schema_version": "v1",
  "fetched_at": "2026-10-12T03:34:28.000Z",
  "action": "detail",
  "platform": "youtube",
  "status": "ok",
  "items": [
    {
      "platform": "youtube",
      "id": "…",
      "ref": "…",
      "approx": [],
      "type": "entry",
      "entry_type": "transcript",
      "title": null,
      "url": null,
      "rank": null,
      "heat": null,
      "fields": {
        "lang": "en",
        "text": "…",
        "segments": [
          {
            "start": 0.4,
            "end": 4.24,
            "text": "…"
          },
          {
            "start": 2.08,
            "end": 6.56,
            "text": "…"
          }
        ]
      }
    }
  ],
  "unavailable": [],
  "warnings": [],
  "applied_params": {
    "id": "dQw4w9WgXcQ",
    "include": "transcript"
  },
  "cost_credits": 2,
  "billing": {
    "cost_credits": 2,
    "balance_credits": 98,
    "today_spend_credits": 2,
    "daily_limit_credits": null,
    "daily_remaining_credits": null,
    "display": "This call: 2 credits (≈ $0.0067). Balance: 98 credits (≈ $0.33)."
  },
  "replayed": false
}
```

## What YouTube's own API gives

YouTube's Data API downloads caption tracks only for videos the signed-in user may edit, at a quota cost per call; it does not give the transcript of any public video.

| Official API | Who can use it | Cost | Limits | Source |
| --- | --- | --- | --- | --- |
| YouTube Data API v3 | Any developer with a Google Cloud project and an API key. | Free within the quota: by default 100 search.list calls and 10,000 units a day for the other endpoints. | A read of a list usually costs 1 unit; more quota is requested through Google's quota extension form. | [developers.google.com](https://developers.google.com/youtube/v3/getting-started), checked 2026-10-29 |
| Captions download | A signed-in user with permission to edit the video. | 200 quota units a call. | Downloads caption tracks only of videos the user can edit, so not of any public video. | [developers.google.com](https://developers.google.com/youtube/v3/docs/captions/download), checked 2026-10-29 |

## In your AI client

Connect SocialToAI once over [MCP](https://socialtoai.com/mcp.md), then ask in plain words. Your AI makes the call and reads the transcript.

| Ask | Credits |
| --- | --- |
| Read this YouTube video: dQw4w9WgXcQ | 2 |

## What it costs

2 credits a video: $0.0067 at the first pack, so a thousand videos are $6.67. A failed call costs nothing; estimate a batch with the [cost estimator](https://socialtoai.com/free-tools/api-cost-estimator.md). 100 free credits on sign-up, no card.

## FAQ

### Can I get the transcript of any public YouTube video?

Yes, by its link or ID, 2 credits a video (≈ $0.004–$0.0067). A call that fails costs nothing.

### Does the official YouTube API give transcripts?

Only of videos you may edit: captions download requires permission to edit the video and costs 200 quota units a call.

### Do I need a Google Cloud project or a YouTube account?

No. You need one SocialToAI key, or sign-in from your AI client.

### Can Claude or ChatGPT fetch YouTube transcripts?

Yes, once SocialToAI is connected over MCP: give it the link and ask for the transcript or a summary.

- [YouTube detail API](https://socialtoai.com/youtube-detail-api.md): The whole call, every parameter and field.
- [YouTube API](https://socialtoai.com/platforms/youtube.md): Every call on YouTube and its credits.
- [How do I find out how a product is talked about on YouTube with AI?](https://socialtoai.com/docs/guides/track-brand-mentions-on-youtube.md): A recorded run on YouTube.
- [YouTube MCP server](https://socialtoai.com/mcp/youtube.md): Let your AI read YouTube.
