SkillAtlasSkill 详情

baoyu-post-to-wechat

收录最全、更新最快的AI Agent技能库,涵盖文档处理、内容创作、编程开发、机器学习、自动化工作流等多个领域的精选技能包。

审核状态:已审核Quality 72Security 70

复制安装命令

用 Codex 或 Claude 安装复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它先审查 Skill 页面再帮你安装。

复制前请先查看来源、License 和安全提示。

项目 README

来源文件:README.md

抓取于 2026年8月3日

🎯 技能商店 - Skill Store

Stars Forks Last Commit Issues License Auto Sync

收录最全、更新最快的AI Agent技能库,涵盖文档处理、内容创作、编程开发、机器学习、自动化工作流等多个领域的精选技能包。

官方技能 本地技能 备份覆盖 自动更新

📊 统计数据

  • 官方技能: 182 个(来自 awesome-agent-skills,自动爬取)
  • 本地技能: 62 个(26核心 + 30子技能 + 6系统内置)
  • 技能总数: 244 个(官方 + 本地)
  • 备份覆盖率: 100%(71个压缩包,完整备份)
  • 自动更新: 每24小时自动爬取最新技能

🌟 核心特性

🤖 自动更新

每24小时自动爬取 awesome-agent-skills 仓库,确保技能库始终保持最新状态。

📦 双重技能库

  • 官方技能:182个来自Anthropic、Vercel、Cloudflare、Google Labs、Hugging Face等顶级团队
  • 本地技能:62个精选中文技能,涵盖内容创作、视频制作、电商营销等垂直领域

🏷️ 智能分类

按照功能、来源、Star数量等多维度标签进行分类整理。

📊 数据导出

支持JSON和CSV格式导出,方便数据分析和二次开发。

📚 官方技能来源

本技能商店收录了来自以下顶级团队的官方技能:

  • Anthropic (17个) - docx, pptx, xlsx, pdf, mcp-builder, webapp-testing 等
  • Vercel (7个) - react-best-practices, next-best-practices, composition-patterns 等
  • Cloudflare (7个) - agents-sdk, durable-objects, wrangler 等
  • Trail of Bits (26个) - building-secure-contracts, static-analysis, property-based-testing 等
  • Hugging Face (8个) - model-trainer, datasets, evaluation, jobs 等
  • Google Labs (2个) - design-md, react-components 等
  • Stripe (2个) - stripe-best-practices, upgrade-stripe
  • Supabase (1个) - postgres-best-practices
  • Expo (3个) - expo-app-design, expo-deployment, upgrading-expo
  • Sentry (7个) - code-review, commit, create-pr, find-bugs 等
  • Better Auth (3个) - best-practices, commands, create-auth
  • 其他团队 - Tinybird, Remotion, Inngest 等

💾 本地技能库(62个)

📝 内容创作与发布(10个)

  • content-creation-publisher ⭐⭐⭐⭐⭐ - 内容创作与发布全流程
  • intelligent-content-system ⭐⭐⭐⭐⭐ - 智能内容系统
  • article-illustrator ⭐⭐⭐⭐ - 文章智能配图
  • baoyu-url-to-markdown ⭐⭐⭐⭐ - 网页转Markdown
  • baoyu-format-markdown ⭐⭐⭐⭐ - Markdown格式化
  • baoyu-post-to-wechat ⭐⭐⭐⭐ - 微信公众号发布
  • baoyu-post-to-x ⭐⭐⭐ - X/Twitter发布
  • baoyu-xhs-images ⭐⭐⭐⭐ - 小红书图文生成
  • wechat-hotspot-publisher ⭐⭐⭐ - 微信热点文章生成

🎬 视频创作(9个)

  • video-creation-suite ⭐⭐⭐⭐⭐ - 完整视频创作套件
  • video-creation-collaborator ⭐⭐⭐⭐ - 多智能体协同视频创作
  • video-creation-pro ⭐⭐⭐ - 商品视频创作系统
  • video-recreation ⭐⭐⭐⭐ - 视频二创工具
  • video-frame-extractor ⭐⭐⭐ - 视频反推工具
  • viral-video-copywriting ⭐⭐⭐⭐ - 爆款短视频文案
  • historical-science-video-prod ⭐⭐ - 历史科学类视频
  • historical-interview-scripts ⭐⭐ - 历史访谈文案
  • three-body-video-creator ⭐⭐ - 《三体》视频创作

🛒 电商与营销(7个)

  • ecommerce-full-pipeline ⭐⭐⭐⭐⭐ - 跨境电商全链路自动化(1688采集/清洗/上架/推广/视频/代发/爆品挖掘/闲鱼选品捡漏)
  • pet-commerce-creator ⭐⭐⭐ - 萌宠带货短视频
  • ecommerce-copywriter ⭐⭐⭐ - 电商图片文案
  • ecommerce-video-marketing ⭐⭐⭐ - 电商视频营销
  • product-marketing-copywriter ⭐⭐⭐ - 产品营销文案
  • product-video-creator ⭐⭐⭐⭐ - 商品视频创作
  • xiaohongshu-makeup ⭐⭐⭐ - 小红书美妆内容

📊 PPT与演示(6个)

  • NanoBanana-PPT-Skills ⭐⭐⭐⭐⭐ - AI生成PPT图片和视频
  • ppt-generator ⭐⭐⭐⭐ - 智能PPT生成
  • pptx-generator ⭐⭐⭐ - JSON转PPTX
  • nanobanana-ppt-visualizer ⭐⭐⭐ - PPT视觉增强
  • ppt-roadshow-generator ⭐⭐ - PPT路演视频
  • remotion-video-enhancer ⭐⭐ - 视频转场动画

🎙️ 语音与音频(3个)

  • tts-voice-synthesis ⭐⭐⭐⭐⭐ - 智能语音合成
  • qwen3-tts-local ⭐⭐⭐⭐ - 本地语音合成(Edge-TTS)
  • qwen3-asr-assistant ⭐⭐⭐⭐ - 语音转文字

🤖 数字人与视频配音(5个)

  • infinitetalk ⭐⭐⭐⭐⭐ - 音频驱动视频配音
  • infinitetalk-shopping-avatar ⭐⭐ - 小省导购员提示词
  • digital-avatar-shopping-video ⭐⭐ - 数字人口播带货
  • dream-video-prompt-generator ⭐⭐ - 即梦视频提示词
  • agentkit-multimedia-shopping ⭐⭐ - 多媒体带货视频

📄 文档与分析(4个)

  • paper-analysis-assistant ⭐⭐⭐⭐ - arXiv论文分析
  • contract-review ⭐⭐⭐ - 合同审核
  • law-to-markdown ⭐⭐ - 法律文档转换
  • stock-analysis ⭐⭐⭐ - 股票个股分析

🤝 智能体协作(3个)

  • agent-team ⭐⭐⭐ - 智能体团队协作
  • multi-agent-meeting ⭐⭐ - 多智能体会议
  • peers-advisory-group ⭐⭐ - 同行顾问团

💼 产品与项目管理(2个)

  • product-manager-toolkit ⭐⭐⭐ - 产品经理工具包
  • sales-ai-assistant ⭐⭐ - 销售AI助手

🎨 设计与可视化(4个)

  • frontend-design ⭐⭐⭐ - 前端界面设计
  • ai-drawio ⭐⭐⭐⭐ - 流程图绘制
  • pop-up-book-illustration ⭐⭐ - 3D纸艺插画
  • web-to-app ⭐⭐ - 网页转桌面应用

📑 文档处理(4个 - 系统内置)

  • pptx ⭐⭐⭐⭐⭐ - PPT文件处理
  • xlsx ⭐⭐⭐⭐⭐ - Excel文件处理
  • pdf ⭐⭐⭐⭐⭐ - PDF文件处理
  • docx ⭐⭐⭐⭐⭐ - Word文件处理

🔧 技能管理(2个 - 系统内置)

  • find-skill ⭐⭐⭐ - 技能发现工具
  • skill-creator ⭐⭐⭐ - 技能创建工具

💰 财务分析(2个)

  • creating-financial-models ⭐⭐⭐⭐ - 财务建模套件
  • market-research-reports ⭐⭐⭐⭐ - 市场研究报告

🎭 文化创作(1个)

  • poetry-music-visual ⭐⭐ - 古诗词配图配乐

🚀 快速开始

1. 克隆仓库

git clone https://github.com/anbeime/skill.git
cd skill

2. 安装依赖

pip install -r requirements.txt

3. 运行更新

# 立即执行一次更新
python main.py --once

# 启动定时更新守护进程
python main.py --daemon

# 显示数据统计
python main.py --stats

# 导出为 CSV 格式
python main.py --export skills.csv

# 详细日志模式
python main.py --once -v

4. 浏览技能

访问 在线技能商店 或查看本地文件:

# 查看官方技能列表
cat data/skills.json

# 查看本地技能列表
cat data/local_skills.json

# 查看技能文档
ls docs/

💾 技能备份

备份位置

  • 主目录: D:\tool\skills\
  • 压缩备份: D:\tool\skills\skill压缩文件\(71个压缩包)
  • 备份覆盖率: 100%

备份说明

  • 所有本地技能均有对应压缩包
  • 系统内置技能(pptx、xlsx、pdf、docx、find-skill、skill-creator)无需压缩包
  • 包含backup标记的文件为历史版本备份

📖 文档

🛠️ 技能验证工具

内置技能验证工具,用于检查 SKILL.md 是否符合规范:

# 验证所有技能
python tools/skill_validator.py validate

# 验证单个技能
python tools/skill_validator.py validate skills/agent-team

# 读取技能属性
python tools/skill_validator.py read-properties skills/agent-team --json

# 生成 XML prompt(用于 AI 调用)
python tools/skill_validator.py to-prompt skills/agent-team

详见 工具文档。

📊 数据格式

skills.json(官方技能)

{
  "skills": [
    {
      "name": "组织名/技能名",
      "description": "技能描述",
      "link": "GitHub链接",
      "category": "分类名称",
      "source": "来源仓库",
      "crawled_at": "2026-02-02T17:07:33"
    }
  ],
  "total": 182,
  "updated_at": "2026-02-02T17:07:33"
}

local_skills.json(本地技能)

{
  "metadata": {
    "total_skills": 61,
    "core_skills": 25,
    "sub_skills": 30,
    "system_builtin": 6,
    "last_updated": "2026-02-11T15:30:00"
  },
  "categories": {
    "内容创作与发布": {...},
    "视频创作": {...},
    ...
  },
  "statistics": {
    "by_api_requirement": {
      "必需API": 15,
      "可选API": 20,
      "完全免费": 26
    }
  }
}

🎯 核心技能推荐

⭐⭐⭐⭐⭐ 五星技能(11个)

  1. content-creation-publisher - 内容创作与发布全流程
  2. intelligent-content-system - 智能内容系统
  3. video-creation-suite - 完整视频创作套件
  4. ecommerce-full-pipeline - 跨境电商全链路自动化(1688采集/上架/推广/视频/代发/爆品挖掘/闲鱼选品)
  5. NanoBanana-PPT-Skills - AI生成PPT
  6. tts-voice-synthesis - 智能语音合成
  7. infinitetalk - 音频驱动视频配音
  8. pptx - PPT文件处理(系统内置)
  9. xlsx - Excel文件处理(系统内置)
  10. pdf - PDF文件处理(系统内置)
  11. docx - Word文件处理(系统内置)

🔗 相关链接

🤝 贡献

欢迎提交 Issue 和 Pull Request!详见 贡献指南。

🤝 贡献你的技能

发现了好用的 AI Agent 技能?欢迎提交!

贡献者

感谢所有为这个项目做出贡献的伙伴:

Contributors

🌐 兄弟项目

📄 许可证

MIT License

🙏 致谢

📝 更新日志

v2.2 (2026-07-29)

  • ✨ 新增 ecommerce-full-pipeline 技能:跨境电商全链路自动化工具
  • 🛒 集成1688采集、数据清洗、多平台上架(微信小店/Shopify/TikTok)、推广方案、短视频创作、一键代发、爆品挖掘、闲鱼选品捡漏、全自动流水线
  • 📊 本地技能从61个增加到62个
  • 🏆 电商与营销分类从6个增加到7个

v2.1 (2026-07-28)

  • 🛠️ 新增技能验证工具 (tools/skill_validator/)
  • 📋 新增技能创建模板 (skills/_template/)
  • 📖 新增规范文档、最佳实践、快速入门
  • 📝 新增贡献指南 (CONTRIBUTING.md)
  • ✅ 验证工具支持双重嵌套目录结构
  • ⚠️ 非标准字段改为警告(兼容社区技能)

v2.0 (2026-02-11)

  • ✨ 新增12个本地技能
  • 📊 本地技能从49个增加到61个
  • 🏷️ 完善技能分类体系(14个分类)
  • 📦 更新技能管理数据库
  • 🔄 更新README和前端页面
  • 📝 添加技能清单文档
  • 🔍 保留182个官方技能数据

v1.0 (2026-02-09)

  • 🎉 初始版本发布
  • 📦 包含182个官方技能
  • 💾 包含49个本地技能
  • 🗂️ 建立技能仓库
  • 🤖 实现自动爬取功能

最后更新: 2026-02-11
维护者: anbeime
联系方式: GitHub Issues

📦 社区技能仓库聚合

此部分由自动化脚本每日从上游源同步更新

最后更新: 2026-08-03T05:29:17.609648 | 技能源总数: 155

数据来源

技能仓库列表

OpenAI Skills

VoltAgent Awesome Agent Skills

ClawHub (Skill Registry)

Latest commit: 4ae5180

Packages

PackageDescription
clawhub-adminclawhub-admin package
clawhubCLI tool for managing skills
schemaShared API types and routes

CLI Commands

CLI

Common CLI flows:

  • Auth: clawhub login, clawhub whoami
  • Remote/headless auth: clawhub login --device
  • Discover: clawhub search ..., clawhub explore
  • Browse unified catalog (skills + plugins): clawhub package explore, clawhub package inspect <name>
  • Manage local installs: clawhub install @openclaw/demo, clawhub pin <skill>, clawhub unpin <skill>, clawhub uninstall <skill>, clawhub list, clawhub update --all
  • Inspect without installing: `clawhub inspect @op
内容与创作

中风险

  • 来源需自行核对维护者身份。
  • 包含脚本或命令调用,安装前请复核。
  • 可能需要外部 token、网络权限或第三方服务。
  • 未检测到高风险命令。
  • 扫描发现:3 条。

Codex — Git Clone 安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 克隆仓库:git clone https://github.com/anbeime/skill.git
  3. 将 "skills/content-creation-publisher/baoyu-post-to-wechat" 文件夹复制到 Codex 的 skills 目录中。
  4. 重启 Codex 让新的 skill 生效。

Codex — 手动复制安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 从源仓库下载 SKILL.md 及相关文件。
  3. 在 Codex 的 skills 目录中创建新文件夹。
  4. 将所有 skill 文件复制到新文件夹中。
  5. 重启 Codex 让新的 skill 生效。

Claude Code — Git Clone 安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 克隆仓库:git clone https://github.com/anbeime/skill.git
  3. 将 "skills/content-creation-publisher/baoyu-post-to-wechat" 文件夹复制到 Claude Code 的 skills 目录中。
  4. 重启 Claude Code 让新的 skill 生效。

Claude Code — 手动复制安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 从源仓库下载 SKILL.md 及相关文件。
  3. 在 Claude Code 的 skills 目录中创建新文件夹。
  4. 将所有 skill 文件复制到新文件夹中。
  5. 重启 Claude Code 让新的 skill 生效。

Cursor — Git Clone 安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 克隆仓库:git clone https://github.com/anbeime/skill.git
  3. 将 "skills/content-creation-publisher/baoyu-post-to-wechat" 文件夹复制到 Cursor 的 skills 目录中。
  4. 重启 Cursor 让新的 skill 生效。

Cursor — 手动复制安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 从源仓库下载 SKILL.md 及相关文件。
  3. 在 Cursor 的 skills 目录中创建新文件夹。
  4. 将所有 skill 文件复制到新文件夹中。
  5. 重启 Cursor 让新的 skill 生效。

GitHub Copilot — Git Clone 安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 克隆仓库:git clone https://github.com/anbeime/skill.git
  3. 将 "skills/content-creation-publisher/baoyu-post-to-wechat" 文件夹复制到 GitHub Copilot 的 skills 目录中。
  4. 重启 GitHub Copilot 让新的 skill 生效。

GitHub Copilot — 手动复制安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 从源仓库下载 SKILL.md 及相关文件。
  3. 在 GitHub Copilot 的 skills 目录中创建新文件夹。
  4. 将所有 skill 文件复制到新文件夹中。
  5. 重启 GitHub Copilot 让新的 skill 生效。

Windsurf — Git Clone 安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 克隆仓库:git clone https://github.com/anbeime/skill.git
  3. 将 "skills/content-creation-publisher/baoyu-post-to-wechat" 文件夹复制到 Windsurf 的 skills 目录中。
  4. 重启 Windsurf 让新的 skill 生效。

Windsurf — 手动复制安装

  1. 安装前请先查看来源仓库和风险报告。
  2. 从源仓库下载 SKILL.md 及相关文件。
  3. 在 Windsurf 的 skills 目录中创建新文件夹。
  4. 将所有 skill 文件复制到新文件夹中。
  5. 重启 Windsurf 让新的 skill 生效。
查看 SKILL.md 原文
name: baoyu-post-to-wechat
description: Posts content to WeChat Official Account (微信公众号) via API or Chrome CDP. Supports article posting (文章) with HTML, markdown, or plain text input, and image-text posting (图文) with multiple images. Use when user mentions "发布公众号", "post to wechat", "微信公众号", or "图文/文章".

Post to WeChat Official Account

Language

Match user's language: Respond in the same language the user uses. If user writes in Chinese, respond in Chinese. If user writes in English, respond in English.

Script Directory

Agent Execution: Determine this SKILL.md directory as SKILL_DIR, then use ${SKILL_DIR}/scripts/<name>.ts.

ScriptPurpose
scripts/wechat-browser.tsImage-text posts (图文)
scripts/wechat-article.tsArticle posting via browser (文章)
scripts/wechat-api.tsArticle posting via API (文章)

Preferences (EXTEND.md)

Use Bash to check EXTEND.md existence (priority order):

# Check project-level first
test -f .baoyu-skills/baoyu-post-to-wechat/EXTEND.md && echo "project"

# Then user-level (cross-platform: $HOME works on macOS/Linux/WSL)
test -f "$HOME/.baoyu-skills/baoyu-post-to-wechat/EXTEND.md" && echo "user"

┌────────────────────────────────────────────────────────┬───────────────────┐ │ Path │ Location │ ├────────────────────────────────────────────────────────┼───────────────────┤ │ .baoyu-skills/baoyu-post-to-wechat/EXTEND.md │ Project directory │ ├────────────────────────────────────────────────────────┼───────────────────┤ │ $HOME/.baoyu-skills/baoyu-post-to-wechat/EXTEND.md │ User home │ └────────────────────────────────────────────────────────┴───────────────────┘

┌───────────┬───────────────────────────────────────────────────────────────────────────┐ │ Result │ Action │ ├───────────┼───────────────────────────────────────────────────────────────────────────┤ │ Found │ Read, parse, apply settings │ ├───────────┼───────────────────────────────────────────────────────────────────────────┤ │ Not found │ Run first-time setup (references/config/first-time-setup.md) → Save → Continue │ └───────────┴───────────────────────────────────────────────────────────────────────────┘

EXTEND.md Supports: Default theme | Default publishing method (api/browser) | Default author | Default open-comment switch | Default fans-only-comment switch | Chrome profile path

First-time setup: references/config/first-time-setup.md

Minimum supported keys (case-insensitive, accept 1/0 or true/false):

KeyDefaultMapping
default_authoremptyFallback for author when CLI/frontmatter not provided
need_open_comment1articles[].need_open_comment in draft/add request
only_fans_can_comment0articles[].only_fans_can_comment in draft/add request

Recommended EXTEND.md example:

default_theme: default
default_publish_method: api
default_author: 宝玉
need_open_comment: 1
only_fans_can_comment: 0
chrome_profile_path: /path/to/chrome/profile

Value priority:

  1. CLI arguments
  2. Frontmatter
  3. EXTEND.md
  4. Skill defaults

Image-Text Posting (图文)

For short posts with multiple images (up to 9):

npx -y bun ${SKILL_DIR}/scripts/wechat-browser.ts --markdown article.md --images ./images/
npx -y bun ${SKILL_DIR}/scripts/wechat-browser.ts --title "标题" --content "内容" --image img.png --submit

See references/image-text-posting.md for details.

Article Posting Workflow (文章)

Copy this checklist and check off items as you complete them:

Publishing Progress:
- [ ] Step 0: Load preferences (EXTEND.md)
- [ ] Step 1: Determine input type
- [ ] Step 2: Check markdown-to-html skill
- [ ] Step 3: Convert to HTML
- [ ] Step 4: Validate metadata (title, summary, cover)
- [ ] Step 5: Select method and configure credentials
- [ ] Step 6: Publish to WeChat
- [ ] Step 7: Report completion

Step 0: Load Preferences

Check and load EXTEND.md settings (see Preferences section above).

CRITICAL: If not found, complete first-time setup BEFORE any other steps or questions.

Resolve and store these defaults for later steps:

  • default_author
  • need_open_comment (default 1)
  • only_fans_can_comment (default 0)

Step 1: Determine Input Type

Input TypeDetectionAction
HTML filePath ends with .html, file existsSkip to Step 4
Markdown filePath ends with .md, file existsContinue to Step 2
Plain textNot a file path, or file doesn't existSave to markdown, then Step 2

Plain Text Handling:

  1. Generate slug from content (first 2-4 meaningful words, kebab-case)
  2. Create directory and save file:
mkdir -p "$(pwd)/post-to-wechat/$(date +%Y-%m-%d)"
# Save content to: post-to-wechat/yyyy-MM-dd/[slug].md
  1. Continue processing as markdown file

Slug Examples:

  • "Understanding AI Models" → understanding-ai-models
  • "人工智能的未来" → ai-future (translate to English for slug)

Step 2: Check Markdown-to-HTML Skill

Skip if: Input is .html file

Skill Discovery:

# Check if baoyu-markdown-to-html exists
test -f skills/baoyu-markdown-to-html/SKILL.md && echo "found"
ResultAction
FoundRead its SKILL.md, continue to Step 3
Multiple skillsAskUserQuestion to choose
Not foundShow installation suggestion

When Not Found:

No markdown-to-html skill found.

Suggested installation:
https://github.com/JimLiu/baoyu-skills/blob/main/skills/baoyu-markdown-to-html/SKILL.md

Options:
A) Cancel - install the skill first
B) Continue - provide HTML file manually

Step 3: Convert Markdown to HTML

Skip if: Input is .html file

  1. Ask theme preference (unless specified in EXTEND.md or CLI):
ThemeDescription
default经典主题 - 传统排版,标题居中带底边,二级标题白字彩底
grace优雅主题 - 文字阴影,圆角卡片,精致引用块
simple简洁主题 - 现代极简风,不对称圆角,清爽留白
  1. Execute conversion (using the discovered skill):
npx -y bun ${MD_TO_HTML_SKILL_DIR}/scripts/main.ts <markdown_file> --theme <theme>
  1. Parse JSON output to get: htmlPath, title, author, summary, contentImages

Step 4: Validate Metadata

Check extracted metadata from Step 3 (or HTML meta tags if direct HTML input).

FieldIf Missing
TitlePrompt: "Enter title, or press Enter to auto-generate from content"
SummaryPrompt: "Enter summary, or press Enter to auto-generate (recommended for SEO)"
AuthorUse fallback chain: CLI --author → frontmatter author → EXTEND.md default_author

Auto-Generation Logic:

  • Title: First H1/H2 heading, or first sentence
  • Summary: First paragraph, truncated to 120 characters

Cover Image Check (required for article_type=news):

  1. Use CLI --cover if provided.
  2. Else use frontmatter (featureImage, coverImage, cover, image).
  3. Else check article directory default path: imgs/cover.png.
  4. Else fallback to first inline content image.
  5. If still missing, stop and request a cover image before publishing.

Step 5: Select Publishing Method and Configure

Ask publishing method (unless specified in EXTEND.md or CLI):

MethodSpeedRequirements
api (Recommended)FastAPI credentials
browserSlowChrome, login session

If API Selected - Check Credentials:

# Check project-level
test -f .baoyu-skills/.env && grep -q "WECHAT_APP_ID" .baoyu-skills/.env && echo "project"

# Check user-level
test -f "$HOME/.baoyu-skills/.env" && grep -q "WECHAT_APP_ID" "$HOME/.baoyu-skills/.env" && echo "user"

If Credentials Missing - Guide Setup:

WeChat API credentials not found.

To obtain credentials:
1. Visit https://mp.weixin.qq.com
2. Go to: 开发 → 基本配置
3. Copy AppID and AppSecret

Where to save?
A) Project-level: .baoyu-skills/.env (this project only)
B) User-level: ~/.baoyu-skills/.env (all projects)

After location choice, prompt for values and write to .env:

WECHAT_APP_ID=<user_input>
WECHAT_APP_SECRET=<user_input>

Step 6: Publish to WeChat

API method:

npx -y bun ${SKILL_DIR}/scripts/wechat-api.ts <html_file> [--title <title>] [--summary <summary>] [--author <author>] [--cover <cover_path>]

draft/add payload rules:

  • Use endpoint: POST https://api.weixin.qq.com/cgi-bin/draft/add?access_token=ACCESS_TOKEN
  • article_type: news (default) or newspic
  • For news, include thumb_media_id (cover is required)
  • Always resolve and send:
    • need_open_comment (default 1)
    • only_fans_can_comment (default 0)
  • author resolution: CLI --author → frontmatter author → EXTEND.md default_author

If script parameters do not expose the two comment fields, still ensure final API request body includes resolved values.

Browser method:

npx -y bun ${SKILL_DIR}/scripts/wechat-article.ts --html <html_file>

Step 7: Completion Report

For API method, include draft management link:

WeChat Publishing Complete!

Input: [type] - [path]
Method: API
Theme: [theme name]

Article:
• Title: [title]
• Summary: [summary]
• Images: [N] inline images
• Comments: [open/closed], [fans-only/all users]

Result:
✓ Draft saved to WeChat Official Account
• media_id: [media_id]

Next Steps:
→ Manage drafts: https://mp.weixin.qq.com (登录后进入「内容管理」→「草稿箱」)

Files created:
[• post-to-wechat/yyyy-MM-dd/slug.md (if plain text)]
[• slug.html (converted)]

For Browser method:

WeChat Publishing Complete!

Input: [type] - [path]
Method: Browser
Theme: [theme name]

Article:
• Title: [title]
• Summary: [summary]
• Images: [N] inline images

Result:
✓ Draft saved to WeChat Official Account

Files created:
[• post-to-wechat/yyyy-MM-dd/slug.md (if plain text)]
[• slug.html (converted)]

Detailed References

TopicReference
Image-text parameters, auto-compressionreferences/image-text-posting.md
Article themes, image handlingreferences/article-posting.md

Feature Comparison

FeatureImage-TextArticle (API)Article (Browser)
Plain text input✗✓✓
HTML input✗✓✓
Markdown inputTitle/content✓ (via skill)✓ (via skill)
Multiple images✓ (up to 9)✓ (inline)✓ (inline)
Themes✗✓✓
Auto-generate metadata✗✓✓
Default cover fallback (imgs/cover.png)✗✓✗
Comment control (need_open_comment, only_fans_can_comment)✗✓✗
Requires Chrome✓✗✓
Requires API credentials✗✓✗
SpeedMediumFastSlow

Prerequisites

For API method:

  • WeChat Official Account API credentials
  • Guided setup in Step 5, or manually set in .baoyu-skills/.env

For Browser method:

  • Google Chrome
  • First run: log in to WeChat Official Account (session preserved)

For Markdown conversion:

  • A markdown-to-html skill (e.g., baoyu-markdown-to-html)
  • If not installed, the workflow will suggest installation

Config File Locations (priority order):

  1. Environment variables
  2. <cwd>/.baoyu-skills/.env
  3. ~/.baoyu-skills/.env

Troubleshooting

IssueSolution
No markdown-to-html skillInstall baoyu-markdown-to-html from suggested URL
Missing API credentialsFollow guided setup in Step 5
Access token errorCheck if API credentials are valid and not expired
Not logged in (browser)First run opens browser - scan QR to log in
Chrome not foundSet WECHAT_BROWSER_CHROME_PATH env var
Title/summary missingUse auto-generation or provide manually
No cover imageAdd frontmatter cover or place imgs/cover.png in article directory
Wrong comment defaultsCheck EXTEND.md keys need_open_comment and only_fans_can_comment
Paste failsCheck system clipboard permissions

Extension Support

Custom configurations via EXTEND.md. See Preferences section for paths and supported options.

发现问题?提交给管理员复核

评分:

评论 (0)

暂无评论,成为第一个评论者吧!