Skip to main content
Glama

Record document payment

record_document_payment

Record a payment against any document, in either direction. A money-in document (invoice, recurring invoice, quote, debit note) records the payment as an income; a money-out document (bill, purchase order, GRN, credit note) is settled by recording an expense whose accountid is the document's id — the tool dispatches on the document's direction, so pass the document id and the payment details either way.

Input Schema

TableJSON 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

A3.7/5.0
Behavior3/5

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

The annotations already indicate readOnlyHint=false and destructiveHint=false, meaning the tool performs a write but is not destructive. The description does not disclose additional behavioral aspects beyond what the annotations state, such as authentication requirements, rate limits, or side effects like creating a payment record. It adds no extra transparency.

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 description is a single sentence that front-loads the main verb and action. It could be slightly more concise, as it repeats 'either direction' and lists document types twice, but it remains well-structured and immediately understandable. It earns a 4 for being largely succinct while still thorough.

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?

The description covers the core action and the document types involved, which is sufficient given there is no output schema. It doesn't mention return values or postconditions, but the absence of an output schema reduces the need for that. It is complete enough for the tool's context.

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?

The schema provides 100% description coverage for all parameters, so the baseline is 3. The description repeats some parameter details (e.g., the 'id' field meaning the payment id on update) but does not add significant new semantics beyond the schema's own descriptions. It is neither redundant nor insufficient.

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 explicitly states the action 'Record a payment against any document' and clarifies the two directions (money-in vs money-out) with specific document types. It is distinct from sibling tools like settle_bills or save_expense by focusing on recording a payment rather than settling or saving. This fully clarifies the tool's purpose.

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 clearly defines the tool's own scope, but it does not explicitly mention when to use this tool over alternatives (e.g., when to use settle_bills vs record_document_payment). It lacks explicit 'when not to use' guidance, so it meets the baseline but does not exceed it.

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