Back to list
ImGoodBai

baoyu-post-to-wechat

by ImGoodBai

Desktop Cowork app for office workers: organize local folders, extract from PDFs/images, generate invoices/contracts/resumes, and build small internal tools.

48🍴 11📅 Jan 24, 2026

SKILL.md


name: baoyu-post-to-wechat displayName: 公众号发布技能 description: Post content to WeChat Official Account (微信公众号). Supports both article posting (文章) and image-text posting (图文).

Post to WeChat Official Account (微信公众号)

Post content to WeChat Official Account using Chrome CDP automation.

Script Directory

Important: All scripts are located in the scripts/ subdirectory of this skill.

Agent Execution Instructions:

  1. Determine this SKILL.md file's directory path as SKILL_DIR
  2. Script path = ${SKILL_DIR}/scripts/<script-name>.ts
  3. Replace all ${SKILL_DIR} in this document with the actual path

Script Reference:

ScriptPurpose
scripts/wechat-browser.tsImage-text posts (图文)
scripts/wechat-article.tsFull article posting (文章)
scripts/md-to-wechat.tsMarkdown → WeChat HTML conversion
scripts/copy-to-clipboard.tsCopy content to clipboard
scripts/paste-from-clipboard.tsSend real paste keystroke

Quick Usage

Image-Text (图文) - Multiple images with title/content

# From markdown file and image directory
npx -y bun ${SKILL_DIR}/scripts/wechat-browser.ts --markdown article.md --images ./images/

# With explicit parameters
npx -y bun ${SKILL_DIR}/scripts/wechat-browser.ts --title "标题" --content "内容" --image img1.png --image img2.png --submit

Article (文章) - Full markdown with formatting

# Post markdown article
npx -y bun ${SKILL_DIR}/scripts/wechat-article.ts --markdown article.md --theme grace

Note: ${SKILL_DIR} represents this skill's installation directory. Agent replaces with actual path at runtime.

References

  • Image-Text Posting: See references/image-text-posting.md for detailed image-text posting guide
  • Article Posting: See references/article-posting.md for detailed article posting guide

Prerequisites

  • Google Chrome installed
  • bun runtime (via npx -y bun)
  • First run: log in to WeChat Official Account in the opened browser window

Features

FeatureImage-TextArticle
Multiple images✓ (up to 9)✓ (inline)
Markdown supportTitle/content extractionFull formatting
Auto title compression✓ (to 20 chars)
Content compression✓ (to 1000 chars)
Themes✓ (default, grace, simple)

Troubleshooting

  • Not logged in: First run opens browser - scan QR code to log in, session is preserved
  • Chrome not found: Set WECHAT_BROWSER_CHROME_PATH environment variable
  • Paste fails: Check system clipboard permissions

Score

Total Score

80/100

Based on repository quality metrics

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

+10
説明文

100文字以上の説明がある

+10
人気

GitHub Stars 100以上

0/15
最近の活動

1ヶ月以内に更新

+10
フォーク

10回以上フォークされている

+5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

+5

Reviews

💬

Reviews coming soon