Invoicing Platform Architecture
The complexity in invoicing platforms is in tax calculation accuracy, e-invoicing format compliance, and AR workflow state management, not the invoice PDF itself.
Invoice Data Model and Line Item Engine
Invoice records are modelled as immutable documents: once issued, corrections are handled via credit notes and re-issuance, not in-place edits. The line item engine supports flat fees, time-and-materials (hours x rate, with timesheet integration), milestone billing, and usage-based quantities pulled from a metering API. Tax rules are stored as versioned configuration (rate, jurisdiction, exemption categories), not hardcoded, so rate changes are applied without code deployment.
E-Invoicing and Structured Data Exchange
For EU and UK customers, the platform generates invoices in structured electronic formats: PEPPOL BIS Billing 3.0 (UBL 2.1 XML) for PEPPOL network delivery, Factur-X/ZUGFeRD (PDF/A-3 with embedded XML) for email delivery with machine-readable data, and EN 16931 semantic model compliance for cross-border EU trade. The PEPPOL access point integration handles SMP lookup for recipient endpoint discovery, document validation against the relevant PEPPOL BIS specification, and transmission acknowledgement tracking.
Accounts Receivable Workflow Engine
The AR workflow state machine tracks invoices through: Draft, Issued, Partially Paid, Paid, Overdue, Disputed, Written Off. Dunning sequences are configured per customer segment: enterprise customers on a manual escalation path, SME customers on automated email sequences with adjustable cadence. Each dunning contact is logged with timestamp, channel, and response outcome. Dispute handling creates a linked dispute record with evidence attachment, suspends the dunning sequence, and triggers an internal review workflow.
Payment Rail Integration and Reconciliation
Payment collection integrates with direct debit rails (GoCardless for BACS/SEPA Core, Stripe for ACH Debit), card payment for one-off settlement, and virtual bank account per customer for faster payment reconciliation via Modulr or Bankable. Inbound payments are matched to open invoices automatically using amount + reference number + IBAN source, with a matching confidence score that flags low-confidence matches for manual review rather than auto-posting incorrect allocations.