YouTube comments API
Pass a public YouTube video URL and get top-level comments with author, likes, and reply counts — same Social Fetch envelope as channel lookup and transcripts.
GET /v1/youtube/videos/comments1 credit per successful request.
About this endpoint
Brand monitoring, toxicity filters, and research jobs often need the comment thread under a video, not a scraped watch-page HTML blob. YouTube's own comment UI is fine for a person. For a batch job you want a stable JSON page: text, author identity, likes, reply counts, and an opaque cursor when there is more.
`GET /v1/youtube/videos/comments` takes a required `url` query param (watch links, `youtu.be`, Shorts). Optional `order` is `top` (highest-ranked) or `newest`. On a found lookup, read `data.comments` and `data.page`. Each comment can include `id`, `text`, `createdAt`, `publishedTimeText`, `likeCount`, `replyCount`, `repliesCursor`, and an `author` object with handle, display name, channel URL, and verification flags. Paginate by passing `data.page.nextCursor` as the `cursor` query param while `hasMore` is true. Branch on `data.lookupStatus` before you write rows.
Pricing is on the credit badge for this operation; bill from `meta.creditsCharged` on every response. Nested replies are a separate route: `GET /v1/youtube/videos/comments/replies` with the comment's `repliesCursor`. For spoken text on the same video, use the transcript endpoint under the same YouTube tag and API key.
YouTube comments API FAQ
How do I list YouTube video comments via API?
Call GET /v1/youtube/videos/comments with your Social Fetch API key (x-api-key) and a public video url query param. Read data.lookupStatus, then data.comments and data.page. Full parameters and examples are in the API docs.
How much does the YouTube comments endpoint cost?
Pricing is documented on the operation in the API registry (shown on this page). Confirm on every response with meta.creditsCharged — that field is the billing source of truth.
Can I sort YouTube comments by top or newest?
Yes. Pass optional order=top for highest-ranked comments or order=newest for the most recent. Omit order when you are fine with the API default for that call.
How does pagination work on YouTube video comments?
Each response includes data.page.nextCursor and data.page.hasMore. When hasMore is true, pass nextCursor as the cursor query param on the next request. The cursor is opaque — do not invent or parse it.
How do I get replies to a YouTube comment?
Use GET /v1/youtube/videos/comments/replies with the repliesCursor from a comment in this list response (or page.nextCursor when paging replies). Top-level listing and reply threads are separate operations.
What fields are in each YouTube comment?
Items can include id, text, createdAt, publishedTimeText, likeCount, replyCount, repliesCursor, and author (handle, displayName, platformUserId, verified, creator, avatarUrl, channelUrl). Always branch on data.lookupStatus before treating comments as present.
What URL formats does the YouTube comments API accept?
Public YouTube video URLs: standard watch links, youtu.be short links, and Shorts URLs. Pass one url per request.
Other YouTube endpoints
- ChannelGET /v1/youtube/channel
- Channel videosGET /v1/youtube/channels/videos
- Channel shortsGET /v1/youtube/channels/shorts
- PlaylistGET /v1/youtube/playlists
- Community postGET /v1/youtube/community-posts
- SearchGET /v1/youtube/search
- Hashtag searchGET /v1/youtube/search/hashtags
- Trending shortsGET /v1/youtube/shorts/trending