Skip to main content
Glama

Invio Xero MCP

get_xero_profit_and_loss

get_xero_profit_and_loss
Read-only

Profit and Loss report from Xero for the current organisation, for a date range. Read-only. columns gives the period label(s) for the numbers in each row; rows are flattened from Xero's nested section layout (section names the enclosing group, e.g. "Income" or "Operating Expenses"; rowType "SummaryRow" marks a subtotal/total, not a line item - do not double-count a SummaryRow alongside the rows it totals). currency comes from this organisation's own Xero settings, never assumed from anything about the Invio account asking the question - state it whenever relaying a figure from this report. fromDate and toDate must be supplied TOGETHER or OMITTED TOGETHER - never just one; supplying only one is rejected rather than silently widened (see each argument's own description for why). This organisation's financial year is NOT necessarily the calendar year (added 11 September 2026 - see lib/xero/financial-year.ts). financialYear in the result names the organisation's real financial year end and its exact current/previous dates, or says the year end is unknown. Never answer "this financial year", "last financial year", or "year to date" from the calendar year or the organisation's country - use financialYear's dates as fromDate/toDate, and state the period you actually used when relaying a figure.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toDateNoEnd date, YYYY-MM-DD. Must be supplied together with fromDate, or omitted together with it - never alone, for the identical reason. Omit both to get the CURRENT calendar month.
fromDateNoStart date, YYYY-MM-DD. Must be supplied together with toDate, or omitted together with it - never alone (Xero would default toDate to the end of the CURRENT month, not the month fromDate is in). Omit both to get the CURRENT calendar month.
organisationNoThe Xero organisation to use, by its display name. Only needed if this connection reaches more than one organisation - omit it when there is only one.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already mark the tool as read-only and open-world, and the description goes well beyond them by warning that SummaryRow totals must not be double-counted, that supplying only one date is rejected, and that currency comes from the organisation's own Xero settings. It also discloses that the financial year may not match the calendar year and explains how to derive date parameters from financialYear.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long but each sentence addresses a real failure mode, output nuance, or derivation rule, such as double-counting SummaryRows and deriving dates from financialYear. It is front-loaded with the core purpose and structured so that critical warnings are not buried.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description carries the full burden of explaining the result shape, and it names columns, rows, section, rowType, currency, and financialYear. It also tells the agent which period label to state when relaying figures and how to avoid calendar-year assumptions, making it complete enough for correct invocation and interpretation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Parameter schema coverage is 100%, so the baseline is 3; the description adds value by explicitly stating the together-or-omit-both rule, the rejection of a single date, and the 'omit both for current calendar month' convention. It does not add new meaning for the organisation parameter beyond the schema's guidance, so 4 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly identifies the resource as a Profit and Loss report from Xero for the current organisation and date range, and adds detail about the columns and rows returned. It does not explicitly contrast it with sibling report tools such as get_xero_balance_sheet, so it stops short of full sibling differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives strong when-to-use context: it is a read-only report, requires paired dates or no dates, and explains the effect of omitting both dates. It does not name alternative tools or say 'use this instead of X', but the report name and read-only framing make the primary use case clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources