Token导航 LogoToken导航TokenDH.com
研究检索操作浏览器github未标认证来源可访问许可证需确认审计提醒

bilibili-clibilibili CLI 搜索

Agent Skill

bilibili-cli 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

7,344

周安装

306

GitHub Stars

710

下载量

2,448
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:bilibili-cli(bilibili CLI 搜索)
来源仓库:https://github.com/jackwener/bilibili-cli
仓库路径:skills/bilibili-cli
安装命令:
npx skills add https://github.com/jackwener/bilibili-cli --skill bilibili-cli
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/jackwener/bilibili-cli --skill bilibili-cli

简介

bilibili-cli 用于查找、检索和筛选 B 站视频、用户信息及相关内容,适合在 Codex、Claude、Cursor、Gemini CLI 中快速定位候选结果。

  • 适用于关键词搜索、视频信息获取、用户资料浏览等场景,支持 YAML/JSON 输出与分页控制。
  • 通过 npx skills add 命令从 GitHub 安装,需确认权限与维护状态,避免触发不必要的联网或文件操作。
  • 使用前建议核对目标功能是否需要 Cookie,并注意命令参数以控制结果集大小与格式。
  • 涉及登录或敏感数据时,应先获得用户授权并妥善处理凭据。

SKILL.md

bilibili-cli Skill

A CLI tool for interacting with Bilibili (哔哩哔哩). Use it to fetch video info, search content, browse user profiles, and perform interactions like liking or triple-clicking.

Agent Defaults

When you need machine-readable output:

  1. Prefer --yaml first because it is usually more token-efficient than pretty JSON.
  2. Use --json only when downstream tooling strictly requires JSON.
  3. Keep result sets small with --max, --page, or --offset.
  4. Prefer specific commands over broad ones. Example: use bili user-videos 946974 --max 3 --yaml instead of fetching large timelines.
  5. When summarizing a video, fetch subtitles first. Subtitles usually contain the video's core content and are the best primary source for summaries.
  6. Only fall back to --ai, comments, or audio extraction when subtitles are unavailable or clearly insufficient.

Prerequisites

# Install (requires Python 3.10+)
uv tool install bilibili-cli
# Or: pipx install bilibili-cli

# If you need audio extraction support (requires PyAV)
uv tool install "bilibili-cli[audio]"
# Or: pipx install "bilibili-cli[audio]"

# Upgrade to latest (recommended to avoid API errors)
uv tool upgrade bilibili-cli
# Or: pipx upgrade bilibili-cli

Authentication

Most read commands work without login. Subtitles, favorites/following/watch-later/history, feed, and interactions require login.

bili status                    # Check if logged in (exit 0 = yes, 1 = no)
bili login                     # QR code login (if not authenticated)

Authentication auto-detects local browser cookies (Chrome/Firefox/Edge/Brave). If cookies are found and valid, no manual login needed. Credentials are saved to ~/.bilibili-cli/credential.json.

Command Reference

Video

# Get video details (accepts BV ID or full URL)
bili video BV1ABcsztEcY
bili video https://www.bilibili.com/video/BV1ABcsztEcY

# Options
bili video BV1ABcsztEcY --subtitle            # Show subtitles (plain text)
bili video BV1ABcsztEcY --subtitle-timeline   # Show subtitles with timestamps
bili video BV1ABcsztEcY -st --subtitle-format srt  # Export as SRT format
bili video BV1ABcsztEcY --ai            # Show B站 AI summary
bili video BV1ABcsztEcY --comments      # Show top comments
bili video BV1ABcsztEcY --related       # Show related videos
bili video BV1ABcsztEcY --yaml          # Token-efficient YAML output
bili video BV1ABcsztEcY --json          # Structured JSON envelope

User

# Look up user profile (by UID or username)
bili user 946974
bili user "影视飓风"

# List user's videos
bili user-videos 946974 --max 20
bili user-videos "影视飓风" --yaml

Search

# Search users (default)
bili search "关键词"

# Search videos
bili search "关键词" --type video

# Pagination and limit
bili search "关键词" --type video --max 5
bili search "关键词" --page 2

Discovery

bili hot                       # Trending/popular videos
bili hot --page 2 --max 10     # Page 2, limit 10
bili rank                      # Site-wide ranking (3-day)
bili rank --day 7 --max 30     # 7-day ranking, top 30
bili feed                      # Dynamic timeline (requires login)
bili feed --offset 1234567890  # Next page via returned cursor
bili my-dynamics               # My posted dynamics (requires login)
bili dynamic-post "hello"      # Publish text dynamic (requires write credential)
bili dynamic-delete 123456789  # Delete one dynamic (requires write credential)

Collections (require login)

bili favorites                 # List favorite folders
bili favorites <ID> --page 2   # Videos in a folder
bili following                 # Following list
bili watch-later               # Watch later list
bili history                   # Watch history

Audio Extraction

Requires bilibili-cli[audio] extra (PyAV). Install with uv tool install "bilibili-cli[audio]".

# Download audio and split into ASR-ready WAV segments (25s each, 16kHz mono)
bili audio BV1ABcsztEcY                 # Split to /tmp/bilibili-cli/{title}/
bili audio BV1ABcsztEcY --segment 60    # 60s per segment
bili audio BV1ABcsztEcY --no-split      # Full m4a file, no splitting
bili audio BV1ABcsztEcY -o ~/data/      # Custom output directory

Interactions (require login)

bili like BV1ABcsztEcY         # Like a video
bili like BV1ABcsztEcY --undo  # Unlike
bili coin BV1ABcsztEcY         # Give 1 coin
bili coin BV1ABcsztEcY -n 2    # Give 2 coins
bili triple BV1ABcsztEcY       # 一键三连 (like + coin + favorite)
bili unfollow 946974           # Unfollow by UID

Account

bili status                    # Quick login check
bili status --yaml             # Structured auth status
bili whoami                    # Detailed profile info
bili whoami --yaml              # Profile as YAML
bili whoami --json              # Profile as JSON
bili login                     # QR code login
bili logout                    # Clear credentials

Structured Output

Major query commands support both --yaml and --json for machine-readable output. Prefer YAML for agent use:

bili status --yaml                                # Quick structured auth check
bili video BV1ABcsztEcY --yaml                       # Preferred for AI agents
bili hot --max 5 --yaml                             # Smaller, token-efficient payload
bili user 946974 --json | jq -r '.data.user.name'   # JSON when jq is needed

When stdout is not a TTY, bilibili-cli defaults to YAML automatically. Use OUTPUT=yaml|json|rich|auto to override the default output mode. All machine-readable output uses the envelope documented in SCHEMA.md.

Debugging

bili -v <command>              # Enable verbose/debug logging for any command

Common Patterns for AI Agents

# For video summarization, fetch subtitles first
bili video BV1ABcsztEcY --subtitle

# Only use AI summary as a fallback or secondary signal
bili video BV1ABcsztEcY --ai

# Get comments for sentiment analysis
bili video BV1ABcsztEcY --comments

# Extract audio for speech-to-text (ASR)
# Segments are saved to /tmp/bilibili-cli/{title}/seg_000.wav, seg_001.wav, ...
bili audio BV1ABcsztEcY --segment 25

# Find a user's latest video BV ID with minimal payload
bili user-videos 946974 --max 1 --yaml

# Check if logged in before performing actions
bili status && bili like BV1ABcsztEcY

# Search and inspect the first few results
bili search "topic" --type video --max 3 --yaml

Workflow: Video Content Analysis

# 1. Search for a topic
bili search "AI" --type video --max 5

# 2. Get subtitles first for summarization
bili video BV1xxx --subtitle

# 3. If subtitles are missing or incomplete, try AI summary
bili video BV1xxx --ai

# 4. If there is still not enough content, extract audio for ASR
bili audio BV1xxx --segment 25

# 5. Get comments for audience reaction
bili video BV1xxx --comments

Workflow: UP主 Research

# 1. Look up UP主 profile
bili user "影视飓风"

# 2. Get their recent videos
bili user-videos 946974 --max 10

# 3. Inspect a specific video
bili video BV1xxx --ai --comments

Error Handling

  • Commands exit with code 0 on success, non-zero on failure
  • Error messages are prefixed with ❌
  • Login-required commands show ⚠️ with instruction to run bili login
  • Invalid BV IDs show a clear error message

Safety Notes

  • Do not ask users to share raw credential/cookie values in chat logs.
  • Prefer local browser cookie extraction over manual secret copy/paste.
  • If auth fails, ask the user to re-login via bili login.

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

33.73%
按下载量换算826

Claude

30.86%
按下载量换算755

Cursor

18.74%
按下载量换算459

Gemini CLI

9.39%
按下载量换算230

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills