hejunjie/wechat-bill-parser
Composer 安装命令:
composer require hejunjie/wechat-bill-parser
包简介
一个高性能、自动化的微信账单解析器,支持压缩包密码自动破解与账单数据智能提取,适用于账单分析、账单自动化入账、个人理财工具开发等场景 | A fast, automated Wechat bill parser that cracks compressed file passwords and extracts bill data. Perfect for bill analysis, automatic bookkeeping, and personal finance tools
README 文档
README
English|简体中文⚠️ This project is for learning and communication purposes only. Commercial or illegal use is strictly prohibited.
A high-performance, automated Wechat bill parser that supports automatic password cracking of compressed files and intelligent extraction of bill data. Ideal for scenarios such as bill analysis, automated bookkeeping, and personal finance tool development.
This project has been parsed by Zread. If you need a quick overview of the project, you can click here to view it:Understand this project
✨ Features
-
🔐 Automatic Password Cracking for Compressed Files: Utilizes a native C-based multithreaded brute-force tool for extremely fast response and minimal resource usage.
-
📦 No Manual Extraction Required: Supports password-protected archives, automatically decompresses and reads bill data without manual intervention.
-
📄 Intelligent Data Extraction: Parses Wechat bill CSV files to quickly extract account information, user names, and transaction details.
-
🧩 Highly Customizable: Offers flexible control over the parsing process via callback functions—for example, to retrieve only the password without generating HTML.
-
📬 Compatible with Email Monitoring Scripts: Can be integrated with email listeners to enable fully automated bill collection and parsing.
🛠 System Requirements
This library depends on the C library libzip. Please install the dependency first:
-
Ubuntu / Debian:
sudo apt install libzip-dev
-
macOS (using Homebrew):
brew install libzip
-
Windows users can use this via WSL, or use the precompiled
zip_bruteforce.exe.
📦 Installation
Install this library via Composer:
composer require hejunjie/wechat-bill-parser
🚀 Usage
use Hejunjie\WechatBillParser\WechatBillParser; use Hejunjie\WechatBillParser\ParseOptions; $zipFile = '/path/to/微信支付账单.zip'; $options = new ParseOptions($zipFile); $options->onPasswordFound = function ($password) { echo "password:$password\n"; return true; // Returning false will terminate the subsequent parsing process. }; $options->onDataParsed = function ($data) { echo "name " . $data['real_name'] . PHP_EOL; echo "account " . $data['account'] . PHP_EOL; echo "A total of " . count($data['data']) . " records have been parsed.\n"; return true; // Returning false will skip the HTML generation step (under development). }; // tips: Future versions may support directly generating a bill report as an HTML file. $parser = new WechatBillParser(); $parser->parse($options);
You can also choose to retrieve only the password or only the bill data—simply implement the corresponding callback functions as needed.
🧠 Purpose & Motivation
I usually keep track of my bills and personal income and expenses, but the bill formats exported from WeChat and Alipay are inconsistent and often come as encrypted compressed files. Exporting, extracting, and organizing these bills every time is extremely tedious. So, I developed this tool:
-
Acts as middleware for personal bill processing;
-
Eliminates the need for manual downloading and extraction by automatically cracking compressed files and extracting data;
-
Can be combined with email monitoring scripts to enable automated transaction collection;
-
Simply forward all bill emails to a designated mailbox, and you can parse all bill data with one click—freeing your hands completely.
🧾 Output Structure Description
The $data passed into the onDataParsed callback is an array with the following structure:
[ 'real_name' => '张三', // name 'account' => '18273727771', // WeChat Nickname 'data' => [ // Each line of bill record ["Transaction Time", "Transaction Type", "Counterparty", "Product", "Income/Expense", "Amount (CNY)", "Payment Method", "Current Status", "Transaction ID", "Merchant Order ID", "Remarks"] ... ] ]
📮 Contact
If you have any questions, suggestions, or cooperation interests, feel free to reach out to me via GitHub Issues.
hejunjie/wechat-bill-parser 适用场景与选型建议
hejunjie/wechat-bill-parser 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 25 次下载、GitHub Stars 达 7, 最近一次更新时间为 2025 年 05 月 27 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 hejunjie/wechat-bill-parser 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 hejunjie/wechat-bill-parser 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 25
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 7
- 点击次数: 35
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2025-05-27