Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

youtube-acquisition

БесплатноБез исполняемых скриптовНе проверен

yt-dlp patterns for acquiring content from YouTube and video platforms

jmaglyот jmagly★ 233 звезды на GitHub

Об этом скилле

YouTube Acquisition

Comprehensive yt-dlp command patterns for downloading video and audio content from YouTube, Vimeo, SoundCloud, and other supported platforms. Includes quality selection strategies, format filtering, the SABR 403 workaround, metadata extraction, and batch operations.

Overview

yt-dlp is the primary tool for media acquisition from YouTube and 1000+ other sites. This skill documents proven patterns from production use, including workarounds for the n-challenge / EJS gate, PO-token requirements, and the older SABR 403 issue.

Key Capabilities:

  • Download best available quality (video + audio)
  • Extract audio-only in multiple formats
  • Handle playlists and channels
  • Embed metadata and thumbnails
  • Download subtitles and auto-captions
  • Work around platform restrictions

Prerequisites (#1229)

As of 2026, basic format selectors return only image storyboards on most YouTube videos until two relatively new gates are satisfied. Read this section before any acquisition attempt — running yt-dlp without these prerequisites produces "Only images are available for download" failures that look like format-selector bugs but aren't.

1. n-challenge / EJS solver

YouTube returns ciphered streaming URLs whose n parameter must be transformed by JavaScript extracted from the player. yt-dlp delegates this to the yt-dlp-ejs plugin plus a JS runtime. Without both, all real formats are filtered out and only sb* storyboard formats remain.

# Install the EJS plugin
pip install --user yt-dlp-ejs

# JS runtime — deno preferred, node accepted
which deno || sudo apt install -y deno   # Debian/Ubuntu
# OR: yt-dlp --js-runtimes node:/usr/bin/node ...

Reference: https://github.com/yt-dlp/yt-dlp/wiki/EJS

2. PO Token (Proof of Origin)

Many client variants (mweb, ios, web) demand a Proof-of-Origin token tied to a logged-in / browser-attested session. Without a PO token provider those clients are skipped, narrowing the available format list. Standard provider:

pip install --user bgutil-ytdlp-pot-provider

Reference: https://github.com/yt-dlp/yt-dlp/wiki/PO-Token-Guide

3. Plugin discovery — install yt-dlp via pip, NOT the standalone zipapp

This is the gotcha that bites operators most often. The standalone yt-dlp zipapp (the form distributed at /usr/local/bin/yt-dlp from the official static download) does not expose user site-packages to its plugin-discovery path. Even after pip install --user yt-dlp-ejs, a zipapp invocation will silently fail to find the EJS solver. Symptoms: n challenge solving failed warnings even after installing the plugin.

The fix is to install yt-dlp itself via pip so it shares site-packages with the EJS plugin, then ensure ~/.local/bin precedes /usr/local/bin on PATH:

pip install --user --break-system-packages yt-dlp-ejs   # plugin
pip install --user --break-system-packages -U yt-dlp    # 2026.03.17+ — same site-packages
export PATH="$HOME/.local/bin:$PATH"

# Verify the EJS solver is discovered
~/.local/bin/yt-dlp -F "https://www.youtube.com/watch?v=VIDEO_ID"
# Should now list real formats, not just sb*

After this, downloads typically succeed automatically — yt-dlp's EJS solver may even fall back to the android_vr client without needing the JS runtime.

Basic Download Patterns

Best Quality Video + Audio

Download highest quality video and audio, merge into single file.

# Recommended: Let yt-dlp choose best combination
yt-dlp "VIDEO_URL"

# Explicit best video+audio merge
yt-dlp -f "bestvideo+bestaudio" "VIDEO_URL"

# Prefer MP4 container
yt-dlp -f "bestvideo[ext=mp4]+bestaudio[ext=m4a]" --merge-output-format mp4 "VIDEO_URL"

# With metadata and thumbnail embedding
yt-dlp -f "bestvideo+bestaudio" \
  --embed-metadata \
  --embed-thumbnail \
  --embed-subs \
  "VIDEO_URL"

Failure-Mode Triage (#1229)

Match the symptom to the right gate before changing format selectors. Three distinct failures look similar but require different fixes:

Symptom Cause Fix
-F lists only sb0..sb3 storyboard formats; warning n challenge solving failed, Only images are available n-challenge / EJS missing Install yt-dlp-ejs and a JS runtime (see Prerequisites). Most failures resolve here.
Client-specific 403s; warning mweb formats require a GVS PO Token or similar PO token required Install bgutil-ytdlp-pot-provider (see Prerequisites).
Explicit-format 403 on bestvideo[ext=mp4]+bestaudio[ext=m4a] selectors against newer videos SABR Simplify to best[ext=mp4]/best (below).

SABR 403 (legacy fix — keep for explicit-selector failures)

# BROKEN (SABR 403 on explicit selectors):
yt-dlp -f "bestvideo[ext=mp4]+bestaudio[ext=m4a]" "VIDEO_URL"

# WORKS (SABR-compatible):
yt-dlp -f "best[ext=mp4]/best" "VIDEO_URL"

# Audio-only SABR-safe:
yt-dlp -f "bestaudio/best" -x --audio-format mp3 "VIDEO_URL"

**Why this still helps

Полный SKILL.md на GitHub

Установить youtube-acquisition в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

FAQ

Что делает скилл youtube-acquisition?

yt-dlp patterns for acquiring content from YouTube and video platforms

Как установить скилл youtube-acquisition?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл youtube-acquisition запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить youtube-acquisition с