# YouTube comments: `POST /v1/youtube/comments`

Cost: 2 credits (2 (an empty answer, an unknown or private video, and failed requests are free)). Docs: https://scrapercompany.com/docs/reference/youtube-comments

One page (~20 threads) of a video's comments.

Each comment carries its id, text, the relative `published_time`
verbatim (with "(edited)"), the author (name, channel id, handle,
avatar, verified), `likes` and `reply_count` as exact integers when
YouTube prints them exactly ("14K" stays in `likes_text` only),
`is_pinned` with YouTube's `pinned_text`, `is_hearted` (creator heart)
and `author_is_creator`. `replies_page_token` reads a thread's replies
through this same route. `total_comments_text` is the header's count.
Comments turned off answer `comments_disabled: true` with YouTube's
message and no comments (not charged).

Request body (JSON):

- `video_id` (string | null; optional; min length 11, max length 300): The 11-character video id (`8jPQjjsBbIc`) or any YouTube video URL: `watch?v=`, `youtu.be/`, `/shorts/`, `/embed/`, `/live/`. Ids come from `POST /v1/youtube/search` (`videos[].video_id`). Required unless `page_token` is given.
- `sort` (string; optional; default top; one of newest, top): YouTube's Sort-by menu: `top` (YouTube's featured order) or `newest` (one extra upstream call on the first page). A `page_token` keeps the sort it was issued with.
- `page_token` (string | null; optional; max length 4000): `next_page_token` from a previous answer, or a comment's `replies_page_token` to read its replies. It carries the video and the sort.
- `hl` (string; optional; default en; pattern ^[A-Za-z]{2,3}(?:-[A-Za-z0-9]{2,4})?$): Interface language YouTube localizes texts in (`hl`): relative dates, view-count wording, caption track names. Counts parse to integers only for English-style numbers.
- `gl` (string; optional; default US; pattern ^[A-Za-z]{2}$): Content country (`gl`), two letters.

Base URL: `https://api.scrapercompany.com`. Auth: send your key in the `x-api-key` header. A failed request (4xx or 5xx) or an empty result costs 0 credits.

- [Full API reference as one Markdown file](https://scrapercompany.com/llms-full.txt)
- [OpenAPI spec](https://scrapercompany.com/openapi.json)
