Agent skill

Universal Media Downloader

by cat-xierluo in cat-xierluo/legal-skills

输入各类视频网站/播客平台链接后,自动下载对应媒体文件并交付给用户。优先使用 yt-dlp 覆盖抖音(Douyin)、B站(Bilibili)、YouTube 等常见视频网站,也可用于可直接暴露音频地址的播客平台(如小宇宙单集链接)。当遇到 403/登录/年龄或地区限制时,支持使用 cookies.txt 重试;对于可能存在 DRM/加密或条款限制的平台(例如部分 Spotify…

MITAuto-check: warnings

Install Universal Media Downloader

The automated check flagged lines worth reading first. See the safety section below.

skills CLI
$ npx skills add cat-xierluo/legal-skills --skill universal-media-downloader -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install cat-xierluo/legal-skills universal-media-downloader --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/cat-xierluo/legal-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/universal-media-downloader .claude/skills/universal-media-downloader && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
universal-media-downloader
GitHub stars
720
Token cost
~1.2k tokens
SKILL.md length
287 words
Files
7 (incl. scripts, references)
Skills in repo
62
Repo updated
First seen
Licence
MIT

At a glance

输入各类视频网站/播客平台链接后,自动下载对应媒体文件并交付给用户。优先使用 yt-dlp 覆盖抖音(Douyin)、B站(Bilibili)、YouTube 等常见视频网站,也可用于可直接暴露音频地址的播客平台(如小宇宙单集链接)。当遇到 403/登录/年龄或地区限制时,支持使用 cookies.txt 重试;对于可能存在 DRM/加密或条款限制的平台(例如部分 Spotify…

  • SKILL.md covers 适用范围, 快速开始, 平台差异与限制(重要) and Bundled scripts, plus 1 more section
  • Runs Python scripts from its folder; calls python, pip and brew

What it does

Universal Media Downloader is an agent skill from cat-xierluo/legal-skills. 输入各类视频网站/播客平台链接后,自动下载对应媒体文件并交付给用户。优先使用 yt-dlp 覆盖抖音(Douyin)、B站(Bilibili)、YouTube 等常见视频网站,也可用于可直接暴露音频地址的播客平台(如小宇宙单集链接)。当遇到 403/登录/年龄或地区限制时,支持使用 cookies.txt 重试;对于可能存在 DRM/加密或条款限制的平台(例如部分 Spotify 内容),应提示用户仅下载其有权保存的内容,并在不可下载时建议改用官方离线/导出渠道或提供原始 RSS/直链。抖音视频在 yt-dlp 撞签名墙("Fresh cookies needed")时自动三级 fallback:无登录直连 aweme.snssdk.com/v1/play → 本机浏览器游客 cookie(无需登录抖音)重跑 yt-dlp,全程无感;抖音图文笔记暂不支持自动下载,需手动处理。

Its SKILL.md is about 1.2k tokens, which your agent loads only when the skill is triggered. The skill folder holds 8 other files, including scripts and reference files (for example `CHANGELOG.md`, `references/douyin-nocookie-approach.md` and `scripts/download_douyin_note.py`).

It works with YouTube, Bilibili, Douyin and Spotify. The licence is MIT.

Example prompts

  • “Fresh cookies needed”
  • “/universal-media-downloader”

Requirements

  • Python 3

What it can do on your machine

Read from SKILL.md and the folder at commit db2c58c. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 3 files in scripts/ (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python
    • pip
    • brew
    • apt-get

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use pip, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Universal Media Downloader loads about 1.2k tokens when it runs, and up to ~3.9k if it reads all its reference files. Until then it costs about 105 tokens; SKILL.md has 287 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~105
When it runs · the whole SKILL.md, loaded when a task matches
~1.2k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~3.9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: warnings

The automated check found patterns that need a careful read before installing.

  • WarningMentions a credentials file (SSH keys, cloud or package-manager tokens)SKILL.md:106
    - `--cookies-from-browser`(可选,chrome/firefox/safari/edge,与 `--cookies` 互斥)
  • NoteRuns commands with sudoSKILL.md:128
    macOS: `brew install ffmpeg`<br>Linux: `sudo apt-get install ffmpeg` |

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from cat-xierluo/legal-skills at commit db2c58c, republished under its MIT licence (© cat-xierluo). 287 words, ~1,163 tokens.

Download SKILL.mdSave it as .claude/skills/universal-media-downloader/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.
name
universal-media-downloader
description
输入各类视频网站/播客平台链接后,自动下载对应媒体文件并交付给用户。优先使用 yt-dlp 覆盖抖音(Douyin)、B站(Bilibili)、YouTube 等常见视频网站,也可用于可直接暴露音频地址的播客平台(如小宇宙单集链接)。当遇到 403/登录/年龄或地区限制时,支持使用 cookies.txt 重试;对于可能存在 DRM/加密或条款限制的平台(例如部分 Spotify 内容),应提示用户仅下载其有权保存的内容,并在不可下载时建议改用官方离线/导出渠道或提供原始 RSS/直链。抖音视频在 yt-dlp 撞签名墙("Fresh cookies needed")时自动三级 fallback:无登录直连 aweme.snssdk.com/v1/play → 本机浏览器游客 cookie(无需登录抖音)重跑 yt-dlp,全程无感;抖音图文笔记暂不支持自动下载,需手动处理。
homepage
https://github.com/cat-xierluo/legal-skills
author
杨卫薪律师(微信ywxlaw)
version
0.5.2
license
MIT

Universal Media Downloader(通用视频/播客下载)

适用范围

优先覆盖(通常可直接用)

  • 抖音视频:douyin.com、v.douyin.com 等视频链接
  • 抖音图文笔记:暂不支持自动下载(反爬限制),需手动截图
  • B站:bilibili.com、b23.tv 等
  • YouTube:youtube.com、youtu.be
  • 以及其它 yt-dlp 支持的网站(数量很多)

播客平台

  • 小宇宙(单集/节目页):多数情况下可直接下载音频(yt-dlp 通常能用)
  • 其它播客平台:如果页面可解析出音频直链,通常也能下载

合规提示:仅用于下载你有权保存的内容(例如你自己上传/拥有版权/获得授权/平台允许离线的内容)。遇到 DRM/加密或平台限制时,不要尝试绕过。

快速开始

1)下载视频(默认)
  • 命令:

    • python scripts/download_media.py "<URL>"
  • 默认保存目录:

    • 用户主目录下的 ~/Downloads/(不再自包含,方便日常访问;见 DEC-004)
    • 可通过 --out-dir 参数自定义输出路径
2)只下载音频(适合播客 / 只想要 MP3)
  • 命令:
    • python scripts/download_media.py --audio-only --audio-format mp3 "<URL>"
3)遇到 403 / 需要登录 / 风控拦截:用 cookies 重试

更省事(推荐)——直接读浏览器 cookies:

  • 用户已在浏览器(Chrome/Firefox/Safari/Edge)登录过该站点的话,直接指定浏览器,免手动导出:
    • python scripts/download_media.py --cookies-from-browser chrome "<URL>"
    • 适用:B站 412、YouTube 年龄限制、抖音带登录态等

或手动导出 cookies.txt(Netscape 格式):

  • 让用户导出 cookies.txt,然后重试:
    • python scripts/download_media.py --cookies "/path/to/cookies.txt" "<URL>"

--cookies 与 --cookies-from-browser 互斥,二选一。抖音视频无需手动传 cookie——脚本会自动走三级 fallback(见下文「平台差异」),其中最后一环就是自动带本机浏览器游客 cookie 重试(无需登录抖音)。

4)需要代理(可选)
  • 例如:
    • --proxy "socks5://127.0.0.1:7890"
5)指定下载路径
  • 用户可通过自然语言指定保存位置,AI 应自动转换为 --out-dir 参数
  • 示例:
    • 用户说"下载到桌面" → --out-dir ~/Desktop
    • 用户说"保存到 Videos/bilibili" → --out-dir "~/Videos/bilibili"
    • 用户说"下载到这个文件夹"(指定某路径)→ 使用用户指定的绝对路径
  • 注意:确保目标目录存在,如不存在可自动创建

平台差异与限制(重要)

  • YouTube / B站:

    • 常见失败原因:年龄限制、地区限制、频繁请求触发风控、需要登录
    • 处理方式:cookies、代理、或降低并发/等待后重试
    • YouTube 额外提示:若出现 Signature solving failed / JS challenge 警告,可按 yt-dlp 的 EJS 指引启用挑战求解组件(例如加 --remote-components ejs:github),或让用户提供 cookies
  • 抖音视频(三级自动 fallback,v0.3.0 起 / v0.5.0 增强):

    • 抖音 www.douyin.com 业务 API 已全上 a_bogus/msToken 签名墙,yt-dlp 直接下会报 Fresh cookies are needed。
    • 「抖音域名 + 用户未显式传 cookie」且 yt-dlp 失败时,自动按序补救:
      1. 无登录直连(v0.3.0,仅视频):短链 → SSR share 页提 video_id → aweme.snssdk.com/aweme/v1/play/ 拿 302 CDN 直链 → 带 referer 下载,无需 cookie/签名。
      2. 浏览器游客 cookie 重试(v0.5.0,音视频均可):自动依次从本机 chrome、safari 读一份游客 cookie(s_v_web_id 等访问 cookie,无需登录抖音)重跑 yt-dlp,即可过 "Fresh cookies are needed" 校验。
    • 边界:仅公开视频;私密/仅好友可见、已删除、异地限制、直播/直播回放、图文笔记均不适用(图文走 download_douyin_note.py)。浏览器 cookie 读取失败(如 Chrome 正在运行占用/无该浏览器)时自动换下一个,全失败则回显 yt-dlp 原始报错。
    • 无登录直链有效期约 1-2 小时,过期重跑即可。SSR share 页自 2026-08-30 起已对无 cookie 请求停止渲染 play_addr(监控信号 #2 命中,风控返回壳页),当前主力通道是游客 cookie;演进记录见 references/douyin-nocookie-approach.md。
  • Spotify:

    • Spotify 上的内容可能存在 DRM、账号权限/订阅限制,且“下载”可能违反平台条款。
    • 本 skill 不保证 Spotify 链接一定可下载。
    • 可行替代:
      • 使用官方离线功能(若平台提供)
      • 提供该播客的 RSS/音频直链(如果你拥有/可获得),再用本脚本下载

Bundled scripts

  • scripts/download_media.py

    • 基于 yt-dlp 的通用下载器
    • 输出:成功时最后一行 SAVED_FILEPATH=...
    • AI 使用指引:当用户指定保存路径时,自动使用 --out-dir 参数
    • 参数:
      • url(必填)
      • --audio-only / --audio-format
      • --subtitles(可选,自动下载字幕)
      • --sub-lang(可选,字幕语言,默认 all)
      • --cookies(可选)
      • --cookies-from-browser(可选,chrome/firefox/safari/edge,与 --cookies 互斥)
      • --proxy(可选)
      • --out-dir(可选,自定义输出目录)
  • scripts/download_douyin_note.py

    • 抖音图文笔记图片下载器(视频流接口对图文只返回首图,故图文单独走图片提取)
    • 注意:其依赖的旧版 iteminfo API 已被抖音加 encrypt_data_miss 拦截,当前提取能力有限,必要时手动截图
  • scripts/download_douyin_video_nocookie.py

    • 抖音视频无登录直连下载器(aweme.snssdk.com/v1/play,无需 cookie/签名)
    • download_media.py 在抖音 yt-dlp 失败时会自动调用它;也可独立使用
    • 输出同样以 SAVED_FILEPATH= 结尾,便于下游脚本(cubox/content-manager)解析
    • 参数:url(必填)、--out-dir、--ratio(540p/720p/1080p,默认 540p)、--out-name
    • 原理与边界见 references/douyin-nocookie-approach.md

依赖

系统依赖
依赖安装方式
yt-dlppip install yt-dlp
ffmpeg(可选,用于字幕提取和音频转换)macOS: brew install ffmpeg<br>Linux: sudo apt-get install ffmpeg
aria2c(可选,抖音 fallback 大文件多线程加速 + 断点续传;未安装自动回退单线程)macOS: brew install aria2
Python 包

无需额外 Python 依赖,yt-dlp 已包含所需库。 抖音相关脚本(download_douyin_*.py)额外依赖 requests(pip install requests)。

© cat-xierluo, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 6 other files (scripts, references) in skills/universal-media-downloader of cat-xierluo/legal-skills.

  • SKILL.md
  • CHANGELOG.md
  • LICENSE.txt
  • references/douyin-nocookie-approach.md
  • scripts/download_douyin_note.py
  • scripts/download_douyin_video_nocookie.py
  • scripts/download_media.py

Open the folder on GitHubat commit db2c58c

Compare with similar skills

Universal Media Downloader next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Universal Media Downloader compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Universal Media Downloader this skillcat-xierluo/legal-skills720—~1.2kAutomated safety check: WarnMIT
Video To Subtitle Summaryimlewc/video-to-subtitle-summary-skill218—~4.6kAutomated safety check: NotesMIT
Video Podcast MakerAgents365-ai/video-podcast-maker1.7k—~4.9kAutomated safety check: PassMIT
Video To NotesKIRVO-REPORTING/video-to-notes105—~1.5kAutomated safety check: PassMIT
Video Copy AnalyzerALBEDO-TABAI/video-copy-analyzer209—~1.9kAutomated safety check: PassMIT
Video To Notelike-attract/video-to-note124—~1kAutomated safety check: PassMIT

Similar skills

  • Video To Subtitle Summary

    imlewc/video-to-subtitle-summary-skill

    A skill your agent uses when user provides a short video platform URL or local video/audio file and wants subtitles/AI summary, or when user asks to list their own AI Douyin historical tasks.

    218 GitHub stars~4.6k tokensUpdated 2 mo ago
    Media & CreativeAuto-check: notes
  • Video Podcast Maker

    Agents365-ai/video-podcast-maker

    A skill your agent uses when the user gives a topic and wants an automated topic-driven narrated explainer, podcast, or knowledge-summary video (Bilibili / YouTube / Xiaohongshu / Douyin / WeChat…

    1.7k GitHub stars~4.9k tokensUpdated 10 days ago
    Media & CreativeAuto-check passed
  • Video To Notes

    KIRVO-REPORTING/video-to-notes

    Use immediately for any bare YouTube or YouTube Shorts URL, youtu.be link, Bilibili or b23.tv link, or other video URL; do not ask what the user wants.

    105 GitHub stars~1.5k tokensUpdated 1 mo ago
    Media & CreativeAuto-check passed
  • Video Copy Analyzer

    ALBEDO-TABAI/video-copy-analyzer

    视频文案分析一站式工具。下载在线视频(B站/YouTube/抖音等)、使用FunASR进行高速中文语音转录、 自动校正文稿、并进行三维度综合分析(TextContent/Viral/Brainstorming)。

    209 GitHub stars~1.9k tokensUpdated 1 mo ago
    Agent WorkflowsAuto-check passed
  • Video To Note

    like-attract/video-to-note

    Generate structured, timestamped Markdown notes from videos (Bilibili, Douyin, YouTube, or local media files) using the local VideoToNo service.

    124 GitHub stars~1k tokensUpdated 7 days ago
    Knowledge ManagementAuto-check passed
  • Ray Trend Search

    imraywang/rayskills

    Researches what people are saying about a topic over a recent window across X, Reddit, YouTube and the public web, reporting each source's status with links.

    159 GitHub stars~2.1k tokensUpdated 18 days ago
    Research & ScienceAuto-check passed

More from cat-xierluo/legal-skills

All 62 skills in this repo
  • Elements-Style Complaint Generator

    cat-xierluo/legal-skills

    Converts a lawyer's ordinary complaint or a described case into the Supreme People's Court's elements-style Word template, with layout checks on the result.

    721 GitHub stars~2.6k tokensUpdated yesterday
    Auto-check: notes
  • Lecture Performance Review

    cat-xierluo/legal-skills

    Analyzes raw lecture transcripts for verbal tics, pacing, time use and promise follow-through, with optional slide-by-slide comparison and cross-session tracking.

    721 GitHub stars~2.2k tokensUpdated yesterday
    Auto-check passed
  • De-AI Polish for Chinese Articles

    cat-xierluo/legal-skills

    Detects and rewrites machine-sounding patterns in the body text of Chinese articles while keeping the author's facts, headings and legal terms intact.

    721 GitHub stars~2.9k tokensUpdated yesterday
    Auto-check passed
  • GitHub Star Manager

    cat-xierluo/legal-skills

    Finds GitHub projects mentioned in articles or screenshots and stars them, tracks updates to your starred repos, and builds an HTML dashboard to browse them.

    721 GitHub stars~2k tokensUpdated yesterday
    Auto-check: notes
  • Legal Harness Initializer

    cat-xierluo/legal-skills

    Sets up or incrementally updates AGENTS.md and CLAUDE.md for legal professionals, with a minimal safety baseline and a check that a new session loads and follows the rules.

    721 GitHub stars~2.3k tokensUpdated yesterday
    Auto-check passed
  • Moot Court Simulation Builder

    cat-xierluo/legal-skills

    Chinese-language skill that organizes a case file into a multi-role mock trial with judge, parties and clerk, producing a transcript, issue review and a to-strengthen list.

    721 GitHub stars~1.4k tokensUpdated yesterday
    Auto-check passed

Questions about Universal Media Downloader

What does Universal Media Downloader do?

输入各类视频网站/播客平台链接后,自动下载对应媒体文件并交付给用户。优先使用 yt-dlp 覆盖抖音(Douyin)、B站(Bilibili)、YouTube 等常见视频网站,也可用于可直接暴露音频地址的播客平台(如小宇宙单集链接)。当遇到 403/登录/年龄或地区限制时,支持使用 cookies.txt 重试;对于可能存在 DRM/加密或条款限制的平台(例如部分 Spotify…. Universal Media Downloader is an agent skill from cat-xierluo/legal-skills.

How do I install Universal Media Downloader in Claude Code?

Run `npx skills add cat-xierluo/legal-skills --skill universal-media-downloader -a claude-code`. Or copy the skill folder (skills/universal-media-downloader in cat-xierluo/legal-skills) into .claude/skills/universal-media-downloader in your project. Claude Code loads it when a task matches its description.

How do I install Universal Media Downloader in Codex?

Run `npx skills add cat-xierluo/legal-skills --skill universal-media-downloader -a codex`. Or copy the skill folder (skills/universal-media-downloader in cat-xierluo/legal-skills) into .agents/skills/universal-media-downloader in your project. Codex loads it when a task matches its description.

Can I use Universal Media Downloader in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add cat-xierluo/legal-skills --skill universal-media-downloader -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/universal-media-downloader, .gemini/skills/universal-media-downloader, .github/skills/universal-media-downloader and .opencode/skills/universal-media-downloader in your project.

What does Universal Media Downloader need to run?

Going by SKILL.md and its folder, Universal Media Downloader needs Python for the scripts in its folder and the command-line tools its instructions call (python, pip, brew and apt-get). Our summary lists: Python 3.

Does Universal Media Downloader access the network?

SKILL.md contains no URLs. Its commands use pip, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Universal Media Downloader safe to install?

Our automated static check of SKILL.md flagged 1 warning(s): mentions a credentials file (ssh keys, cloud or package-manager tokens). Read the flagged lines before installing; the check is not a guarantee either way. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Universal Media Downloader use?

Universal Media Downloader is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Universal Media Downloader use?

About 1.2k tokens (SKILL.md is roughly 4.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 2.7k tokens, read only when the agent opens those files.

What are the alternatives to Universal Media Downloader?

Skills that share tags, products or a category with Universal Media Downloader: Video To Subtitle Summary (imlewc/video-to-subtitle-summary-skill, 218 stars), Video Podcast Maker (Agents365-ai/video-podcast-maker, 1.7k stars), Video To Notes (KIRVO-REPORTING/video-to-notes, 105 stars) and Video Copy Analyzer (ALBEDO-TABAI/video-copy-analyzer, 209 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Universal Media Downloader?

cat-xierluo (a GitHub user) maintains it in cat-xierluo/legal-skills, which has 720 GitHub stars. The repository holds 62 skills in this directory. The repository was last updated on October 10, 2026.

Source: cat-xierluo/legal-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.