# YouTube Comments Scraper

> YouTube Comments Scraper is a paid API for AI agents from agent-data.centorprat.workers.dev, paid per call via x402, $0.04/call, status unknown (last checked 2026-10-29).

Scrapes top-level comments and replies from YouTube videos, including metadata like likes, author, channel ID, pinned/hearted status, and publish time — no YouTube API key or quota required.

## Facts

- Endpoint: POST https://agent-data.centorprat.workers.dev/tools/youtube-comments-scraper?utm_source=zero.xyz
- Price: $0.04/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-29
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/youtube-comments-scraper-dbac60a2
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_3vv7DPJisggOUoQuGM-gS

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 youtube-comments-scraper-dbac60a2 -d '<json body>'
```

Example prompt: Scrape the top 50 comments (sorted by top) from this YouTube video — https://www.youtube.com/watch?v=dQw4w9WgXcQ — and include up to 3 replies per comment with their likes, author names, and publish times.

## When to prefer this

Choose this endpoint when you need YouTube comment data without consuming YouTube Data API quota or managing API credentials. It is particularly valuable for competitive research, sentiment analysis, audience feedback collection, or NLP pipelines where raw comment text plus metadata (likes, author, timestamp, pinned/hearted) is needed at low cost per comment. Prefer it over official API wrappers when quota limits are a concern or when comment reply threads are needed with minimal setup.

## Known failure modes

- Video URL or ID is invalid or the video is unavailable — lookup fails without charge
- Video has comments disabled — returns empty results
- maxCommentsPerVideo or maxRepliesPerComment exceeds schema limits (100 and 5 respectively) — request rejected
- Network or scraping timeout on heavily loaded videos — partial or empty results
- Private or age-restricted videos may not return comments

## How this service works

Pay-per-call data and tools for AI agents, $0.002-0.01 per call in USDC via x402 (Base, Polygon or Solana), no account or API key; MAX tiers ($0.05-0.25) run deeper jobs. Agent toolkit: web search, search + read top pages, any page as clean markdown with a prompt-injection check, which-x402-API-to-call recommender, seller check. Data: Google Maps places with contacts, YouTube video data and transcripts, job listings (Indeed, LinkedIn, 13 boards), Google Ads Transparency, TikTok comments, Pinterest, Airbnb, Redfin, AliExpress, app stores, live sports, website and SEO checks, Shopify store tech stacks, and onchain token / address risk checks.

## Output

Returns an array of comment objects per video, each containing: comment text, author name, channel ID, like count, reply count, publish timestamp, direct comment link, pinned/hearted flags, and optionally nested reply objects with the same fields (up to the specified reply cap).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "sort": {
   "enum": [
    "top",
    "newest"
   ],
   "type": "string",
   "description": "Comment order."
  },
  "videos": {
   "type": "array",
   "items": {
    "type": "string"
   },
   "maxItems": 1,
   "description": "YouTube video URLs (watch, shorts, youtu.be) or 11-character ids."
  },
  "includeReplies": {
   "type": "boolean",
   "description": "Also scrape the replies under each comment."
  },
  "maxCommentsPerVideo": {
   "type": "integer",
   "maximum": 100,
   "description": "Top-level comments per video (replies come on top)."
  },
  "maxRepliesPerComment": {
   "type": "integer",
   "maximum": 5,
   "description": "Cap on replies per comment."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "items": [
   {
    "url": "https://www.youtube.com/watch?v=jNQXAC9IVRw&lc=UgzuC3zzpRZkjc5Qzsd4AaABAg",
    "text": "We're so honored that the first ever YouTube video was filmed here!",
    "likes": 4800000,
    "author": "(reviewer)",
    "isReply": false,
    "videoId": "jNQXAC9IVRw",
    "commentId": "UgzuC3zzpRZkjc5Qzsd4AaABAg",
    "isHearted": true,
    "replyCount": 986,
    "publishedTime": "6 years ago",
    "authorChannelId": null,
    "authorIsCreator": false,
    "parentCommentId": null,
    "authorIsVerified": true
   }
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/youtube-comments-scraper-dbac60a2/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent-data.centorprat.workers.dev](https://www.zero.xyz/host/agent-data.centorprat.workers.dev/llms.txt)
