Skip to main content
Glama
ppiotis

Xero Practice Aggregator MCP

by ppiotis

Payroll risk ranking

payroll_risk
Read-onlyIdempotent

Rank client orgs by payroll shortfall risk: compare cash minus bills due before payday against average wages; coverage below 1.0 flags a shortfall.

Instructions

Ranks orgs by how close they are to missing their next payroll. coverage = (cash in bank - bills due on or before payroll date) / payroll amount. Below 1.0 means a shortfall. Payroll amount defaults to the average of wages/salaries P&L lines over the last 3 months, next payroll date to the next 25th; override with set_payroll_profile. Shows the formula with numbers for each org.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
as_ofNoReport date (YYYY-MM-DD). Defaults to today (demo mode: 2026-09-30).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint and destructiveHint=false, so the safety profile is covered. The description adds genuinely useful behavior beyond that: how coverage is computed, the exact default assumptions (3-month average of wages/salaries P&L lines, next 25th payroll date), and that the formula is returned with numbers per org.

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?

Four tight sentences: the purpose and threshold first, then the formula, then the defaults and the override path, then the output note. Nothing is redundant and the most decision-relevant facts are front-loaded.

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

Completeness4/5

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

For a read-only, single-optional-parameter ranking tool with no output schema, the description covers purpose, metric definition, default assumptions, and output shape adequately. Minor gaps remain: it doesn't say whether results cover all connected orgs or how the ranking is ordered/limited.

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

Parameters3/5

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

There is a single optional parameter (as_of) with 100% schema description coverage, including its format pattern and demo-mode default, so the schema carries the load. The description adds nothing about as_of semantics (e.g. whether historical dates recompute defaults), which is the baseline-3 expectation when schema coverage is complete.

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

Purpose5/5

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

The description names a specific verb and resource ('Ranks orgs') plus the exact quantity ranked ('how close they are to missing their next payroll'). It also defines the metric outright (coverage formula, 1.0 threshold), so an agent can distinguish it from siblings like client_health or overdue_invoices without opening the schema.

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?

It gives concrete context for invocation (assessing payroll shortfall risk) and explicitly routes the agent to set_payroll_profile when the default payroll amount or date assumptions must be overridden. It does not state when NOT to use this versus other risk-oriented siblings, so it falls short of a full when/when-not/alternatives treatment.

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