Monthly Xero P&L variance narrative for leadership

On the first business day of each month, get a written variance narrative comparing last month's P&L to the prior month and budget, sent to Slack and the CFO.

Agentic Task
XeroSlack BotGmailFinanceAI ReportsDaily Digests
PromptCreate

On the first business day of each month at 9am local time, produce a written variance narrative comparing last month's Profit and Loss against the prior month and against budget, then share it with the leadership team via Slack and email. If the first calendar day of the month falls on a weekend or public holiday, run on the next business day instead.

Data to pull from Xero: run the Profit and Loss Report for last month, run the Profit and Loss Report for the prior month (as the comparative baseline), and run the Budget Summary Report for the same window. If the Profit and Loss Report supports comparative periods in a single call, use that; otherwise pull the two months as separate calls.

Xero returns date fields in the .NET JSON format like /Date(1551830400000+0000)/. Parse the millisecond timestamp before using any date value in the narrative. Money fields are returned as decimal numbers (not cents), and account IDs are opaque GUIDs.

The Profit and Loss report and the Budget Summary report are separately scoped on Xero, so make sure the Xero connection was granted access to both reports when it was set up. If the Budget Summary call comes back empty, the org likely has not loaded a budget for the period, and the narrative should say so plainly rather than skipping the budget comparison silently.

The narrative should read as a plain-English brief for a CEO and leadership team, not a variance table. Cover, in this order:

  • Revenue movement by top revenue account: which lines drove the number and which changed the most against the prior month and budget.

  • Expense movement by category, grouping related accounts sensibly (payroll, marketing, software, contractors, occupancy, and so on). Interpret the direction rather than just listing accounts.

  • Unusual variance items: any single account line that moved by more than the variance threshold versus budget or versus the prior month. For each, name the account, the size of the swing, the plausible driver, and whether it warrants a look.

  • One open question worth flagging on the leadership call: something concrete finance should raise, not a generic 'let us discuss' placeholder.

Once the narrative is written, post it to the configured finance Slack channel using Slack Bot's Send a Message action, and email the same body to the configured CFO email address using Gmail's Send a Message action. Use the same content in both places so leadership reads the same brief wherever they see it. Keep the Slack version formatted for that channel (short paragraphs, mrkdwn if useful) and the Gmail version as a clean plain-text or lightly formatted email.

Expose these as customer-set variables so different organisations can tune the workflow:

  • Fiscal year end (so month boundaries and the current-versus-prior comparison line up with the org's accounting).

  • Finance Slack channel to post into.

  • CFO email address to send to.

  • Variance threshold (default 20%) that decides which line items are called out as unusual.

Additional information

What does this prompt do?
  • Pulls last month's Profit and Loss and Budget Summary from Xero on the first business day of the month
  • Compares the actuals against the prior month and against budget, then flags any line that moved more than a threshold you set
  • Writes a plain-English variance narrative covering revenue by top account, expenses by category, unusual movements, and one open question worth raising on the leadership call
  • Posts the narrative to your finance Slack channel and emails the same content to the CFO
What do I need to use this?
  • A Xero account with access to the Profit and Loss and Budget Summary reports
  • A Slack workspace with a finance channel to post into
  • A Google account we can send email from via Gmail
  • The CFO's email address
How can I customize it?
  • The fiscal year end, so month boundaries and comparisons line up with your accounting
  • The Slack channel and the CFO email address the narrative gets sent to
  • The variance threshold that flags a line as unusual (default 20%)

Frequently asked questions

When exactly does this run?
On the first business day of each month at 9am local time. If the first of the month lands on a weekend or public holiday, the run rolls to the next business day.
What counts as an unusual line item?
Any single account line that moved by more than the variance threshold you set (20% by default) against either the prior month or the budget. You can tune the threshold higher for a quieter narrative or lower to catch smaller swings.
Does this work if my fiscal year does not start in January?
Yes. Set your fiscal year end when you configure the workflow so month boundaries and budget comparisons match your books.
How is this different from the weekly Xero cash flow digest?
The weekly digest looks at cash on hand, overdue customers, and upcoming bills. This one is a monthly P&L story with variance interpretation, aimed at the leadership meeting.
Can I post to a private Slack channel?
Yes, as long as the Slack bot has been added to the channel.

Stop building the monthly variance deck by hand.

Let this workflow pull last month's numbers from Xero and hand your leadership team a written narrative every month.