Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
bnd-1 avatar

Wechat Draft Publisher

  • 75 installs
  • 1 repo stars
  • Updated April 12, 2026
  • bnd-1/wechat_article_mini

wechat-draft-publisher is a skill that uploads an HTML article and cover image to a WeChat public-account draft box via the official API, with first-run guided credential and IP-whitelist setup.

About

wechat-draft-publisher is a skill that publishes an HTML article to a WeChat public-account draft box via the official API. A developer invokes it after formatting an article to upload the cover image, upload content images, and create the draft. On first use it guides the user through IP-whitelist configuration and entering AppID and AppSecret. Drafts are not auto-published; the user confirms in the WeChat backend. This is the 'mini' fast variant. Docs are in Chinese.

  • Publishes HTML articles to the WeChat public-account draft box
  • First-run guided setup for IP whitelist plus AppID/AppSecret
  • Uploads cover and content images, then returns a media_id

Wechat Draft Publisher by the numbers

  • 75 all-time installs (skills.sh)
  • Ranked #1,203 of 1,879 Marketing & SEO skills by installs in the Skillselion catalog
  • Data as of Jul 28, 2026 (Skillselion catalog sync)
At a glance

wechat-draft-publisher capabilities & compatibility

Free tooling; requires a WeChat public-account AppID/AppSecret and the server IP whitelisted.

Capabilities
wechat publishing · draft creation · image upload
Use cases
marketing · copywriting
Pricing
Bring your own API key
From the docs

What wechat-draft-publisher says it does

首次使用需要配置两件事:
SKILL.md
**调用发布**:上传封面 → 上传内容图片 → 创建草稿
SKILL.md
草稿不会自动发布,你可以在后台编辑后再发
SKILL.md
npx skills add https://github.com/bnd-1/wechat_article_mini --skill wechat-draft-publisher

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs75
repo stars1
Last updatedApril 12, 2026
Repositorybnd-1/wechat_article_mini

What it does

Publish a formatted HTML article and cover image to the WeChat public-account draft box using the official API and stored credentials.

Who is it for?

Writers who want to push a finished WeChat article to the draft box without manually calling the API.

Skip if: Auto-publishing; the draft stays in the backend and the user publishes it manually.

When should I use this skill?

The user says '推送到微信', '发布到公众号', or '上传草稿' (push to WeChat / publish to public account / upload draft).

What you get

An article draft created in the WeChat backend with cover and content images, returning a media_id.

  • WeChat draft with media_id
  • uploaded cover and content images

By the numbers

  • config stored at ~/.wechat-publisher/config.json
  • common-error lookup table with four rows

Files

SKILL.mdMarkdownGitHub ↗

微信公众号草稿发布器(小龙虾极速版)

核心理念:首次引导配置,之后一键发布

---

前置:安装依赖

每次使用前,先确保依赖已安装(幂等操作,可重复执行):

pip3 install -r skills/wechat-draft-publisher/requirements.txt

---

首次使用:引导配置

第1步:查询IP并告知用户

每次首次使用或遇到IP白名单错误时,先帮用户查询IP:

python publisher.py --query-ip

这会自动查询公网IP并显示:

>>> 你的公网IP是: x.x.x.x

请将此IP添加到微信公众号后台:
1. 登录 https://developers.weixin.qq.com/platform
2. 设置与开发 → 基本配置 → IP白名单
3. 添加IP: x.x.x.x

告诉用户:

首次使用需要配置两件事:

1. IP白名单:我已查到你的服务器IP是 x.x.x.x
   请登录微信公众号后台,在 设置与开发→基本配置→IP白名单 中添加这个IP

2. AppID和AppSecret:
   在同一页面(基本配置)中复制AppID和AppSecret
   运行发布工具时会自动引导你填写

配置好了告诉我,我就帮你发布!

第2步:运行发布器(自动引导输入凭证)

python publisher.py --title "文章标题" --content article.html

首次运行会自动提示输入 AppID 和 AppSecret。

---

正常发布流程(配置完成后)

一键发布

python publisher.py \
  --title "文章标题" \
  --content xxx_formatted.html \
  --cover cover.png \
  --author "小龙虾"

自动执行步骤

1. 找 HTML 文件:优先 *_formatted.html,回退最新 .html 2. 提取标题:从 HTML 注释或文件名 3. 找封面图cover.png 4. 调用发布:上传封面 → 上传内容图片 → 创建草稿 5. 返回结果:显示 media_id,提示去后台查看

发布成功后提示

✅ 文章已推送到草稿箱!

接下来:
1. 登录 https://developers.weixin.qq.com/platform
2. 进入"草稿箱"
3. 预览效果,确认后发布

⚠️ 草稿不会自动发布,你可以在后台编辑后再发

---

常见错误速查

错误原因解决
invalid ip not in whitelistIP不在白名单运行 python publisher.py --query-ip 查IP并添加
AppSecret error凭证错误检查 ~/.wechat-publisher/config.json
title size out of limit标题太长工具会自动截断,无需处理
api功能未授权公众号类型不支持需要认证的服务号

---

配置文件位置

~/.wechat-publisher/config.json

{
  "appid": "xxx",
  "appsecret": "xxx"
}

---

完整工作流联动

写文章(tech-writer/pm-writer) → 美化格式(formatter) → 推送到微信(本skill)

用户只需要说三句话: 1. "写一篇关于XXX的文章" 2. "美化文章" 3. "推送到微信"

Related skills

FAQ

What credentials does it need?

AppID and AppSecret from the WeChat public-account basic-config page, stored in ~/.wechat-publisher/config.json, plus the server IP added to the WeChat IP whitelist.

Does it publish the article automatically?

No. It creates a draft that is not auto-published; the user reviews and publishes it from the WeChat backend.

Marketing & SEOdistributioncontent

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.