ximalaya-audio-assistant

Ximalaya audio content management skill: Browser automation implemented as a Node.js script wrapped around AgentBrowserController, supporting audio upload and publishing actions (including title, description, cover image, tags, topics, discussion cards, privacy settings, AI-generated markers, scheduled publishing, etc.). Triggered when the user mentions “Ximalaya” together with “upload/publish/audio/sound/program,” and depends on the agent-browser CLI and a logged-in Ximalaya account.

Installation

Review the source and dependencies with a prompt. A package is available to download.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "ximalaya-audio-assistant" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-bbcd81f7c17f2764be1c4e87d7573745c2acd81d4ceb1d4802e026cf4076b1db. Verify the upstream source and version against https://skillhub.cn/skills/user_c354bc8c/ximalaya-audio-assistant before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Source and setup

skillhub.cn

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

Ximalaya audio content management skill: Browser automation implemented as a Node.js script wrapped around AgentBrowserController, supporting audio upload and publishing actions (including title, description, cover image, tags, topics, discussion cards, privacy settings, AI-generated markers, scheduled publishing, etc.). Triggered when the user mentions “Ximalaya” together with “upload/publish/audio/sound/program,” and depends on the agent-browser CLI and a logged-in Ximalaya account.

0 Downloads

Introduction source: third_party · user_c354bc8c · 1.0.1 Reference

SkillPi interpretation

Tasks
Translation pending; see source documentation.
Software, accounts and paid services
Translation pending; see source documentation.
Testing
Not tested

Browse files

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: ximalaya-assistant
label: 喜马拉雅助手
description: >
  喜马拉雅音频内容管理技能,基于 AgentBrowserController 封装的 Node.js 脚本实现浏览器自动化。
  支持音频上传发布(标题、简介、封面图片、标签、话题、讨论卡片、私有设置、AI生成标记、定时发布等)。
  当用户提到"喜马拉雅"与"上传/发布/音频/声音/节目"时触发。依赖 agent-browser CLI 和已登录的喜马拉雅账号。
agent_created: true

喜马拉雅助手

1 鉴权说明

助手需要 appid 和 secret 才能连接远程工作流服务。两种提供方式:

  1. 命令行参数:--appid <id> --secret <密钥>
  2. 环境变量:export XIMALAYA_APPID=xxx XIMALAYA_SECRET=xxx

两者都未提供时,脚本直接报错退出并提示用法。

关于测试账号

试用可直接用下面的公共测试账号(无需自己申请): --appid "alex-daily" \ --secret "624adc2a4524373d6ad75bff58aadd59bfd4862f7486b263e7626227ddf65960"

⚠️ 注意:该测试账号为多人共用,配额限制为每天 10 次(自然日 UTC+8 零点重置)。超量会返回 429,请省着点用。

2. 概览

2.1 核心文件:

  • scripts/AgentBrowserController.js — 浏览器自动化控制器类,封装 agent-browser CLI 的所有操作
  • scripts/upload.js — 上传发布入口脚本:解析命令行参数 → 启动浏览器 → 拉取工作流 → 执行上传流程
  • scripts/workflow-runner.js — 工作流执行引擎:从远程拉取声明式 JSON 工作流,逐条映射到 AgentBrowserController 的方法并执行

2.2 前置依赖

  1. agent-browser CLI — 已安装并可在命令行执行 agent-browser 命令。如未安装,先加载 agent-browser-core 技能。
  2. Node.js 18+ — 需要 util.parseArgs 支持(Node 18.3+ 内置)。
  3. 浏览器 — Playwright Chromium 或系统 Edge,脚本会自动查找并启动带 --remote-debugging-port=9222 的实例。
  4. 喜马拉雅登录态 — 首次使用需手动在浏览器中扫码登录,登录后脚本使用 .browser-data 目录保持会话。推荐传入 --browser-data 指定工作空间下的共享目录,避免重复登录。

3. 上传发布

3.1 命令行用法

node scripts/upload.js <专辑名> <音频文件路径> [options]

必选位置参数:

参数 说明
<专辑名> 要上传到的专辑名称(用于搜索选择)
<音频文件路径> 本地音频文件绝对路径

可选 options:

选项 类型 默认值 说明
--title <标题> string '' 声音标题
--desc <简介> string '' 节目简介(多行需将换行符改为 <br>)
--imagePath <图片路径> string '' 封面图片绝对路径
--tags <标签> string '' 标签,多个用英文逗号分隔
--topic <话题> string '' 话题关键词
--discussion <讨论> string '' 讨论主题
--private boolean false 标记为私有(出现即 true)
--ai boolean false 标记为AI生成(出现即 true)
--schedule <时间> string '' 定时发布时间(格式: 2026-07-12 18:01,HH:mm 24h制)
--browser-data <目录> string ./.browser-data 浏览器用户数据目录(共享登录态)
--appid <id> string XIMALAYA_APPID 环境变量 鉴权 appid(必填,未提供则报错退出)
--secret <密钥> string XIMALAYA_SECRET 环境变量 本地签名密钥,生成 HMAC token 不传输(必填,未提供则报错退出)
-h, --help boolean — 显示帮助

3.2 使用示例

node scripts/upload.js "长城内外的故事" "D:/audio/ep01.mp3" \
  --title "第一集:山海关" \
  --desc "从山海关讲起,追溯长城防御体系的起源" \
  --imagePath "D:/audio/cover01.jpg" \
  --tags "历史,长城,故事" \
  --topic "长城" \
  --discussion "长城防御体系是智慧还是劳民伤财?" \
  --ai \
  --schedule "2026-07-12 18:01" \
  --private \
  --browser-data "D:/资料/claw/世界杯人物记/.browser-data" \
  --appid "alex-daily" --secret "your-secret-here"

3.3 执行流程

upload.js 执行以下步骤:

  1. 启动浏览器(CDP connect 到 Playwright Chromium)
  2. 打开喜马拉雅上传页面
  3. 上传音频文件
  4. 选择专辑(搜索专辑名 → 点击匹配结果)
  5. 填充标题(--title)
  6. 上传封面图片(--imagePath,如提供)
  7. 填充节目简介(KindEditor iframe:frame 切入 → fill body → finally 切回)
  8. 滚动到页面底部
  9. 填充标签(逗号分隔逐个输入 + Enter)
  10. 添加话题(如提供)/ 填充讨论(如提供)
  11. 勾选AI生成(--ai,如提供)
  12. 设置定时发布(--schedule,如提供)
  13. 点击"确认发布"按钮

3.4 在 WorkBuddy 中使用

当用户说"帮我上传音频到喜马拉雅"时:

  1. 确认必选信息:专辑名、音频文件路径。如缺少,用 AskUserQuestion 询问。
  2. 可选信息(标题、简介、封面图片、标签、话题、讨论、私有、AI生成、定时发布):如用户提供则带上,否则使用默认值。
  3. 将 scripts/ 下全部文件(upload.js、workflow-runner.js、AgentBrowserController.js)复制到用户工作目录(或直接在 skill 目录下运行)。
  4. 推荐:传入 --browser-data 指向工作空间下的 .browser-data 目录,共用登录态。
  5. 执行命令:node scripts/upload.js "<专辑名>" "<文件路径>" [options]
  6. 脚本输出步骤进度,完成后返回 { success: true } 或 { success: false, error: "..." }。
  7. 如失败,根据错误信息排查(参见 references/ 文档)。

4. AgentBrowserController API 速查

上传脚本之外,如需编写自定义流程(编辑、删除等),可导入 AgentBrowserController 类:

import AgentBrowserController from './AgentBrowserController.js';

const controller = new AgentBrowserController({
  sessionId: 'default',
  debug: true,
  cdpPort: 9222,
  // userDataDir: '自定义浏览器数据目录'  // 默认 ./.browser-data
});

await controller.launchBrowser();
await controller.navigate('https://www.ximalaya.com/...');
const snapshot = await controller.getSnapshot();
await controller.click('input[placeholder*="标题"]');
await controller.fill('input[placeholder*="标题"]', '标题文本');
await controller.fillKindEditor('#iframe_id', '简介内容');
await controller.type('input[placeholder*="回车"]', '标签');
await controller.press('Enter');
await controller.uploadFile('D:/audio/ep01.mp3');
await controller.eval('document.title');
await controller.switchToFrame('#iframe_id');  // 或 'main' 切回
await controller.scrollToBottom();
await controller.screenshot('/output/screenshot.png');
await controller.findAndClick(snapshot, '确认发布', { exact: false, role: 'button' });
await controller.closeBrowser();

关键方法说明:

方法 说明
launchBrowser() CDP connect 到 Chromium,端口未监听则自动启动
navigate(url) 导航并等待 2s
getSnapshot() snapshot -i --json,返回 { elements: [{ref, tag, text, attrs}], raw }
click(ref) 点击元素(ref 或 CSS 选择器)
fill(ref, text) 清空并填入文本
type(ref, text) 逐字符输入(触发 keydown/keyup)
fillKindEditor(ref, text) KindEditor iframe 专用:切入 frame → fill body → finally 切回 main
press(key) 按键(如 'Enter', 'Tab')
uploadFile(filePath) snapshot 找 file input → upload
eval(jsCode) 执行 JS 并返回结果
switchToFrame(refOrName) 切换 frame 上下文('main' 切回主文档)
findAndClick(snapshot, text, options) 按文本匹配元素并点击

Current listing version

1.0.1

Verify the source revision ↗

Safety and assessment details

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value85/100

Highlights

  • 提供喜马拉雅音频上传发布的完整自动化能力,支持标题、简介、封面、标签、话题、讨论卡片、私有设置、AI生成标记、定时发布等功能
  • 解决内容创作者的实际痛点,实用价值高,受众明确
Trigger Precision80/100

Highlights

  • 触发词描述清晰,覆盖'喜马拉雅'与'上传/发布/音频/声音/节目'等关键词,边界合理
Structure and Standards95/100

Highlights

  • 文档结构完整,包含鉴权、概览、依赖、详细流程、示例、API 速查等
  • 步骤清晰,有端到端示例,frontmatter 完整,符合规范
Execution Reliability90/100

Highlights

  • 工具来源明确,参数说明详细,覆盖主要异常场景
  • 依赖项清晰,不可逆操作有明确流程,可靠性高
Evidence Verifiability (mean of the first four)88/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

Domains or addresses referenced in the document

These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.

  • www.ximalaya.com

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

safe · Static evidence review; not a runtime safety guarantee.

Translation pending; see source documentation.

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.