Skip to content

0007: VAT derivation and back-test ​

Context ​

The old code built VAT from invoice and bill headers only and could double-count receipts. Xero exposes no UK VAT report, and its Journals endpoint is not on the free tier.

Decision ​

Derive from line items with tax type across invoices, bills, credit notes, bank transactions and manual journals, using a tested tax-type-to-box mapping. An unknown tax type blocks the draft. Before first use, past periods must equal the returns HMRC holds.

Consequences ​

Standard accrual only at first. Other schemes stop with unsupported scheme.