Skip to main content

Module parser

Module parser 

Source
Expand description

UPI/bank payment parsing from notification/SMS text. Rule-based, no AI. Port of lib/core/upi_parser.dart (parseUpiNotification, _cleanMerchant, encodeInboxLine). Covers UPI apps, bank apps, and messaging apps (amount + payment keyword).

Regex notes: every pattern is verbatim from the Dart source wrapped in (?i:...), with mechanical \d[0-9] / \s[ \t\n\x0B\f\r] (see non_transaction.rs for why).

Structs§

ParsedPayment
A UPI/bank payment parsed from a notification’s text.

Functions§

encode_inbox_line
Encodes a raw capture line for the inbox JSONL file.
parse_upi_notification
Parses text into a payment, or None if it isn’t a payment notification (spam, no amount, or no payment verb — e.g. a casual “send me ₹200” chat).