Work snippetAI receivables
AI aged-receivables assistant for Xero: follow-ups for approval and a weekly cashflow summary
How I would approach about US$248,000 owing across 47 customers for a 20-tech commercial service business: follow-ups drafted from each customer's payment history for a person to edit and send, and a weekly cash summary whose every figure is checked against Xero. Nothing is sent automatically.
Work snippet with example figures.
- Area
- AI receivables
- Tools
- Xero · n8n · Airtable · Mailbox drafts
- Typical scope
- US$1,800–3,200
- Timeline
- About 6 weeks · 4 fixed milestones
Problem
What the owner sees
- A long aged receivables list and no time to write to each customer
- Reminders that read the same for a customer who always pays and one who never does
- Overdue invoices chased while the job is still in dispute
- No clear view of what cash will arrive in the next four weeks
- A tool that emails customers by itself
Chasing is mostly reading: who owes what, how they usually pay, and what was said last time. A model can draft each message from those facts quickly. It must not send anything, and it must not state a number that did not come from Xero. The design drafts, a person edits and sends, and every figure in the text comes from the data.
| Everyday situation | What goes wrong |
|---|---|
| Reminder sent for an invoice paid yesterday | The customer is annoyed and the credit controller embarrassed |
| Same wording to every customer | Good payers are insulted and poor payers ignore it |
| Dispute noted on a job, not in Xero | A firm letter goes to someone waiting for a fix |
| Several overdue invoices for one customer | Five separate emails instead of one statement-style message |
| Cashflow estimated in a spreadsheet | Built once, never updated, wrong by the third week |
| An auto-send tool | A message goes out on a bad day with a wrong figure |
System map
A 20-tech commercial service business with about US$248,000 owing across 47 customers. A part-time credit controller chases by email and phone, and the owner wants a short cash view each Monday. Jobs run in ServiceM8 or Jobber and the ledger is in Xero.
The example drafts personalised follow-ups by customer history and puts them in a queue. The credit controller edits, approves and sends from their own mailbox. A weekly summary of cash is drafted from figures computed from Xero.
| Part | What it does |
|---|---|
| Xero | Open invoices, contacts, payments, aged receivables and bills due. Read only. |
| History table | Per customer: average days to pay, late payments in the last 12 invoices, last contact and any dispute flag. |
| Job system | Job status for each invoice, so work that is incomplete or disputed is excluded. |
| Language model | Drafts message wording from facts that code supplies. It does no arithmetic. |
| Review queue | Each draft with the facts used, the reason it was drafted and the invoice list. |
| Mailbox | The credit controller’s own mailbox. The workflow saves drafts there and has no send step. |
| n8n workflow | Pulls the data, runs the rules, builds the queue and the Monday summary. |
How the data moves
- Xero aged receivables
- History and job status joined
- Stage chosen by rule
- Draft written
- Credit controller edits and sends
- Log updated
- Monday cash summary
Rules agreed in writing
Stages are chosen by rule, not by the model. The model only chooses wording within the stage and the customer’s history.
| Item | Example setting |
|---|---|
| Stage 0 | Due in 3 days or less. No message unless the customer has paid late three times in a row. |
| Stage 1 | 1 to 14 days overdue. A short friendly reminder with the invoice list. |
| Stage 2 | 15 to 45 days overdue. A firm message that asks for a payment date. |
| Stage 3 | Over 45 days or over US$10,000. No email draft. A call is suggested and a note prepared for the owner. |
| Dispute flag | No draft. The owner is told and the item is excluded until the flag is cleared. |
| Tone by history | Usually pays within 5 days of due: light. Late on four of the last twelve: direct. |
| Frequency | One message per customer per 7 days, covering all their overdue invoices. |
| What a draft may contain | Invoice numbers, dates, amounts and balances from Xero. Nothing else numeric. |
Flow steps
Eight steps, run each weekday at 07:30 for follow-ups and Monday 07:00 for the cash summary.
| Step | Trigger | What happens | Result |
|---|---|---|---|
| 1 Pull | Schedule | Open invoices and aged receivables read from Xero. | Invoice list |
| 2 Join | Invoice list | History and job status attached to each customer. | Customer facts |
| 3 Stage | Customer facts | Rules pick a stage, or exclude the customer with a reason. | Stage per customer |
| 4 Draft | Stage 1 or 2 | Model writes the message. Code inserts the invoice table. | Draft with facts |
| 5 Check | Draft ready | Every number in the text compared with Xero. Invoice paid since the pull is removed. | Pass or fail |
| 6 Queue | Check passed | Draft placed in the queue with the reason and facts. | Queue item |
| 7 Approve | Credit controller | Edits, approves, and a draft is saved in their mailbox. | Mailbox draft |
| 8 Log | Credit controller marks sent | Date and wording stored. Next review set in 7 days. | History updated |
Field mapping
The table shows what is read from Xero and where each value is used. The draft facts and the cash numbers are shown in the worked example.
| Xero value | Used for | Rule |
|---|---|---|
| Contact name and email | Addressing the draft | Billing contact if set, otherwise the primary contact |
| Invoice number, date, due date | Invoice table in the draft | Inserted by code, never typed by the model |
| Amount due | Balance and stage | Live from Xero at the check step |
| Payments applied | Days to pay and the stale check | A paid invoice is removed before approval |
| Credit notes and overpayments | Net balance | Shown as a credit line, never ignored |
| Tracking category | Branch or division | Used to route the draft to the right controller |
| Contact notes | Dispute flag | A flag word in the note excludes the customer |
| Bank summary and bills due | Weekly cash summary | Read at 07:00 on Monday |
Edge cases
Each is run as a test customer before go-live.
| Situation | How it is handled |
|---|---|
| Invoice paid after the pull | Removed at the check step. If all are paid, the draft is withdrawn. |
| Customer with a credit note | The credit is shown against the balance in the message. |
| Overpayment on account | No chase draft. A note suggests allocating it. |
| Several billing contacts | The billing contact on the Xero contact is used and the rest are shown in the queue. |
| Customer replies with a promise to pay | The controller records the date. No draft until that date passes. |
| Payment plan agreed | Marked on the history table. Stage rules pause until the plan fails. |
| Large customer, small invoice overdue | Stage 3 rules do not apply below US$1,000 on a good payer, and the item is listed for a call. |
| Xero data unavailable at 07:30 | No drafts that day. An alert goes to the owner. |
| Model returns a number not in the data | Draft rejected and rewritten once, then shown as a plain invoice table. |
Human sign-off and audit trail
There is no send step in the workflow. The credit controller reads every draft and sends it themselves, and the owner approves any stage 3 note.
| Who | Signs off | When | If nobody acts |
|---|---|---|---|
| Credit controller | Every draft, after editing, before it is saved as a mailbox draft | Daily | Drafts wait. Nothing is sent. |
| Credit controller | Sending from their own mailbox | After approval | The draft is not sent |
| Owner | Stage 3 notes and disputes | Weekly | Customer stays excluded |
| Owner | Stage rules, tone settings and summary wording | Before go-live and quarterly | Existing rules stay |
| Owner | The Monday summary, by reading it | Weekly | Summary is a reminder, not a decision |
| Field | Example |
|---|---|
| Draft ID | Queue item number |
| Data pulled | Xero pull time and invoice IDs used |
| Stage and reason | Stage 2, 22 days overdue, usual payer late on 3 of 12 |
| Model | Model name and version, prompt version |
| Number check | Pass, with the list of figures compared |
| Edits | Text before and after, who and when |
| Sent | Marked sent by the controller, date and time |
Data and privacy
Receivables data names customers and amounts. The assistant keeps it inside your own accounts.
| Data | Handling |
|---|---|
| Xero access | Read only for receivables, contacts, payments, bills and the bank summary. |
| Model request | Contains first names, amounts and invoice numbers. Bank details and full addresses are left out. |
| Model use | A hosted model on terms that do not allow training on your data, or a local model. |
| Drafts | Saved in the controller’s mailbox or the queue only. Retention follows your mail policy. |
| Accounts | Xero, n8n and the mailbox stay in your accounts. I am added as a user and removed at handover. |
Worked example
The tables below use example figures for one business. They show the shape of the numbers, not a client result.
| Customer | Current | 1–30 | 31–60 | 61–90 | Over 90 | Total |
|---|---|---|---|---|---|---|
| Property manager, 14 sites | 38,200.00 | 21,400.00 | 9,800.00 | 0.00 | 0.00 | 69,400.00 |
| Retail chain, 6 branches | 27,600.00 | 12,900.00 | 6,400.00 | 0.00 | 0.00 | 46,900.00 |
| Medical practice | 9,400.00 | 0.00 | 3,100.00 | 0.00 | 0.00 | 12,500.00 |
| Builder, 3 active projects | 18,800.00 | 11,200.00 | 14,900.00 | 8,300.00 | 4,200.00 | 57,400.00 |
| School | 6,300.00 | 0.00 | 0.00 | 0.00 | 0.00 | 6,300.00 |
| All other customers (42) | 31,500.00 | 14,700.00 | 5,900.00 | 2,100.00 | 1,500.00 | 55,700.00 |
| Total | 131,800.00 | 60,200.00 | 40,100.00 | 10,400.00 | 5,700.00 | 248,200.00 |
| Fact | Value | Source |
|---|---|---|
| Customer | Retail chain, 6 branches | Xero contact |
| Overdue invoices | 2 invoices, 23 and 41 days overdue | Xero |
| Amount overdue | 19,300.00 | Xero, live at check |
| Usual payment | Pays 6 days late on average | History table |
| Last contact | Phone call 12 days ago, promised payment | History table |
| Stage and tone | Stage 2, direct but polite | Rules |
| Week | Expected in | Bills due | Net | Closing balance |
|---|---|---|---|---|
| Week 1 | 31,200.00 | 26,800.00 | 4,400.00 | 88,700.00 |
| Week 2 | 24,500.00 | 19,300.00 | 5,200.00 | 93,900.00 |
| Week 3 | 28,900.00 | 33,600.00 | -4,700.00 | 89,200.00 |
| Week 4 | 22,700.00 | 17,400.00 | 5,300.00 | 94,500.00 |
Testing and checks
Every check has a written pass condition and fail condition before it is run. A FAIL stops go-live until it is cleared and the check is run again.
| ID | Check | Method | PASS when | FAIL when |
|---|---|---|---|---|
| T1 | Number check | Edit a draft number in a test | Draft rejected and rewritten | Wrong number reaches the queue |
| T2 | Paid invoice | Pay one invoice after the pull | Removed before approval | Still in the draft |
| T3 | Dispute flag | Add the flag word to a contact | No draft, owner told | A draft appears |
| T4 | Stage rules | Run ten test customers at known ages | Every customer in the right stage | Any wrong stage |
| T5 | Tone | Compare drafts for a good and a poor payer | Wording differs as set | Same wording |
| T6 | No send step | Review the workflow and permissions | No node or permission sends mail | Any send route |
| T7 | Summary figures | Recompute the four weeks by hand | Every figure equals the script | Any difference |
| T8 | Summary wording | Insert a number the script did not produce | Summary rejected, table sent instead | Number appears |
| T9 | Xero outage | Block Xero in test | No drafts and an alert | Drafts from old data |
| T10 | Frequency | Run two days running | One message per customer per 7 days | Two drafts for a customer |
Scope and milestones
A fixed scope agreed in writing before anything starts. Each milestone is paid when you sign off its deliverable.
| Area | Included |
|---|---|
| Systems Audit | Review of the aged receivables report, your current chasing routine and the Xero contact setup, a 45-minute call, written findings and a fixed quote |
| Data pull and history table | Xero reads and a per-customer history table |
| Stage rules and tone | Rules written with the credit controller and owner |
| Draft engine and number check | Drafts with code-inserted figures and a comparison to Xero |
| Review queue | Queue with reasons, facts and mailbox drafts |
| Weekly cash summary | Computed figures, drafted wording and a check on every number |
| Testing | Ten checks, run to a pass before go-live |
| Handover | Written SOPs, a recorded handover video and files you own, plus 14 days of fixes after go-live |
| Not included | Tax filing and statutory returns. |
| Also outside the scope | Sending messages automatically. Collections calls or letters. Model usage fees, billed to you by the vendors. Credit policy changes. |
| Milestone | Deliverable | Timing | Share |
|---|---|---|---|
| M1 Rules and history | Stage rules signed and history table loaded | Week 1 | 25% |
| M2 Draft engine | Drafts with the number check, T1 to T5 pass | Weeks 2 to 3 | 30% |
| M3 Queue and summary | Queue, mailbox drafts and the Monday summary, T6 to T10 pass | Week 4 | 30% |
| M4 Handover | Two weeks of supervised use, SOPs, handover video, 14 days of fixes | Weeks 5 to 6 | 15% |
Typical scope for this kind of project: US$1,800–3,200
About 6 weeks across 4 fixed milestones. The Systems Audit (US$300, fixed) comes first and confirms the scope.
Describe what is going wrong between your job system and your books, and I will say where I would look first.
Send a short note through the form on the home page. I will reply with where I would start, and whether the US$300 Systems Audit is the right first step.