/youtube-search
Search YouTube by keyword and return structured video metadata (title, URL, channel, views, duration, date) via yt-dlp. No API keys. Triggers on: "search youtube", "find youtube videos", "top youtube videos on", "trending videos on", "youtube results for", "yt search",
$ npx -y skills add Mathews-Tom/armory --skill youtube-search --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
- Slash command
/youtube-search
Context preview
The summary Claude sees to decide when to auto-load this skill.
Search YouTube by keyword and return structured video metadata (title, URL, channel, views, duration, date) via yt-dlp. No API keys. Triggers on: "search youtube", "find youtube videos", "top youtube videos on", "trending videos on", "youtube results for", "yt search",
SKILL.md
youtube-search.SKILL.mdname: youtube-search
description: 'Search YouTube by keyword and return structured video metadata (title, URL, channel, views, duration, date) via yt-dlp. No API keys. Triggers on: "search youtube", "find youtube videos", "top youtube videos on", "trending videos on", "youtube results for", "yt search", "/yt-search".'
metadata:
version: 1.1.1
category: research
tags: [youtube, search, skill]
difficulty: beginner
YouTube Search
Search YouTube by keyword and return structured video metadata — title, URL, channel, views, duration, upload date. Uses `yt-dlp` for scraping with no API keys or OAuth required.
Prerequisites
uv tool install yt-dlp
Verify:
yt-dlp --version
Usage
Basic Search
yt-dlp "ytsearch10:claude code skills" --dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -r '[.title, .url, .channel, .view_count, .duration_string, .upload_date] | @tsv'
- `ytsearch10:` — search YouTube, return 10 results (adjust number as needed)
- `--dump-json` — output metadata as JSON
- `--flat-playlist` — don't download, just list
- `--no-warnings` — suppress non-error output
Structured JSON Output
yt-dlp "ytsearch5:claude code mcp servers" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq '{
title: .title,
url: .url,
channel: .channel,
views: .view_count,
duration: .duration_string,
upload_date: .upload_date,
description: (.description // "" | .[0:200])
}'Search with Sorting
yt-dlp does not support server-side sort. To sort by views or date, capture all results and sort client-side:
# Sort by view count (descending)
yt-dlp "ytsearch20:AI agents 2026" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.view_count) | .[:10][] | {title, url, channel, views: .view_count}'# Sort by upload date (newest first)
yt-dlp "ytsearch20:claude code tutorial" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.upload_date) | .[:10][] | {title, url, channel, upload_date}'Search Result Count
The number after `ytsearch` controls how many results to fetch:
| Pattern | Results | | ------------------ | -------------------------------------- | | `ytsearch5:query` | 5 results | | `ytsearch10:query` | 10 results (default recommendation) | | `ytsearch20:query` | 20 results | | `ytsearch50:query` | 50 results (slow, may hit rate limits) |
**Recommendation:** Fetch 15-20 results, then filter/sort client-side to the top N the user wants. This provides enough data for meaningful sorting without being excessive.
Workflow
User provides search query
|
v
+---------------------+
| Step 0: Deps check |
+----------+----------+
v
+---------------------+
| Step 1: Search |
| (yt-dlp ytsearch) |
+----------+----------+
v
+---------------------+
| Step 2: Parse JSON |
| (jq formatting) |
+----------+----------+
v
+---------------------+
| Step 3: Present |
| results to user |
+---------------------+Step 1: Execute Search
yt-dlp "ytsearch${COUNT}:${QUERY}" \
--dump-json --flat-playlist --no-warnings 2>/dev/nullStep 2: Parse and Format
Extract relevant fields with `jq`. The full metadata object from yt-dlp contains many fields; the useful subset for search results:
| Field | Description | | ------------------ | ------------------------------------------ | | `.title` | Video title | | `.url` | Full YouTube URL | | `.channel` | Channel name | | `.view_count` | Total views (integer) | | `.duration_string` | Duration as `H:MM:SS` or `MM:SS` | | `.upload_date` | Upload date as `YYYYMMDD` | | `.description` | Video description (can be long — truncate) | | `.like_count` | Likes (may be null) | | `.comment_count` | Comments (may be null) |
Step 3: Present Results
Format as a markdown table for the user:
yt-dlp "ytsearch10:${QUERY}" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.view_count) | .[] | "| \(.title[:60]) | \(.channel) | \(.view_count) | \(.duration_string) | \(.upload_date) |"' -rPrefix with a header row:
| Title | Channel | Views | Duration | Date |
|-------|---------|-------|----------|------|
Advanced Patterns
Filter by Duration
# Only videos longer than 10 minutes (600 seconds)
yt-dlp "ytsearch20:deep dive AI agents" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s '[.[] | select(.duration >= 600)] | sort_by(-.view_count) | .[:10][]'
Filter by Recency
# Only videos from the last 30 days
CUTOFF=$(date -v-30d +%Y%m%d 2>/dev/null || date -d "30 days ago" +%Y%m%d)
yt-dlp "ytsearch20:claude code" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s --arg cutoff "$CUTOFF" '[.[] | select(.upload_date >= $cutoff)] | sort_by(-.view_count) | .[]'
Channel-Specific Search
# Search within a specific channel
yt-dlp "ytsearch10:skills site:youtube.com/c/ChannelName" \
--dump-json --flat-playlist --no-warnings 2>/dev/null
Or use the channel URL directly:
yt-dlp "https://www.youtube.com/@ChannelName/search?query=skills" \
--dump-json --flat-playlist --no-warnings 2>/dev/null
Extract URLs Only (for Piping)
# Get just URLs for feeding into other tools (youtube-analysis, notebooklm)
yt-dlp "ytsearch10:claude code MCP" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -r '.url'
Composability
This skill produces
Read more
name: youtube-search description: 'Search YouTube by keyword and return structured video metadata (title, URL, channel, views, duration, date) via yt-dlp. No API keys. Triggers on: "search youtube", "find youtube videos", "top youtube videos on", "trending videos on", "youtube results for", "yt search", "/yt-search".' metadata: version: 1.1.1 category: research tags: [youtube, search, skill] difficulty: beginner
YouTube Search
Search YouTube by keyword and return structured video metadata — title, URL, channel, views, duration, upload date. Uses `yt-dlp` for scraping with no API keys or OAuth required.
Prerequisites
uv tool install yt-dlp
Verify:
yt-dlp --version
Usage
Basic Search
yt-dlp "ytsearch10:claude code skills" --dump-json --flat-playlist --no-warnings 2>/dev/null \ | jq -r '[.title, .url, .channel, .view_count, .duration_string, .upload_date] | @tsv'
- `ytsearch10:` — search YouTube, return 10 results (adjust number as needed)
- `--dump-json` — output metadata as JSON
- `--flat-playlist` — don't download, just list
- `--no-warnings` — suppress non-error output
Structured JSON Output
yt-dlp "ytsearch5:claude code mcp servers" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq '{
title: .title,
url: .url,
channel: .channel,
views: .view_count,
duration: .duration_string,
upload_date: .upload_date,
description: (.description // "" | .[0:200])
}'Search with Sorting
yt-dlp does not support server-side sort. To sort by views or date, capture all results and sort client-side:
# Sort by view count (descending)
yt-dlp "ytsearch20:AI agents 2026" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.view_count) | .[:10][] | {title, url, channel, views: .view_count}'# Sort by upload date (newest first)
yt-dlp "ytsearch20:claude code tutorial" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.upload_date) | .[:10][] | {title, url, channel, upload_date}'Search Result Count
The number after `ytsearch` controls how many results to fetch:
| Pattern | Results | | ------------------ | -------------------------------------- | | `ytsearch5:query` | 5 results | | `ytsearch10:query` | 10 results (default recommendation) | | `ytsearch20:query` | 20 results | | `ytsearch50:query` | 50 results (slow, may hit rate limits) |
**Recommendation:** Fetch 15-20 results, then filter/sort client-side to the top N the user wants. This provides enough data for meaningful sorting without being excessive.
Workflow
User provides search query
|
v
+---------------------+
| Step 0: Deps check |
+----------+----------+
v
+---------------------+
| Step 1: Search |
| (yt-dlp ytsearch) |
+----------+----------+
v
+---------------------+
| Step 2: Parse JSON |
| (jq formatting) |
+----------+----------+
v
+---------------------+
| Step 3: Present |
| results to user |
+---------------------+Step 1: Execute Search
yt-dlp "ytsearch${COUNT}:${QUERY}" \
--dump-json --flat-playlist --no-warnings 2>/dev/nullStep 2: Parse and Format
Extract relevant fields with `jq`. The full metadata object from yt-dlp contains many fields; the useful subset for search results:
| Field | Description | | ------------------ | ------------------------------------------ | | `.title` | Video title | | `.url` | Full YouTube URL | | `.channel` | Channel name | | `.view_count` | Total views (integer) | | `.duration_string` | Duration as `H:MM:SS` or `MM:SS` | | `.upload_date` | Upload date as `YYYYMMDD` | | `.description` | Video description (can be long — truncate) | | `.like_count` | Likes (may be null) | | `.comment_count` | Comments (may be null) |
Step 3: Present Results
Format as a markdown table for the user:
yt-dlp "ytsearch10:${QUERY}" \
--dump-json --flat-playlist --no-warnings 2>/dev/null \
| jq -s 'sort_by(-.view_count) | .[] | "| \(.title[:60]) | \(.channel) | \(.view_count) | \(.duration_string) | \(.upload_date) |"' -rPrefix with a header row:
| Title | Channel | Views | Duration | Date | |-------|---------|-------|----------|------|
Advanced Patterns
Filter by Duration
# Only videos longer than 10 minutes (600 seconds) yt-dlp "ytsearch20:deep dive AI agents" \ --dump-json --flat-playlist --no-warnings 2>/dev/null \ | jq -s '[.[] | select(.duration >= 600)] | sort_by(-.view_count) | .[:10][]'
Filter by Recency
# Only videos from the last 30 days CUTOFF=$(date -v-30d +%Y%m%d 2>/dev/null || date -d "30 days ago" +%Y%m%d) yt-dlp "ytsearch20:claude code" \ --dump-json --flat-playlist --no-warnings 2>/dev/null \ | jq -s --arg cutoff "$CUTOFF" '[.[] | select(.upload_date >= $cutoff)] | sort_by(-.view_count) | .[]'
Channel-Specific Search
# Search within a specific channel yt-dlp "ytsearch10:skills site:youtube.com/c/ChannelName" \ --dump-json --flat-playlist --no-warnings 2>/dev/null
Or use the channel URL directly:
yt-dlp "https://www.youtube.com/@ChannelName/search?query=skills" \ --dump-json --flat-playlist --no-warnings 2>/dev/null
Extract URLs Only (for Piping)
# Get just URLs for feeding into other tools (youtube-analysis, notebooklm) yt-dlp "ytsearch10:claude code MCP" \ --dump-json --flat-playlist --no-warnings 2>/dev/null \ | jq -r '.url'
Composability
This skill produces
Curated, production-grade skills, agents, hooks, rules, commands, utilities, and presets for AI coding agents. No magic, no demos — battle-tested workflows built for developers who use AI seriously.
Repo: Mathews-Tom/armory
Other skills on armory.
- /adr-writer
Generates Architecture Decision Records capturing context, rationale, alternatives, and consequences in numbered status-tracked format. Triggers on: "write an ADR", "document this decision", "architecture decision record", "decision record", "design decision", "ADR for".
Open skill - /agent-builder
Build AI agents and automate Claude Code programmatically via the Claude Agent SDK and headless CLI mode. Covers Python SDK, claude -p, SDK MCP servers, hooks, sessions. Triggers on: "build an agent", "agent SDK", "headless mode", "automate Claude", "programmatic agent".
Open skill - /api-docs-generator
Audits and enhances FastAPI and REST API documentation: missing descriptions, response codes, examples, docstrings, Pydantic models, OpenAPI spec. Triggers on: "generate API docs", "document this API", "OpenAPI for", "FastAPI docs", "document endpoints", "swagger docs".
Open skill - /architecture-diagram
Generate layered architecture diagrams as self-contained HTML with inline SVG icons, CSS Grid containers, and connection overlays. Triggers on: "architecture diagram", "infra diagram", "system diagram", "deployment diagram", "topology", "draw architecture". NOT for architecture
Open skill - /architecture-reviewer
Architecture reviews across 7 dimensions (structural, scalability, enterprise readiness, performance, security, ops, data) with scored reports. Triggers on: "review architecture", "critique design", "audit system", "assess scalability", "enterprise readiness", "technical due
Open skill - /arxiv-figures
Optimize and prepare figures for arXiv submission: format conversion (EPS/PDF/PNG/JPG), size reduction, metadata stripping, processor compatibility (DVI vs PDFLaTeX). Triggers on: "optimize figures for arXiv", "reduce figure size", "convert figures for arXiv", "fix arXiv
Open skill

