Personal expense tracker + insights dashboard.
- Input: Telegram-style
/hisabmessages (plain text) - Storage: weekly Excel workbooks (INR)
- Output: interactive dashboard + curated exports
- Optional: Gmail receipts ingestion (label-based)
This repo contains the local scripts that:
- parse your
/hisabtext into structured transactions - apply categorization rules (merchant defaults + heuristics)
- generate reports (Excel export + interactive HTML dashboard)
- (optional) fetch and parse labeled Gmail receipts
Configuration is stored in a separate private repo (recommended).
Clone it into ~/HisabKitab/refs.
The scripts assume a local data folder (not committed):
~/HisabKitab/
refs/ # your editable reference data (merchants/categories/etc.)
HK_YYYY-MM-WeekN.xlsx # weekly workbooks
hisab_dashboard.html
hisab_data.json
orders_unmatched.json
credentials.json # Gmail OAuth client (DO NOT COMMIT)
gmail_token.json # Gmail token (DO NOT COMMIT)
npm installnode src/cli/hk.js import --text "/hisab\nDay (30/1/26)\n100/- Poha (mk)" --base-dir ~/HisabKitabnode src/core/normalize.js --file ~/HisabKitab/HK_2026-01-Week5.xlsx --base-dir ~/HisabKitab
node src/core/categorize.js --file ~/HisabKitab/HK_2026-01-Week5.xlsx --base-dir ~/HisabKitabnode src/dashboard/build_dashboard.js ~/HisabKitab hisab_data.json hisab_dashboard.htmlnode src/excel/export_pretty_excel.js --in ~/HisabKitab/HK_2026-01-Week5.xlsx --out ~/HisabKitab/HK_2026-01-Week5.pretty.xlsx --base-dir ~/HisabKitabThis project only reads emails that you explicitly label HisabKitab.
- Configure supported receipt senders in:
~/HisabKitab/refs/email_merchants.json
See: docs/gmail.md
- Never commit
credentials.jsonorgmail_token.json - Keep
~/HisabKitabprivate to your user (chmod 700) and secret files chmod 600
MIT