wechat-article-downloader
できること
このスキルは、MCPツールサービスを使ってWeChatの公開アカウントから記事をダウンロードします。WeChatの記事を保存、アーカイブ、分析したい人に向けたものです。
使う場面
- ✓WeChatの記事を一つ、PDF、Word、またはMarkdownとして保存したいとき。
- ✓公開アカウントの記事の集まりを、まるごとダウンロードしたいとき。
- ✓記事のタイトル、リンクなどのメタデータを、CSVファイルに書き出したいとき。
スキルのリンク
https://github.com/qiye45/wechatDownload/blob/main/skills/wechat-article-downloader/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“このWeChatの記事をMarkdownファイルとして保存し、そのタイトルとリンクをCSVに書き出してください。”
毎週5つの新しいスキル。1分で読めます。
仕組み
スキルは、まずローカルのMCPサーバーを確認し、一部のツールではリモートのサーバーに切り替えられます。必要なダウンロードまたは書き出しのツールを呼び出し、選んだ形式で結果を保存します。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
WeChat Article Downloader
This skill helps you download articles from WeChat official accounts using an MCP server that interfaces with a WeChat article download tool.
Prerequisites
The skill uses local MCP endpoint http://127.0.0.1:4545/mcp for full functionality.
If local MCP is unavailable, you may fallback to https://changfengbox.top/api/mcp for remote-supported tools.
Local MCP tools:
single_article_download- Download a single articleget_public_account_id- Get public account credentialsbatch_download_articles- Batch download all articles from an accountexport_article_data- Export article metadata to CSV
Remote fallback MCP (https://changfengbox.top/api/mcp) currently supports:
- Methods:
initialize,tools/list,tools/call - Tools in
tools/callname:wechat- Download a single articlewechat_collection- Download a public account collection (appmsgalbum)
Important: remote fallback does not expose local tool names like single_article_download, batch_download_articles, get_public_account_id, or export_article_data.
Workflow
1. Check Local MCP Server Status
Before using most functionality, verify local MCP is running:
import requests
LOCAL_MCP_ENDPOINT = "http://127.0.0.1:4545/mcp"
def check_local_mcp():
response = requests.post(
LOCAL_MCP_ENDPOINT,
json={"jsonrpc": "2.0", "method": "initialize", "id": 1},
headers={"Content-Type": "application/json"},
timeout=3,
)
if response.status_code != 200:
raise RuntimeError("Local MCP is not available")
return LOCAL_MCP_ENDPOINT
local_mcp_endpoint = check_local_mcp()
If local MCP is inaccessible, inform the user they need to:
- Open the WeChat article download tool
- Check the "启动MCP" checkbox to start the MCP service
- Wait for the confirmation message showing the service is running on port 4545
2. Single Article Download
Use local tool first. If local MCP fails, fallback to remote wechat tool.
import requests
LOCAL_MCP_ENDPOINT = "http://127.0.0.1:4545/mcp"
FALLBACK_DOWNLOAD_MCP_ENDPOINT = "https://changfengbox.top/api/mcp"
def call_tool(endpoint, tool_name, arguments, req_id=2):
payload = {
"jsonrpc": "2.0",
"method": "tools/call",
"id": req_id,
"params": {
"name": tool_name,
"arguments": arguments,
}
}
response = requests.post(
endpoint,
json=payload,
headers={"Content-Type": "application/json"},
timeout=10,
)
response.raise_for_status()
return response.json()
def download_single_article(url):
try:
return call_tool(
LOCAL_MCP_ENDPOINT,
"single_article_download",
{"url": url},
req_id=2,
)
except Exception:
remote_config = {
"保存离线网页": True,
"HTML": True,
"MD": True,
"PDF": False,
"WORD": False,
"TXT": False,
"MHTML": False,
"文件开头添加日期": True,
}
return call_tool(
FALLBACK_DOWNLOAD_MCP_ENDPOINT,
"wechat",
{"url": url, "config": remote_config},
req_id=3,
)
# Example usage
article_url = "https://mp.weixin.qq.com/s/xxxxx"
result = download_single_article(article_url)
print(result)
The article will be downloaded to the tool's default download directory in the formats configured in the tool (HTML, PDF, Word, Markdown, MHTML, etc.).
Remote wechat config can use these keys:
保存离线网页HTMLMDPDFWORDTXTMHTML文件开头添加日期
If local 127.0.0.1:4545 is unavailable, this step should transparently use https://changfengbox.top/api/mcp with tool name wechat.
3. Download Collection (appmsgalbum)
For collection URLs, call remote wechat_collection via tools/call:
def download_collection(collection_url):
payload = {
"jsonrpc": "2.0",
"method": "tools/call",
"id": 4,
"params": {
"name": "wechat_collection",
"arguments": {
"url": collection_url,
},
},
}
response = requests.post(
"https://changfengbox.top/api/mcp",
json=payload,
headers={"Content-Type": "application/json"},
timeout=20,
)
response.raise_for_status()
return response.json()
よくある質問
どの形式で保存できますか?
HTML、PDF、Word、Markdown、TXT、MHTMLが挙げられています。
ローカルのサーバーが動いていない場合はどうなりますか?
一部のツールだけに対応するリモートのエンドポイントに、切り替えられるとスキルは述べています。
記事のデータを書き出せますか?
はい。記事のメタデータをCSVに書き出す書き出しツールが含まれています。
詳細
作者による元の説明
Download WeChat official account articles in multiple formats (HTML, PDF, Word, Markdown, TXT, MHTML), including single article download, collection (appmsgalbum) download, local bulk workflows, and metadata export. Use this skill when users ask to download WeChat articles, download public account collections, batch pull account content, or export article data.
repo: qiye45/wechatDownload
人気
- GitHubのスター
- 10.0k
- ランキング
- #12034
- ライセンス
- —
- 更新日
- 2026/11/1
コメント
- …