Skip to main content
Glama

Update document payment

update_document_payment

Correct a payment ALREADY recorded against a document, identified by the payment id (not the document id); to record a new payment, use record_document_payment. Changes its amount, date or account on an invoice, quote, credit note or debit note. Never edit a correct payment to hide an FX or rounding gap; settle the document with save_document settled true instead.

Input Schema

NameRequiredDescriptionDefault
idNoDocument id to record the payment against — a money-in document (invoice / recurring invoice / quote / debit note) or a money-out document (bill / purchase order / GRN / credit note). On update, the payment id.
dateNoDate the payment was received (ISO 8601).
nameNoLabel for this payment (e.g. "Deposit", "Final payment").
notesNoFree-text notes on the payment.
amountNoPayment amount in the payment's currency.
methodNoPayment method as free text (e.g. "cash", "card", "eft") — no fixed set.
paymentNoBank/ledger account id the money moved through — received into (money-in) or paid from (money-out) (see list_accounts).
categoryNoIncome category for the payment; defaults to Sales when omitted.
currencyNoISO 4217 currency code (e.g. "ZAR", "USD"). Defaults to the business currency.
responseidNoInternal: correlation id used to return the updated entity to the frontend; omit.
exchangerateNoManual FX rate to the business base currency; omit to use the stored/auto rate.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

With annotations already declaring readOnlyHint=false and destructiveHint=false, the description adds meaningful behavioral context: this is a correction operation against an existing payment, keyed by payment id, and it warns against editing correct payments to conceal FX/rounding discrepancies. It does not detail ledger effects or whether partial updates are allowed, but the core mutation behavior is clear.

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 compact and front-loaded: it first identifies the operation, then gives the key id distinction and alternative tool, then states the relevant fields, and finally adds a concise integrity warning. Every sentence carries operational value.

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 non-destructive mutation tool with full schema coverage and annotations, the description covers the essential context: what it updates, which identifier to use, the sibling alternative, and an important misuse warning. It does not address partial-update behavior or success/return semantics, but those are secondary given the absence of an output schema and the rich input schema.

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?

Schema description coverage is 100%, so the schema already documents all parameters thoroughly. The description reinforces the critical id semantic (payment id on update, not document id), but that point is also present in the schema, and it does not add further parameter-level guidance beyond the schema baseline.

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 states a specific verb and resource: correct an already recorded document payment, identified by payment id rather than document id. It clearly distinguishes this update tool from the sibling record_document_payment and lists the document types and fields affected.

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

Usage Guidelines5/5

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

It explicitly says when to use this tool (to correct an existing payment) and when to use the alternative (record_document_payment for a new payment). It also gives a concrete negative guideline: do not edit a correct payment to hide an FX or rounding gap, and instead use save_document with settled true.

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