WeChat MP Reader FZX

v1.0.0

抓取微信公众号文章并转换为 Markdown 格式。支持提取标题、作者、发布时间、封面图、正文内容(含图片、视频链接)。 当用户提到以下场景时触发: - 读取/抓取/下载微信公众号文章 - 将公众号文章转为 Markdown - 提取 mp.weixin.qq.com 链接内容 - 保存公众号文章到本地 - 微信...

0· 39·0 current·0 all-time
byfzx@limingfa

Install

OpenClaw Prompt Flow

Install with OpenClaw

Best for remote or guided setup. Copy the exact prompt, then paste it into OpenClaw for limingfa/wechat-mp-reader-fzx.

Previewing Install & Setup.
Prompt PreviewInstall & Setup
Install the skill "WeChat MP Reader FZX" (limingfa/wechat-mp-reader-fzx) from ClawHub.
Skill page: https://clawhub.ai/limingfa/wechat-mp-reader-fzx
Keep the work scoped to this skill only.
After install, inspect the skill metadata and help me finish setup.
Use only the metadata you can verify from ClawHub; do not invent missing requirements.
Ask before making any broader environment changes.

Command Line

CLI Commands

Use the direct CLI path if you want to install manually and keep every step visible.

OpenClaw CLI

Bare skill slug

openclaw skills install wechat-mp-reader-fzx

ClawHub CLI

Package manager switcher

npx clawhub@latest install wechat-mp-reader-fzx
Security Scan
VirusTotalVirusTotal
Benign
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
Name/description describe scraping mp.weixin.qq.com and converting to Markdown; the included Python script and SKILL.md implement exactly that and require only requests/Python. No unrelated credentials, binaries, or installs are requested.
Instruction Scope
Runtime instructions and the script narrowly focus on fetching the provided mp.weixin.qq.com URL, extracting fields, converting to Markdown, and saving to disk. Minor note: the troubleshooting section suggests "更换 IP" (change IP) to bypass 403, which implicitly advises workarounds for anti-scraping measures — that is outside purely technical scope and may have legal/terms-of-service implications.
Install Mechanism
No install spec; this is instruction + a single Python script. Dependencies are minimal (requests). Nothing downloaded from untrusted URLs or extracted to disk during install.
Credentials
The skill requests no environment variables, no credentials, and no config paths. The script makes outbound HTTP GET requests only to the user-provided URL (mp.weixin.qq.com or whatever the user passes).
Persistence & Privilege
always is false and the skill does not request persistent elevated privileges or modify other skills or global agent configuration. It writes Markdown files to the chosen output directory (default current working directory), which is expected behavior.
Assessment
This skill appears to do exactly what it claims: fetch a WeChat article URL and convert it to Markdown. Before installing or running it, consider: 1) Legal/ToS — scraping WeChat content may violate WeChat's terms or copyright; ensure you have the right to archive the article. 2) Anti-abuse — the SKILL.md suggests changing IP to avoid 403s; avoid evasion techniques that could be unlawful. 3) Local file writes — the script saves files to the specified output directory (default = current directory); run it in a controlled directory. 4) Arbitrary-URL fetches — the tool will GET whatever URL you pass; do not run it on untrusted or internal-network URLs you don't intend to fetch. 5) Dependency — install the Python 'requests' package (pip install requests). If you want stronger guarantees, run the script in a sandbox or restricted environment.

Like a lobster shell, security has layers — review code before you run it.

latestvk97a6zekmwzjncts16mf312z7x85msdr
39downloads
0stars
1versions
Updated 1d ago
v1.0.0
MIT-0

WeChat MP Reader — 微信公众号文章抓取工具

功能

抓取微信公众号文章(mp.weixin.qq.com 链接),提取完整内容并转换为 Markdown 格式保存到本地。

支持提取的信息

  • 标题 — 文章标题
  • 公众号名称 — 作者/来源
  • 发布时间 — 文章发布日期
  • 封面图 — 文章封面图片链接
  • 正文内容 — 完整的文章正文,包含:
    • 文本段落、标题层级
    • 图片(保留原图链接)
    • 视频链接
    • 超链接
    • 列表、引用、加粗/斜体等格式

使用方法

命令行方式

python scripts/fetch_wechat_article.py <文章链接> [选项]

参数:

  • url — 微信公众号文章链接(必需)
  • -o, --output — 输出目录(默认:当前目录)
  • --images — 下载图片到本地(开发中)
  • --json — 以 JSON 格式输出元数据

示例:

# 基本用法
python scripts/fetch_wechat_article.py "https://mp.weixin.qq.com/s/xxxxx"

# 指定输出目录
python scripts/fetch_wechat_article.py "https://mp.weixin.qq.com/s/xxxxx" -o ./articles

# 只输出 JSON 元数据
python scripts/fetch_wechat_article.py "https://mp.weixin.qq.com/s/xxxxx" --json

Python API 方式

from scripts.fetch_wechat_article import fetch_article

result = fetch_article(
    url="https://mp.weixin.qq.com/s/xxxxx",
    output_dir="./articles"
)

print(result['title'])      # 文章标题
print(result['author'])     # 公众号名称
print(result['content'])    # Markdown 正文
print(result['filepath'])   # 保存的文件路径

输出格式

生成的 Markdown 文件结构:

# 文章标题

**公众号**: 公众号名称
**发布时间**: 2024-01-01
**封面**: ![封面](封面图链接)
**原文链接**: https://mp.weixin.qq.com/s/xxxxx

---

正文内容...

![图片](图片链接)

[视频](视频链接)

依赖

  • Python 3.8+
  • requests 库(用于 HTTP 请求)

安装依赖:

pip install requests

注意事项

  1. 网络要求 — 需要能访问 mp.weixin.qq.com
  2. 反爬机制 — 频繁抓取可能触发微信的反爬机制,建议适当控制请求频率
  3. 链接有效性 — 确保文章链接未过期或被删除
  4. 图片链接 — 生成的 Markdown 中图片使用微信 CDN 原链接,长期有效性取决于微信策略

故障排查

问题可能原因解决方案
无法提取正文页面结构变化检查微信是否更新了页面结构
返回 403被反爬拦截稍后再试,或更换 IP
标题为空文章被删除/受限确认链接可在浏览器正常打开
图片不显示微信 CDN 链接过期使用 --images 下载到本地

Comments

Loading comments...