The challenge
A national value retail chain runs invoice and header reconciliation across several entities. Invoices arrive by upload and by scheduled feed, in formats that vary by vendor, and each one has to be checked against header and expected data before it is fit to be a record in the ledger. Done by hand, the checks are inconsistent between reviewers, the reasons invoices fail are not counted anywhere, and duplicates are found late — after a second copy of the same invoice has already been keyed. The requirement was a single path from capture to export in which every check is recorded and a person still approves what leaves.
What we built
One flow from capture to export. Invoices arrive by manual upload or on a schedule from SFTP or a configured data source, and OCR reads invoice number, vendor, amounts, tax, GSTIN and dates from each one. Mandatory-field, format and business-rule validation runs before ingestion rather than after it, with duplicates and warnings reported separately from hard failures. Line items are matched n-way against header and expected data, and every outcome is categorised as accepted, mismatched or incomplete with a reason bucket attached. TDS is tagged automatically and expense categories are mapped. Nothing exports until a checker has approved it.
The result
The reasons invoices fail become countable. GSTIN mismatch, amount mismatch and date mismatch are separate buckets rather than a single pile of exceptions, so the root cause is visible and a vendor sending the wrong registration number every month is identifiable as such. Duplicates are caught before ingestion instead of after keying. Filters and financial rules are configured by the finance team without engineering support. Maker-checker keeps a person on the release, and the field-level audit trail plus per-run process logs mean any figure in the export can be traced back to the document and the reviewer who approved it.

