Skip to content

[codex] Parse public account article appmsgs#35

Draft
hqhq1025 wants to merge 1 commit into
jackwener:mainfrom
hqhq1025:codex/article-appmsg-metadata
Draft

[codex] Parse public account article appmsgs#35
hqhq1025 wants to merge 1 commit into
jackwener:mainfrom
hqhq1025:codex/article-appmsg-metadata

Conversation

@hqhq1025
Copy link
Copy Markdown
Contributor

Summary

  • parse forwarded public-account article appmsgs (type=5) into readable history/export content
  • expose structured article metadata under appmsg in JSON output, including url, title, description, source account, and thumbnail metadata
  • make search match decompressed/formatted appmsg content so compressed public-account articles can be found by title/source/URL text

Why

Forwarded WeChat public-account articles are stored as appmsg XML. The raw XML contains the article URL and source account fields, but wx history and wx export previously collapsed these messages to only [链接] <title>, and wx search could miss compressed article appmsgs because SQL LIKE cannot inspect the decompressed body.

Validation

  • cargo test (44 passed)
  • cargo check
  • Real local-data smoke test with an Agent Hub public-account article:
    • wx history "Agent Hub" --json --type link --since 2026-05-04 --until 2026-05-11 -n 10 now includes appmsg.url
    • wx search "候鸟300" --in "Agent Hub" --json -n 20 finds the compressed article appmsg
    • wx export "Agent Hub" --since 2026-05-04 --until 2026-05-10 -f txt includes the visible mp.weixin.qq.com URL

Notes

  • cargo fmt --check currently reports formatting changes across pre-existing files on main; this PR intentionally does not reformat unrelated files.
  • Cross-target checks were attempted, but this local machine lacks the required C cross toolchains/SDKs:
    • Linux target: missing x86_64-linux-gnu-gcc
    • Windows MSVC target: missing target C headers such as stdlib.h/string.h for bundled C deps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant