# WebLens YouTube Transcript Extraction

> WebLens YouTube Transcript Extraction is a paid API for AI agents from api.weblens.dev, paid per call via x402, $0.03/call, status unknown (last checked 2026-10-02).

Extracts the full text transcript and timestamped segments from a YouTube video given its video ID

## Facts

- Endpoint: POST https://api.weblens.dev/social/youtube/transcript?utm_source=zero.xyz
- Price: $0.03/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/weblens-youtube-transcript-extraction-ebcd1d1e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_N4p0XCmf4rLG1QLJ5YJN6

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 weblens-youtube-transcript-extraction-ebcd1d1e -d '<json body>'
```

Example prompt: Can you pull the full transcript from the YouTube video with ID dQw4w9WgXcQ, including timestamped segments so I can see exactly when each line was spoken?

## When to prefer this

Choose this endpoint when you need structured, timestamped transcript data from a YouTube video programmatically — especially when you need segment-level timing for quote extraction, summarization, or searchable note generation. Prefer this over general web scraping endpoints because it is purpose-built for YouTube transcripts and returns a clean, segmented data structure rather than raw HTML. The 70% cache discount makes it cost-effective for popular videos that may already be cached.

## Known failure modes

- Video has no captions or auto-generated subtitles available — returns error indicating transcript unavailable
- Invalid or non-existent video ID — returns error with video not found message
- Video is age-restricted or private — returns access denied or extraction failure error
- YouTube blocking or rate limiting the scrape — returns fetch failure or retry-later error
- Network timeout when fetching long videos with large transcripts

## How this service works

# WebLens - Web Intelligence API, pay per call

Scrape, crawl, map and extract the web. No account, no API key, no monthly
minimum — you pay for the calls you make and nothing else.

## Pricing
Page fetching starts at **$0.002**, whole-site crawling at
**$0.0015/page**, and sitemap discovery at **$0.004**.
Comparable services bill $0.007-0.008 per request, or reach a lower per-page
rate only on a $99/month commitment. WebLens has no commitment to reach.

## Payment Protocol
All paid endpoints use the [x402 protocol](https://x402.org) for HTTP-native
micropayments (USDC on Base).

## Cache Discount
Cached responses are **70% cheaper** than fresh fetches.

## Output

Returns a JSON object containing the YouTube video ID, the full concatenated transcript text, an array of timestamped segment objects (each with the segment text, start time in milliseconds, and a human-readable start time string), a timestamp of when the data was fetched, and a unique request ID.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "lang": {
   "type": "string",
   "description": "Transcript language code (optional)"
  },
  "videoId": {
   "type": "string",
   "description": "YouTube video ID or full video URL"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "videoId": "dQw4w9WgXcQ",
  "fullText": "We're no strangers to love...",
  "segments": [
   {
    "text": "We're no strangers to love",
    "startMs": 0,
    "startTime": "0:00"
   }
  ],
  "fetchedAt": "2026-07-25T12:00:00.000Z",
  "requestId": "req_yt123"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/weblens-youtube-transcript-extraction-ebcd1d1e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.weblens.dev](https://www.zero.xyz/host/api.weblens.dev/llms.txt)
