← Back to Skills Marketplace
xbos1314

bilibili-yt-dlp

by 深柒 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
340
Downloads
1
Stars
1
Active Installs
1
Versions
Install in OpenClaw
/install bilibili-yt-dlp
Description
使用 yt-dlp 和 ffmpeg 下载哔哩哔哩视频。
README (SKILL.md)

哔哩哔哩视频下载器

描述

一个用于下载哔哩哔哩视频的技能,使用 yt-dlp 下载,并使用 ffmpeg 合并音视频。

何时使用

在需要以下操作时使用此技能:

  • 下载哔哩哔哩视频 (b23.tv/xxx 或 bilibili.com/video/xxx)
  • 从哔哩哔哩网页提取视频
  • 保存带音频的哔哩哔哩视频

前置要求

  • 安装 yt-dlp:pip3 install yt-dlp
  • 安装 ffmpeg:

使用方法

方法 1: 使用 yt-dlp(推荐)

# 查看可用格式
yt-dlp --list-formats "https://www.bilibili.com/video/BVxxxx"

# 下载最佳画质(4K/1080P60 可能需要大会员)
yt-dlp -f "best" -o "/path/to/video.mp4" "URL"

# 下载指定格式(视频+音频)
yt-dlp -f "30064+30216" -o "/path/to/video.mp4" "URL"

格式代码

画质 视频ID 音频ID 分辨率
720P 30064 30216 720x1280
480P 30032 30216 480x852
360P 30016 30216 360x640

方法 2: 使用浏览器手动下载

  1. 在浏览器中打开哔哩哔哩链接:
browser action=open url="https://b23.tv/xxxxxx"
  1. 使用浏览器控制台提取视频 URL:
// 从 window.__playinfo__ 获取
var playinfo = window.__playinfo__;
JSON.stringify(playinfo);
  1. 分别下载视频和音频,然后使用 ffmpeg 合并:
ffmpeg -i video.mp4 -i audio.m4a -c copy -y output.mp4

示例

示例 1: 使用 yt-dlp 下载(带 ffmpeg 合并)

# 先分别下载视频和音频
yt-dlp -f "30064+30216" -o "/Users/xbos1314/Documents/openclaw/file/video.%(ext)s" "https://www.bilibili.com/video/BV1EVZyBvEDu"

# 这将下载两个文件:视频和音频
# 然后使用 ffmpeg 合并(如果 yt-dlp 没有自动合并)
ffmpeg -i video.f30064.mp4 -i video.f30216.m4a -c copy -y output.mp4

示例 2: 简单下载(可能不适用于大会员专属内容)

yt-dlp -o "/Users/xbos1314/Documents/openclaw/file/video.mp4" "https://www.bilibili.com/video/BVxxxx"

注意事项

  • 部分视频需要哔哩哔哩大会员才能下载高清画质(4K、1080P60)
  • 格式选择:使用视频+音频格式代码以确保包含音频
  • 默认输出目录:你的工作空间
  • 视频 URL 有时效限制,可能会过期
  • 如需认证,使用 --cookies-from-browser 或 --cookies
  • 下载完成后使用 browser action=close 关闭浏览器标签页
  • 下载完成后将视频发送给用户 发送成功后删除视频文件

技术细节

  • 使用 yt-dlp 下载哔哩哔哩视频
  • 使用 ffmpeg 合并分离的视频和音频流
  • 需要选择正确的格式以获得最佳效果
  • 720P (30064+30216) 推荐给非大会员用户使用
Usage Guidance
This skill appears to do what it says (use yt-dlp + ffmpeg to download Bilibili videos). Before installing or letting an agent run it, consider: 1) The SKILL.md suggests using --cookies-from-browser and browser actions — that can expose your browser cookies and logged-in sessions; only allow this if you trust the agent and understand which browser profile will be accessed. 2) If you prefer more control, install yt-dlp and ffmpeg yourself and run the shown commands manually rather than giving an agent permission to open pages or extract cookies. 3) Be aware of legal/terms-of-service implications for downloading content (especially paywalled content). 4) If you must use cookie-based auth, limit which browser/profile is used and avoid sharing full browser session data. If you want me to, I can point out exact command lines to run locally instead of enabling the skill to act autonomously.
Capability Analysis
Type: OpenClaw Skill Name: bilibili-yt-dlp Version: 1.0.0 The skill bundle provides instructions and commands for downloading Bilibili videos using standard tools like yt-dlp and ffmpeg. While it contains hardcoded absolute file paths (e.g., /Users/xbos1314/Documents/openclaw/file/video.mp4) in the examples, which is a poor practice, the logic is entirely consistent with its stated purpose. There are no signs of data exfiltration, malicious execution, or harmful prompt injection against the agent in SKILL.md.
Capability Assessment
Purpose & Capability
Name/description (download Bilibili with yt-dlp and ffmpeg) align with the instructions: yt-dlp and ffmpeg usage, format codes, and merge steps are all directly relevant.
Instruction Scope
Instructions are largely scoped to downloading and merging streams. However they include browser actions (open/close tab) and advise using --cookies-from-browser and reading window.__playinfo__ from the page — actions that access browser session data and could expose cookies or auth state. Those steps are related to the stated purpose but broaden what the agent will read/use (browser cookies and page JS).
Install Mechanism
No install spec in the registry; the SKILL.md recommends installing yt-dlp via pip and ffmpeg via package manager or official site — these are reasonable and expected for the stated functionality, and no arbitrary downloads or unknown URLs are provided.
Credentials
The skill declares no required env vars or config paths but instructs use of --cookies-from-browser and browser console extraction. This implies access to browser cookie stores / session data that isn't declared as required credentials — a mismatch and a potential privacy/credential exposure risk.
Persistence & Privilege
The skill is instruction-only, has no install spec, does not request permanent presence (always:false). Autonomous invocation is allowed (platform default) but not by itself a red flag here.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install bilibili-yt-dlp
  3. After installation, invoke the skill by name or use /bilibili-yt-dlp
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
bilibili-yt-dlp 1.0.0 初始版本 - 提供哔哩哔哩视频下载教程,基于 yt-dlp 与 ffmpeg。 - 包含格式选择及合并音视频的详细操作指南。 - 支持基础与进阶两种下载方式,适配不同需求。 - 补充常见问题提醒及常用格式代码表。 - 明确依赖要求及安装指引。
Metadata
Slug bilibili-yt-dlp
Version 1.0.0
License MIT-0
All-time Installs 1
Active Installs 1
Total Versions 1
Frequently Asked Questions

What is bilibili-yt-dlp?

使用 yt-dlp 和 ffmpeg 下载哔哩哔哩视频。 It is an AI Agent Skill for Claude Code / OpenClaw, with 340 downloads so far.

How do I install bilibili-yt-dlp?

Run "/install bilibili-yt-dlp" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is bilibili-yt-dlp free?

Yes, bilibili-yt-dlp is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does bilibili-yt-dlp support?

bilibili-yt-dlp is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created bilibili-yt-dlp?

It is built and maintained by 深柒 (@xbos1314); the current version is v1.0.0.

💬 Comments