Skill Tracer
Skills › Knowledge Work Plugins › month-end-prep › xero-reconcile.md

xero-reconcile.md

175 lines · small-business/skills/month-end-prep/reference/xero-reconcile.md at 2574e29

Open on GitHub

Most marks come from matching words in the file, so treat them as pointers.

1# Xero — Reconciliation Reference
2
3Sibling of [quickbooks-reconcile.md](quickbooks-reconcile.md). Same close
4sequence, same packet; the reads and the "needs attention" signal differ
5because Xero's data model does.
6
7**Tool names below come from the Xero connector's published surface.
8Confirm each against the connected server before the first live close.**
9
10---

Xero — Reconciliation Reference

Sibling of quickbooks-reconcile.md. Same close sequence, same packet; the reads and the "needs attention" signal differ because Xero's data model does.

Tool names below come from the Xero connector's published surface. Confirm each against the connected server before the first live close.


Raw lines 1 to 11
12## Reports to pull

Reports to pull

Raw lines 12 to 13
14### Profit & Loss
16`get_profit_and_loss` for the target month, first to last day. Accrual basis
17unless the owner runs cash. Same downstream fields as the QuickBooks path:
18total revenue, gross profit, net income, total operating expenses.

Profit & Loss

get_profit_and_loss for the target month, first to last day. Accrual basis unless the owner runs cash. Same downstream fields as the QuickBooks path: total revenue, gross profit, net income, total operating expenses.

Raw lines 14 to 19
20### The register — what "every line item" means in Xero
22Xero has no single monthly transaction-register read. The register for the
23close is three things, pulled separately:
25| Part | Tool | What it holds |
26|---|---|---|
27| Bills | `get_bills` with `include_line_items=true` | Supplier invoices, paid and unpaid |
28| Invoices | `get_invoices` with `include_line_items=true` | Customer invoices, paid and unpaid |
29| Bank queue | `get_bank_account_transactions` | Bank-feed lines, reconciled and unreconciled |
31`get_bank_account_transactions` is not the monthly register on its own; its
32own description says not to treat it that way. Bills and invoices carry the
33coded detail; the bank queue carries what has and has not been matched.
35**State the scope in the packet.** The "Reconciled" line reads: *"Xero
36(ledger: bills, invoices, and bank transactions for the month)."* An
37accountant reading the packet needs to know the register was assembled from
38documents plus bank lines, not exported as one report.
40Key fields:
42| Field | Notes |
43|---|---|
44| `date` | Document or bank line date |
45| `status` | `AUTHORISED` (approved, unpaid), `PAID`, `DRAFT`, `VOIDED`. Drafts are excluded from the close |
46| `contact.name` | Supplier or customer |
47| `total` | Document total; compare to bank line amount when matching |
48| `account_code` | GL account on each line item |
49| `line_item_cardinality` | Number of lines on the document. Above 1 means a split |
50| `has_attachments` | Present only when `include_line_items=true` |
51| `is_reconciled` (bank line) | Whether the bank-feed line has been matched to a document |
53---

The register — what "every line item" means in Xero

Xero has no single monthly transaction-register read. The register for the close is three things, pulled separately:

PartToolWhat it holds
Billsget_bills with include_line_items=trueSupplier invoices, paid and unpaid
Invoicesget_invoices with include_line_items=trueCustomer invoices, paid and unpaid
Bank queueget_bank_account_transactionsBank-feed lines, reconciled and unreconciled

get_bank_account_transactions is not the monthly register on its own; its own description says not to treat it that way. Bills and invoices carry the coded detail; the bank queue carries what has and has not been matched.

State the scope in the packet. The "Reconciled" line reads: "Xero (ledger: bills, invoices, and bank transactions for the month)." An accountant reading the packet needs to know the register was assembled from documents plus bank lines, not exported as one report.

Key fields:

FieldNotes
dateDocument or bank line date
statusAUTHORISED (approved, unpaid), PAID, DRAFT, VOIDED. Drafts are excluded from the close
contact.nameSupplier or customer
totalDocument total; compare to bank line amount when matching
account_codeGL account on each line item
line_item_cardinalityNumber of lines on the document. Above 1 means a split
has_attachmentsPresent only when include_line_items=true
is_reconciled (bank line)Whether the bank-feed line has been matched to a document

Raw lines 20 to 54
55## The "needs attention" signal: unreconciled bank lines, not uncategorized
57Xero requires an account code when a bank line is reconciled, so the
58QuickBooks categories ("Uncategorized Expense," "Ask My Accountant") do not
59arise. The equivalent signal is **bank lines still unreconciled at month end**:
60money that moved but has not been matched to a bill, invoice, or spend/receive
61transaction.
63Step 2 for a Xero ledger reports:
65```
66Unreconciled bank lines: 14 lines, AUD 6,240 across 2 accounts
67```
69and lists them for the owner to reconcile in Xero before the close advances.
70The Step 6 summary block's "Needs attention" row carries this count.
72Do not present an unreconciled line as an error. It is work not yet done,
73and the owner may have a reason (a payout not yet split, a supplier bill not
74yet entered). Name it, count it, and let them decide.
76---

The "needs attention" signal: unreconciled bank lines, not uncategorized

Xero requires an account code when a bank line is reconciled, so the QuickBooks categories ("Uncategorized Expense," "Ask My Accountant") do not arise. The equivalent signal is bank lines still unreconciled at month end: money that moved but has not been matched to a bill, invoice, or spend/receive transaction.

Step 2 for a Xero ledger reports:

Unreconciled bank lines:   14 lines, AUD 6,240 across 2 accounts

and lists them for the owner to reconcile in Xero before the close advances. The Step 6 summary block's "Needs attention" row carries this count.

Do not present an unreconciled line as an error. It is work not yet done, and the owner may have a reason (a payout not yet split, a supplier bill not yet entered). Name it, count it, and let them decide.


Raw lines 55 to 77
78## Duplicate detection: scan documents, not bank lines
80A bill entered twice in Xero sits as two `AUTHORISED` documents and produces
81**no bank line until one of them is paid**. A bank-side duplicate scan cannot
82see it. For a Xero ledger, Step 4 scans bills and invoices:
84Flag a pair as a suspected duplicate when all four hold:
86- Same `contact.name`
87- Same `total` (within 0.01 in the business currency)
88- Dated within 5 calendar days of each other
89- Both unpaid (`AUTHORISED`), or one unpaid and one paid within the window
91Present pairs to the owner exactly as the QuickBooks path does. Recurring
92weekly bills from the same supplier are the usual false positive.
94**Splits are one document.** A bill with several line items is one document
95with `line_item_cardinality` above 1. The QuickBooks rule "group by `TxnID`
96before comparing" maps to "compare documents, never lines" here. Two lines on
97one bill are never a duplicate pair.
99---

Duplicate detection: scan documents, not bank lines

A bill entered twice in Xero sits as two AUTHORISED documents and produces no bank line until one of them is paid. A bank-side duplicate scan cannot see it. For a Xero ledger, Step 4 scans bills and invoices:

Flag a pair as a suspected duplicate when all four hold:

  • Same contact.name
  • Same total (within 0.01 in the business currency)
  • Dated within 5 calendar days of each other
  • Both unpaid (AUTHORISED), or one unpaid and one paid within the window

Present pairs to the owner exactly as the QuickBooks path does. Recurring weekly bills from the same supplier are the usual false positive.

Splits are one document. A bill with several line items is one document with line_item_cardinality above 1. The QuickBooks rule "group by TxnID before comparing" maps to "compare documents, never lines" here. Two lines on one bill are never a duplicate pair.


Raw lines 78 to 100
101## Receipts: check the document first, then the folder
103Xero stores attachments on the bill or invoice. Before scanning a receipts
104folder (Step 5), read `has_attachments` on each expense document above the
105attention threshold. It is returned only when `include_line_items=true` is
106passed to `get_bills` and `get_invoices`; without that parameter the field is
107absent and every document looks receipt-less.
109- `has_attachments = true` → "receipt on file (Xero)"
110- `false` → fall back to the folder scan, then to asking the owner
112Payments made straight from the bank feed with no bill behind them (a
113spend-money transaction) have no document to attach to. Treat those like a
114QuickBooks expense with no attachment.
116---

Receipts: check the document first, then the folder

Xero stores attachments on the bill or invoice. Before scanning a receipts folder (Step 5), read has_attachments on each expense document above the attention threshold. It is returned only when include_line_items=true is passed to get_bills and get_invoices; without that parameter the field is absent and every document looks receipt-less.

  • has_attachments = true → "receipt on file (Xero)"
  • false → fall back to the folder scan, then to asking the owner

Payments made straight from the bank feed with no bill behind them (a spend-money transaction) have no document to attach to. Treat those like a QuickBooks expense with no attachment.


Raw lines 101 to 117
118## Processor settlements: the payout is already a ledger line
120Xero customers commonly receive Square, Stripe, and PayPal payouts through a
121bank feed. The payout is therefore already in the ledger as a bank line, and
122the reconciliation question is whether that line has been matched, not
123whether a ledger line exists.
125Step 3 for a Xero ledger:
1271. Among the unreconciled bank transactions, find lines whose payee or
128 reference names a processor (Square, Stripe, PayPal, Shopify Payments).
1292. List them per processor as the action items: *"Stripe: 4 payouts,
130 AUD 3,180, unreconciled."*
1313. Match reconciled processor lines to the processor's settlement report
132 net-to-net as usual, for fee verification. Keep the settlement CSV path
133 for a processor with no bank feed or when the owner wants fees checked.
135A processor payout with no bank line at all (feed not set up, or a manual
136bank) falls back to the CSV match in
137[paypal-settlements.md](paypal-settlements.md).
139---

Processor settlements: the payout is already a ledger line

Xero customers commonly receive Square, Stripe, and PayPal payouts through a bank feed. The payout is therefore already in the ledger as a bank line, and the reconciliation question is whether that line has been matched, not whether a ledger line exists.

Step 3 for a Xero ledger:

  1. Among the unreconciled bank transactions, find lines whose payee or reference names a processor (Square, Stripe, PayPal, Shopify Payments).
  2. List them per processor as the action items: "Stripe: 4 payouts, AUD 3,180, unreconciled."
  3. Match reconciled processor lines to the processor's settlement report net-to-net as usual, for fee verification. Keep the settlement CSV path for a processor with no bank feed or when the owner wants fees checked.

A processor payout with no bank line at all (feed not set up, or a manual bank) falls back to the CSV match in paypal-settlements.md.


Raw lines 118 to 140
141## Country, currency, and financial year
143`get_organisation_info` returns the organisation's base currency and country;
144`get_organisation_financial_year` returns the year end. Read them once at
145the start of the close if the business context does not already carry them,
146and use them for:
148- Every amount in the packet (`AUD 12,400`, never `$`)
149- The 0.50 / 0.01 / 25 thresholds, which are in the base currency
150- Whether Step 9 offers `/tax-prep` at all (US only)
152The rule is `../../../shared/currency-and-locale.md`.
154---

Country, currency, and financial year

get_organisation_info returns the organisation's base currency and country; get_organisation_financial_year returns the year end. Read them once at the start of the close if the business context does not already carry them, and use them for:

  • Every amount in the packet (AUD 12,400, never $)
  • The 0.50 / 0.01 / 25 thresholds, which are in the base currency
  • Whether Step 9 offers /tax-prep at all (US only)

The rule is ../../../shared/currency-and-locale.md.


Raw lines 141 to 155
Names a skill tax-prep :150
156## Graceful degradation — Xero not connected or not authorised
158Take this path only when no Xero entry works. An unauthorized `small-business:xero`
159beside the owner's own live Xero is connected — call the owner's entry instead
160(`../../../shared/connector-neutrality.md`, "One connector, two registrations").
162Ask for **two exports** from Xero: the **Profit and Loss** report for the
163month, and the **Account Transactions** report with all accounts selected for
164the same period. One does not contain the other. The Account Transactions
165report is the register; unreconciled lines do not appear in it, so ask the
166owner for the unreconciled count from the bank reconciliation screen as a
167third item, or say in the packet that it was not available.
169---

Graceful degradation — Xero not connected or not authorised

Take this path only when no Xero entry works. An unauthorized small-business:xero beside the owner's own live Xero is connected — call the owner's entry instead (../../../shared/connector-neutrality.md, "One connector, two registrations").

Ask for two exports from Xero: the Profit and Loss report for the month, and the Account Transactions report with all accounts selected for the same period. One does not contain the other. The Account Transactions report is the register; unreconciled lines do not appear in it, so ask the owner for the unreconciled count from the bank reconciliation screen as a third item, or say in the packet that it was not available.


Raw lines 156 to 170
171## Pagination and limits
173Each read returns a page. Request the month in one call per bank account and
174one per document type, and page until the response says there is no more.
175Do not stop at the first page and call the register complete.

Pagination and limits

Each read returns a page. Request the month in one call per bank account and one per document type, and page until the response says there is no more. Do not stop at the first page and call the register complete.

Raw lines 171 to 175