> ## Content Index
> Fetch the complete content index at: https://agentkey.app/blog/llms.txt
> Use this file to discover other available public pages before exploring further.

# How to Find Content Gaps in Your Niche From YouTube Comments With AgentKey
- URL: https://agentkey.app/blog/find-content-gaps-from-youtube-comments/
- Published: 2026-11-24T06:19:18.000Z
- Updated: 2026-11-24T06:19:18.000Z
- Description: Connect YouTube to your AI agent with AgentKey, pull the newest comments on the top videos for a topic, and count the questions the videos left unanswered.
- Author: lxcong
- Tags: Content & Social, #en, #ak-i18n-source, #translation-b8828b68-8b71-447d-b981-f204799dd4a0, #ak-i18n-version-42a90a7504717303

Find the questions viewers ask under the top videos in your niche that those videos never answer. Connect AgentKey, then paste this into your agent:

```
Use AgentKey's YouTube tools to find the questions viewers keep asking under videos about [TOPIC] that the videos do not answer. Check each tool's price before any paid call, and retry a call that times out up to three times.

Search YouTube for the topic with YouTube Search (AnyAPI/youtube_search) sorted by most viewed, then rank the results by view count yourself. Pick the three most-viewed videos whose titles are about this topic and not a neighbouring one, each from a different channel, and call them Video 1, 2 and 3. For each, pull two pages of 20 comments with YouTube Video Comments (AnyAPI/youtube_video_comments) in newest order, using the nextCursor from the first page, and drop the author fields. Tell me how many comments came back per video, how many were the channel's own, and the time span the viewer comments cover.

Mark every viewer comment that asks a question or asks for help, counting one comment as one question. Give each exactly one type by its main ask, with types created from the data, and report each type with its count per video and up to three paraphrased examples. Tell me how many questions have no reply, per video.

Then get each transcript with YouTube Video Transcript (AnyAPI/youtube_video_transcript). Check that its segments have text up to the video's length and that the text is in the video's language; if not, say so and do not judge that video. For the others, say whether the video answers each question fully, partly or not at all, and give the counts per type. Separate what the comments say from what you infer.
```

Content and video leads usually pick the next topic from keyword tools or from what competitors have published. The viewers of those videos write down what was missing, in the comments, every day. Reading them by hand does not scale, and YouTube shows the popular comments first.

An AI agent can do the reading and the counting, with one catch: in our test it could find videos on its own and could not read a single comment. This guide shows how AgentKey supplies the videos, comments and transcripts, and how to turn them into a counted list of unanswered questions. We ran every step on three sourdough starter videos on November 24, 2026, and the numbers below come from that run.

AgentKey returns the data. Your agent's model decides what counts as a question and whether a video answered it, and you check the result. The sample is 118 viewer comments, so read the output as a list of leads.

At the end you will have:

- A counted list of question types across the top videos for your topic.
- For each type, how many questions the videos answered and how many they did not.
- A count of the questions nobody replied to.

## Why can't an AI agent read YouTube comments on its own?

In our test, the agent's built-in tools reached YouTube and brought back nothing to count. A gap analysis needs the most-viewed videos for a topic, then each video's comments with their text and reply counts.

We asked Claude Code to get that with its built-in tools first. The page fetch opened a YouTube search page and got only the site footer. A video page came back as **808 characters of text**: the title and the footer, with no view count, description or comments.

The web search did better at finding videos. An open search returned 16 links, none on youtube.com. Limited to youtube.com, it returned **10 video links**, with no view counts to rank them by and no comment lists.

![Three routes compared: the built-in page fetch returned a video page as 808 characters with the title only, the built-in web search returned 10 video links with no view counts or comments, and AgentKey's YouTube tools returned 120 comments from 3 videos.](https://agentkey.app/blog/content/images/2026/11/youtube-comments-1-access.png)

So the block is partial: the agent can name videos, but it cannot rank them or read the comments. The other route is YouTube's own Data API, which needs a Google Cloud project and an API key; we did not test it.

## Which AgentKey tools does this use?

Three AgentKey YouTube tools do the reading, and finding them is free. Prices and capabilities were verified on November 24, 2026.

### 1\. YouTube Search

Searches YouTube and returns the matching videos. In the AgentKey catalog it is named AnyAPI/youtube\_search.

**Pricing:** from 0.1 credits per call. Our call was charged 0.1\. The same call in a second test run was charged 0.3.

**Features:** sort by relevance or by most viewed. Our call returned 20 videos, each with its title, channel, view count, length, link and a relative age such as "8 years ago".

### 2\. YouTube Video Comments

Lists the comments on a video from its URL. Its catalog name is AnyAPI/youtube\_video\_comments.

**Pricing:** from 0.2 credits per call. Each of our calls returned a page of 20 comments and was charged 0.2.

**Features:** top or newest order, and a cursor for the next page. Each comment has its text, like count, reply count and a relative time such as "2 days ago". It also returns the author's handle, which we dropped.

### 3\. YouTube Video Transcript

Returns a video's captions as timed segments and as one text. Its catalog name is AnyAPI/youtube\_video\_transcript.

**Pricing:** from 0.2 credits per call. Each of our three calls was charged 0.2.

**Features:** takes a video URL or ID and reports the caption language. Two of our three transcripts were complete. The third had text for the first 45 seconds of a 9-minute video and blank segments after that.

### 4\. Tool discovery and price check

Your agent finds a tool and sees its price before it spends anything.

**Pricing:** free.

**Features:** search the catalog in plain language, see each tool's parameters and per-call cost, and check remaining credits.

The ten calls in the steps below cost **1.9 credits**: one search, six comment pages and three transcripts. On the Lite plan, at $12.90 a month for 500 credits, that is about 5 cents. Our whole run made 12 paid calls for 2.7 credits, two of them tests.

Listed prices are minimums; calls are billed on what the data source reports.

## How to find content gaps from YouTube comments, step by step

Connect AgentKey once, then run four steps.

![Diagram of the four steps: find the most-viewed videos, pull the newest comments, count the questions by type, check each against the transcript.](https://agentkey.app/blog/content/images/2026/11/youtube-comments-2-steps.png)

### Before you start

Install AgentKey with the one-line installer. It finds the agents on your machine, adds AgentKey to each, and opens a browser tab to sign in. A new account starts on the Free plan with no card.

```
curl -fsSL https://agentkey.app/install.sh | bash
```

Other install methods, including the Claude Code plugin, are in the [installation guide](https://docs.agentkey.app/connect/install?ref=agentkey.app). The [YouTube for Claude Code page](https://agentkey.app/integrations/youtube-api-for-claude-code/?ref=agentkey.app) shows what the connection gives you.

Then fix the sample before you look at data. We chose the three most-viewed videos for one topic and the 40 newest comments on each.

### Step 1\. Find the most-viewed videos

Give your agent a fixed rule for choosing videos. Ours was the three most-viewed results with the topic in the title, each from a different channel.

One YouTube Search call for "how to make a sourdough starter", sorted by most viewed, returned **20 videos** for 0.1 credits. Only 4 of the 20 had "starter" in the title.

The rule gave us Videos 1, 2 and 3, with 8.9, 3.4 and 2.7 million views, published about eight, two and five years ago. The list ran close to view order with one pair swapped, so have the agent rank by the view count itself.

### Step 2\. Pull the newest comments

Ask for newest order. Our first call asked for Video 1's top comments and returned 20: one from the channel and 19 from viewers, with 128 to 13,000 likes each. **None of the 19 asked a question.**

Newest order took two YouTube Video Comments calls per video, six calls for 1.2 credits, and returned **120 comments**. Two were the channels' own pinned comments, which newest order still lists first. That left 118 from viewers: 39, 40 and 39.

Comments carry relative times only: the 40 newest reached back three weeks on Video 2, four months on Video 3 and six months on Video 1.

### Step 3\. Count the questions by type

This step is the model's work. Ask it to mark each comment that asks something and to create the types from the data.

**59 of the 118 viewer comments** asked a question: 11, 25 and 23 on Videos 1, 2 and 3\. Another 9 described a starter that was misbehaving without asking anything, and we left them out.

Three types made up 33 of the 59:

- **Discard:** 13 questions. Why half the starter is thrown away, what to do with it, and whether it can become a second starter.
- **Which flour:** 11 questions. Whether bread flour, whole wheat or all-purpose will work, and why the recipe changes flour partway.
- **Starter stalled:** 9 questions. It rose on day two or three and then stopped.

![Bar chart of question types in 59 questions. Discard leads with 13, which flour 11, starter stalled 9, other 9, upkeep and fridge 7, when is it ready 4, amounts and ratios 3, is this normal 3.](https://agentkey.app/blog/content/images/2026/11/youtube-comments-3-types.png)

The rest were upkeep, fridge storage and feeding rhythm (7), when the starter is ready (4), amounts and ratios (3), and whether a smell or a layer of liquid is normal (3). Nine fit no type, among them jar choice, a download link that no longer works and food safety.

Reply counts add a second signal. **30 of the 59 questions had no reply**: 9 of 11 on Video 1 and 20 of 23 on Video 3, against 1 of 25 on Video 2.

### Step 4\. Check each question against the transcript

Call YouTube Video Transcript once per video, 0.6 credits for three, and have the model judge each question against the text. We counted a question as answered only when the transcript settles it as asked.

Video 1's transcript had text for its first 45 seconds only, so its 11 questions were not judged. A second tool, AnyAPI/youtube\_video\_transcript\_full at 0.6 credits, returned automatic captions labelled Korean for this English video.

For Videos 2 and 3, **35 of 48 questions were not answered in the video**, and 13 were. The unanswered share by type: which flour 8 of 8, discard 8 of 12, starter stalled 6 of 7, other 5 of 6, upkeep 4 of 7, is this normal 3 of 3, amounts 1 of 2, and when is it ready 0 of 3.

![Paired bars per question type for 48 questions on Videos 2 and 3. Not answered in the video: which flour 8 of 8, discard 8 of 12, starter stalled 6 of 7, other 5 of 6, upkeep and fridge 4 of 7, is this normal 3 of 3, amounts and ratios 1 of 2, when is it ready 0 of 3. Answered: 0, 4, 1, 1, 3, 0, 1 and 3.](https://agentkey.app/blog/content/images/2026/11/youtube-comments-4-answered.png)

Video 2 tells viewers to throw the discard away while the starter is young, which settled 4 questions. Neither video says whether the discard can start a second jar, and three viewers of Video 3 asked what happens to the starter left in the jar.

Our reading: the gaps here are a flour substitution guide, a "why discard" explainer and a troubleshooting piece for a starter that stops around day three. The 13 answered questions suggest a different fix, such as chapters or a pinned comment. Both are inferences from 48 questions.

## How do you check the results?

Recount a slice by hand, and look for the things that distort a comment sample.

- **Count what came back.** Each page held 20 comments, and two of our 120 were pinned comments from the channels. Set those aside before counting.
- **Confirm the order.** Top order gave us 0 questions in 19 viewer comments on Video 1, where newest order gave 11 in 39.
- **Read every transcript to the end.** Video 1's blank segments carried timestamps up to 8:37 of 8:59, so the last timestamp alone would have passed it.
- **Expect the model's judgement to move.** A second agent ran the prompt and found the same 59 questions, but judged 12 answered, 10 partly answered and 26 unanswered where we had 13 and 35.
- **Do not read a reply as an answer.** The tool returns a reply count. We did not open the replies or check who wrote them.
- **Mind the sample.** 118 comments from three videos support the top three types, not the gap between a type of three and a type of four.

## When should you use something else?

Use a different route when the videos are your own, or when you need every comment or continuous tracking.

If the videos are on your channel, YouTube Studio already lists your comments and lets you reply. If you need every comment on a video with thousands, this run did not show that: we read 40 per video.

If your engineers are building a pipeline, YouTube's Data API gives direct control at the cost of a Google Cloud project and quota handling. If you need alerts when new questions appear, a monitoring product is built for that, and we did not test scheduled runs with AgentKey.

This is the AgentKey blog, and AgentKey provides the tools described here. They return videos, comments and transcripts. They do not decide what counts as a question or what you should publish.

## Which tool should you use for each job?

Pick the tool from the question you are asking. Prices were verified on November 24, 2026.

- **Find the most-viewed videos for a topic:** YouTube Search, sorted by most viewed. From 0.1 credits per page of 20 videos.
- **Read what viewers wrote:** YouTube Video Comments, in newest order. From 0.2 credits per page of 20 comments.
- **See what a video covered:** YouTube Video Transcript. From 0.2 credits per video.
- **Check a price before spending:** tool discovery and inspection. Free.

## Conclusion

You now have a way to turn the top videos for a topic into a counted list of viewer questions, split by whether the videos answered them. Pull newest comments, read each transcript to the end, and recount a slice before you plan from it.

[Connect YouTube to your agent through AgentKey →](https://agentkey.app/integrations/youtube-api-for-claude-code/?ref=agentkey.app)

## FAQ

### Can Claude Code read YouTube comments without AgentKey?

Not in our test. On November 24, 2026, its page fetch returned a video page as 808 characters with no comments, and its web search returned video links with no comments or view counts. Other agents may have different built-in access.

### Do I need to write code?

No. You install AgentKey with one command and then ask your agent in plain language.

### How much does it cost to analyze three videos?

The ten calls in the steps cost 1.9 credits, about 5 cents on the Lite plan. A second run of the same prompt cost 2.1 credits, because its search call was charged 0.3.

### How many comments can I pull per video?

Each call returned 20 comments, and a cursor fetches the next page. We pulled two pages per video and did not test how far paging goes.

### Does AgentKey decide which questions a video answered?

No. AgentKey returns the comments and the transcript. Your agent's model marks the questions and judges them against the transcript, so recount a slice by hand.

### Which agents can run this?

We ran it in Claude Code only. AgentKey lists setup steps for other clients such as Cursor, Codex and ChatGPT on its [supported agents page](https://docs.agentkey.app/connect/supported-agents?ref=agentkey.app).

### Is there a free way to try it?

A new account starts on the Free plan, which includes complimentary credits and needs no card. Finding and inspecting tools does not use credits.