# glim.sh YouTube Transcript Fetcher

> glim.sh YouTube Transcript Fetcher is a paid API for AI agents from glim.sh, paid per call via x402, $0.01/call, live (last probed 2026-10-12, last successful call 2026-09-27).

Agents call it through Zero, which pays per call: no API key and no wallet of your own. New accounts start with $5.

Fetches a YouTube video's transcript/caption file (VTT format) by video ID, with optional language and caption origin filter

## Facts

- Endpoint: POST https://glim.sh/api/v1/youtube/get?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: healthy
- Last checked: 2026-10-12
- Last successful call: 2026-09-27
- Success rate: 99% of calls made through Zero
- Rating: 4.8 / 5 from 4 reviews
- Activations on Zero: 72
- Tags: x402
- Canonical page: https://www.zero.xyz/c/glim-sh-youtube-transcript-fetcher-9ec94154
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_SAs6yg2g9u88AfW676-NX

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability glim-sh-youtube-transcript-fetcher-9ec94154 -d '<json body>'
```

Example prompt: Can you grab the uploader-provided English transcript for the YouTube video dQw4w9WgXcQ? I need the caption text so I can summarize it.

## When to prefer this

Use this endpoint when you need to retrieve the transcript or subtitle text of a YouTube video without managing YouTube Data API keys or scraping infrastructure. Ideal for summarization, translation, search indexing, or accessibility workflows. Prefer this over DIY scraping stacks when you want a pay-per-call, no-setup solution.

## Known failure modes

- Video ID not found or invalid (11-char format required)
- Transcript not available in the requested language
- No captions exist for the video (private, live, or captionless videos)
- Requested origin type (uploader_provided vs auto_generated) not available
- Presigned download URL expires — must re-call to get a fresh URL
- Payment failure via x402 protocol

## How this service works

Fetch a YouTube transcript from a video URL or 11-char id (video_id, also accepted as ref or url); returns a presigned download URL to the transcript

## Output

A JSON object containing a presigned download URL for the VTT caption file, the video ID, language code, caption origin (uploader_provided or auto_generated), transcript character count, file size in bytes, content type (text/vtt), and an expiry timestamp for the download URL.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "format": {
   "enum": [
    "inline",
    "url"
   ],
   "type": "string",
   "default": "inline",
   "description": "'inline' (default): include the transcript in the response when it fits the inline cap; otherwise omit it and set transcript_omitted_reason. 'url': never include the transcript; caller fetches download_url. download_url is always present."
  },
  "origin": {
   "enum": [
    "uploader_provided",
    "auto_generated"
   ],
   "type": "string",
   "default": "uploader_provided",
   "description": "'uploader_provided' for human captions (default), 'auto_generated' for YouTube auto-captions."
  },
  "video_id": {
   "type": "string",
   "minLength": 1,
   "description": "YouTube video URL or 11-char video id (e.g. https://youtu.be/dQw4w9WgXcQ, https://www.youtube.com/watch?v=dQw4w9WgXcQ, or dQw4w9WgXcQ). Also accepted as `ref` or `url`."
  },
  "language_code": {
   "type": "string",
   "default": "en",
   "maxLength": 10,
   "minLength": 2,
   "description": "ISO 639-1 language code (e.g. 'en', 'de', 'fr')"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "origin": "uploader_provided",
  "video_id": "dQw4w9WgXcQ",
  "expires_at": "2026-04-21T13:00:00Z",
  "size_bytes": 4096,
  "content_type": "text/vtt",
  "download_url": "https://...presigned...",
  "length_chars": 3500,
  "language_code": "en"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/glim-sh-youtube-transcript-fetcher-9ec94154/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from glim.sh](https://www.zero.xyz/host/glim.sh/llms.txt)
