Tooluck logoTooluck
SKILL.md

aws-wechat-article-publish

Agent skill fromaiworkskills/wechat-article-skills

公众号发布|公众号草稿箱|公众号群发|图文推送|微信 API|wechat automation|WeChat API automation|auto publish|scheduled publish — 公众号 API 发布工具,图文入草稿箱或直接群发,支持封面素材上传、发布前检查与 draft/published 模式切换。面向公众号运营、自动化内容团队、开发者。触发词:「发布」「提交」「群发」「推送」「发出去」「上传到公众号」「发到公众号」「可以发了吗」「发布前检查」。需要多环节串联(写+审+排+配图+发)请走 aws-wechat-article-main。

How to install aws-wechat-article-publish

install aws-wechat-article-publish
# install the wechat-article-skills pack with the skills CLI
npx skills add aiworkskills/wechat-article-skills

# or add only this skill to Claude Code: copy the folder

skills/aws-wechat-article-publish/

# into

~/.claude/skills/aws-wechat-article-publish/ (all projects)

.claude/skills/aws-wechat-article-publish/ (one project)

skills/aws-wechat-article-publish/SKILL.md

Apache-2.0Full file
1# 发布
2
3**公众号 API 直连发布** —— 图文入草稿箱或直接群发,素材上传、发布前检查一站式完成。
4
5> **套件说明** · 本 skill 属 `aws-wechat-article-*` 一条龙套件(共 9 个 slug,入口 `aws-wechat-article-main`)。跨 skill 的相对引用依赖同一 `skills/` 目录,建议一并 `clawhub install` 全套。源码:<https://github.com/aiworkskills/wechat-article-skills>
6
7## 能力披露(Capabilities)
8
9本 skill 调 `publish.py` **直连微信公众号官方 API** 发布图文。**会把本篇 `article.html` 与 `imgs/*` 文件作为 POST body 上传到微信服务器。**
10
11- **凭证读取**:`aws.env` 的 `WECHAT_{N}_APPID` / `WECHAT_{N}_APPSECRET`(多槽位,N≥1)
12- **凭证外发**:`APPID` / `APPSECRET` 以 query string 发给 `api.weixin.qq.com/cgi-bin/token` 换 `access_token`;后续请求带 `access_token`。微信返回的 token 只在进程内存短期缓存,**不落盘**
13- **内容外发**:封面与正文插图以 multipart 发给 `material/add_material`;`article.html` 正文与标题/摘要以 JSON POST 发给 `draft/add`、`freepublish/submit`
14- **网络目标**:默认 `api.weixin.qq.com`;可用 `WECHAT_{N}_API_BASE` / `config.yaml.wechat_api_base` 自配反代
15- **文件读**:`.aws-article/config.yaml`、`aws.env`、本篇 `article.yaml`、`article.html`、`imgs/*`
16- **文件写**:
17 - `publish.py` **不写 `article.yaml`**——`media_id` / `publish_id` / `publish_completed` 只打印,写回由智能体做(见下「`publish_completed` 门禁」)
18 - 图片超过微信大小限制时会在源图旁生成压缩缓存 `<原名>_compressed.jpg`(需 Pillow)。这个文件**不会被自动清理**,也不会被当作正文图上传
19 - `article_init.py` 写本篇 `article.yaml` 与可选 `closing.md`
20- **shell**:`{python} {baseDir}/scripts/` 下的 `publish.py`、`getdraft.py`、`article_init.py`
21
22**建议**:首次运行用 `publish_method: draft` 只入草稿箱确认效果,再切 `published` 真正群发。
23
24## 路由
25…

Excerpt shown under the repository's Apache-2.0 license.

More skills in wechat-article-skills

Keep exploring

Similar skill repositories

thedotmack /

claude-mem
116k

Persistent Context Across Sessions for Every Agent – Captures everything your agent does during sessions, compresses it with AI, and injects relevant context back into future sessions. Works with Claude Code, OpenClaw, Codex, Gemini, Hermes, Copilot, OpenCode + More

CCCXGHGM+135 skills

Newsletter

Join the Community

Subscribe to our newsletter for the latest news and updates