360 Secure SkillHub
360 安全技能中心

wechat-article-to-markdown

该 Skill 提供命令行工具,输入公开的微信公众号文章链接后抓取页面,提取标题、公众号名称、发布时间等元数据,将正文转换为 Markdown,并把正文图片下载到本地目录,可用于文章归档、AI 摘要输入或知识库入库。

jackwener
jackwener
热度 45.60
最近更新 2026-05-20 03:29:09
分类:效率依赖:代码执行 / 联网浏览搜索 / 读写文件应用场景:文件转换 / 自动化脚本

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add wechat-article-to-markdown
Metadata
name
wechat-article-to-markdown
description
Fetch WeChat Official Account (微信公众号) articles from mp.weixin.qq.com and convert to Markdown. 微信文章转 Markdown 工具。
author
jackwener
version
1.0.0
tags
["wechat","微信","微信文章","公众号","mp.weixin.qq.com","markdown","article","converter","cli"]

WeChat Article to Markdown

Fetch a WeChat Official Account article and convert it to a clean Markdown file.

When to use

Use this skill when you need to save WeChat articles as Markdown for:

  • Personal archive
  • AI summarization input
  • Knowledge base ingestion

Prerequisites

  • Python 3.8+
# Install
uv tool install wechat-article-to-markdown
# Or: pipx install wechat-article-to-markdown

Usage

wechat-article-to-markdown "<WECHAT_ARTICLE_URL>"

Input URL format:

  • https://mp.weixin.qq.com/s/...

Output files:

  • <cwd>/output/<article-title>/<article-title>.md
  • <cwd>/output/<article-title>/images/*

Features

  1. Anti-detection fetch with Camoufox
  2. Metadata extraction (title, account name, publish time, source URL)
  3. Image localization to local files
  4. WeChat code-snippet extraction and fenced code block output
  5. HTML to Markdown conversion via markdownify
  6. Concurrent image downloading

Limitations

  • Some code snippets are image/SVG rendered and cannot be extracted as source code
  • Public mp.weixin.qq.com URL is required