---
search:
  tags:
    - Research
    - POST
seo:
  description: >-
    Extract a text transcript from a YouTube video URL. The server talks to
    YouTube's… Reference for the POST /v1/youtube/transcript endpoint in the
    Webfold API.
sidebar:
  label: Fetch a YouTube transcript
  badge: POST
title: Fetch a YouTube transcript
type: openapi-operation
---
Extract a text transcript from a YouTube video URL. The server talks to
YouTube's InnerTube API internally.

`POST /v1/youtube/transcript`

**Request body** (`application/json`, required)

- `url` (string<uri>, required) — YouTube video URL
- `language` (string) — Preferred language code or \`auto\`

Request body example:

```json
{
  "url": "https://youtu.be/dQw4w9WgXcQ",
  "language": "en"
}
```

**Responses**

- `200` — Transcript text and detected language
- `400` — Bad request
- `401` — Missing or invalid bearer token
- `403` — Billing or plan entitlement blocked the request
- `502` — Upstream service (arXiv, YouTube, web page) failed

Response example, 200:

```json
{
  "text": "string",
  "language": "en"
}
```
