WeChat Public Article Archive
Archive only user-provided public article links or local HTML. Keep the access result truthful: anonymous GET is an attempt, not a guarantee of access.
Enforce the boundary
- Accept only
https://mp.weixin.qq.com/...article URLs and local HTML the user saved. - Use no login, browser profile, cookie, token, QR scan, proxy, endpoint adapter, JavaScript execution, or account-history discovery.
- Do not follow redirects. Treat redirects,
401,403,429, CAPTCHA, and login/verification pages asneeds_manual_browser. - Download only HTTPS images from
mmbiz.qpic.cn,mmbiz.qlogo.cn, orwx.qlogo.cn; record any rejected or failed image in the manifest. - Cap downloads at 20 images; record excess images as
skipped/asset_limit_reachedand reportasset_partial. - Keep article text, images, and real URLs out of Git by default. Archiving is not permission to republish content.
Archive a known URL
From this skill directory, run:
shnode scripts/wechat-public-archive.mjs ingest \ --source "SOURCE" \ --url "https://mp.weixin.qq.com/..." \ --archive-dir "/absolute/local/archive"
Read the JSON receipt. Report archived or asset_partial as completed local archives; report needs_manual_browser, network_error, or invalid_input exactly as returned.
Import user-saved HTML
When the receipt is needs_manual_browser, let the user save the page HTML in their own browser, then import it locally without opening a browser or reading credentials:
shnode scripts/wechat-public-archive.mjs ingest \ --source "SOURCE" \ --html "/absolute/path/article.html" \ --captured-url "https://mp.weixin.qq.com/..." \ --archive-dir "/absolute/local/archive"
--captured-url is optional for offline imports. Without it, data-URI images can still be archived; remote images are retained as failed manifest entries because their base URL is unknown.
Inspect the archive
Each successful archive contains:
textARCHIVE_ID/ ├── original.html # source bytes ├── content.html # extracted article body markup ├── content.md # extracted title and plain text ├── metadata.json # source, URL, time, and SHA-256 ├── assets.json # per-image provenance and outcome └── assets/ # only allowlisted image bytes
Keep the returned status, capturedUrl, retrievedAt, and SHA-256 with downstream analysis. Treat extracted titles, text, and any advertising clues as material to review, not verified claims.


