Skip to main content
Glama

reconcile_payments

Read-onlyIdempotent

Reconcile order ledger, PSP captures, and bank deposits in a three-way check, flag fee and payout breaks against contract terms, and return match rates, settlement status, and break IDs.

Instructions

Three-way reconciliation of the order ledger, PSP captures and bank deposits.

Fees are checked against the contract version in force on each transaction date. Payouts not yet due under the contract's payout delay show as in_transit, not missing.

Args: date_from: First order date to include, YYYY-MM-DD (inclusive). Omit for all. date_to: Last order date to include, YYYY-MM-DD (inclusive). Omit for all. as_of: Date to judge payout lateness from, YYYY-MM-DD. Defaults to today.

Returns a summary (match rate, value in breaks), warnings about missing data, per-payout settlement status, and every break with an id for explain_reconciliation_break.

Input Schema

NameRequiredDescriptionDefault
as_ofNo
date_toNo
date_fromNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.2/5.0
Behavior4/5

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

The annotations already declare readOnly, idempotent and non-destructive, so the description doesn't need to restate safety. Instead it adds real behavioral context: fees are checked against the contract version in force on each transaction date, and payouts not yet due under the contract's payout delay are classified as in_transit rather than missing. That preempts a likely misinterpretation of results, though it says nothing about runtime cost or data freshness.

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

Conciseness4/5

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

The purpose is front-loaded in one sentence and the behavioral caveats follow before the Args block, so the structure matches how an agent reads it. The Args formatting is slightly verbose for three parameters, but nothing is padding.

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 three-param read-only tool with an output schema, the definition covers purpose, arg semantics, result shape, warnings for missing data, and the handoff to explain_reconciliation_break. The one real gap is unstated prerequisites, such as whether data sources or contract terms must already be configured before reconciliation is meaningful.

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

Parameters5/5

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

Schema description coverage is 0%, so the description has to carry all meaning, and it does: each of the three args is documented with format (YYYY-MM-DD), inclusivity, 'omit for all' semantics, and the as_of default of today. The description fully compensates for the bare schema.

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 first sentence names a specific operation and its three data sources: 'Three-way reconciliation of the order ledger, PSP captures and bank deposits.' That is far more precise than a sibling like explain_reconciliation_break, which only explains a single break, so the agent can separate the two.

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

Usage Guidelines3/5

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

The description implies the workflow (each break id feeds explain_reconciliation_break) and says to omit the date args for all dates, but it never states when to run reconciliation versus alternatives such as preview_import or list_data_sources, or what prerequisites (configured data sources, contract terms) must hold.

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