Challenge
Supplier invoices arrive in mailboxes, folders and bank feeds. Reconciling them by hand against the accounts is slow, error-prone and leaves no clear record of who approved what.
Approach
An internal web application, built for my own business’s invoices, that follows the document through the whole workflow. Ingestion collects invoices from several monitored mailboxes, a OneDrive folder and FreeAgent bank-transaction attachments, tracking what has been processed so read state is irrelevant, with a backlog import for older documents. Extraction uses Azure AI Document Intelligence behind a circuit breaker, with plausibility checks that reject implausible invoice-number reads and a re-extraction pass for documents processed before a parser fix. Matching performs global assignment across candidate invoice–transaction pairs rather than greedy first-match, with confidence scoring, token-based reference matching, a manual-match screen that records the reason for every rejection, and a full audit trail. Write-back sends confirmed matches to FreeAgent — attachments and explanations — through a dedicated integration service with its own retry and paging logic. A scheduled job verifies that archived documents still match their recorded fingerprints, and a Blazor dashboard gives one view of the whole process. Infrastructure is defined as code; the pipeline applies database patches, runs a post-deploy smoke test and fails on warnings.
Outcome
- Designed to put ingestion, extraction, matching, review and write-back in one interface, so reconciliation ends in the accounting system, not a spreadsheet
- Designed so high-confidence matches can be applied automatically and the rest go to a person
- A full audit log on every match, review and approval
- In live proving on my own invoices: targeted fixes continue as real documents surface edge cases
Have a similar problem in your own systems? Book a free 20-minute call or describe it.
Where judgement mattered
- Global assignment over greedy matching — the obvious algorithm produces confidently wrong pairings
- Plausibility guards on AI extraction, because a model's confidence is not the same as being right
- Access control and audit designed in from the first line, not added afterwards
- Saying "live proving" rather than "done" while the edge cases are still arriving
Technology stack
C# / .NET 10 · Blazor on Azure Static Web Apps · Azure Functions · Azure SQL · Azure AI Document Intelligence · Microsoft Graph · FreeAgent API · Microsoft Entra ID · infrastructure as code · Azure DevOps CI/CD