Docs / API reference

POST/v1/data/youtube/comments

YouTube Comments

Get comments for a YouTube video including author info, verification status, likes, reply count, pinned status, and creator heart status.

Execution model

Live request

Runtime depends on endpoint, target, pagination, rendering mode, and active plan limits.

Credit weight

Live catalog

Current weights are managed from the Data API Weights admin table and shown on pricing before use.

Parameters

NameTypeRequirementDescription
video_idstringRequiredYouTube video ID. 1-20 characters.
limitnumberOptionalMaximum comments and replies to return (1-1000).
cursorstringOptionalOpaque root/reply cursor from the previous response.
max_pagesnumberOptionalMaximum root-comment pages to scan (1-50).
include_repliesbooleanOptionalInclude inline and paginated replies.
replies_limitnumberOptionalMaximum replies across the request (0-1000).
countrystringOptionalYouTube country/region code (maps to gl).
languagestringOptionalYouTube result language.

Request and response

curl -X POST "https://api.datablue.dev/v1/data/youtube/comments" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "video_id": "dQw4w9WgXcQ",
  "limit": 5,
  "include_replies": true,
  "replies_limit": 20,
  "max_pages": 3,
  "country": "us",
  "language": "en"
}'
Example response
{
  "success": true,
  "time_taken": 2.56,
  "video_id": "dQw4w9WgXcQ",
  "count": 5,
  "complete": false,
  "stop_reason": "return_limit_reached",
  "pages_fetched": 1,
  "reply_pages_fetched": 0,
  "next_cursor": "dbyt1.eyJraW5kIjoiY29tbWVudHMifQ.signature",
  "reply_cursors": {},
  "scanned_count": 20,
  "matched_count": 20,
  "duplicate_count": 0,
  "comments": [
    {
      "comment_id": "UgxtV0-example",
      "video_id": "dQw4w9WgXcQ",
      "parent_comment_id": null,
      "is_reply": false,
      "author": "Rick Astley",
      "author_channel_id": "UCuAXFkgsw1L7xaCfnd5JJOw",
      "author_avatar": "https://yt3.ggpht.com/ytc/AIdro_n...",
      "is_verified": true,
      "is_creator": true,
      "text": "Thank you for 1.5 billion views! Never gonna let you down.",
      "likes": 892000,
      "likes_count_status": "exact",
      "reply_count": 47200,
      "published": "3 months ago",
      "pinned": true,
      "hearted": false
    }
  ]
}