Skip to main content
Glama

invoice_adjustment_record

[REQUIRES APPROVAL] Records a credit note, write-off or post-issue discount on an issued invoice. A credit_note is numbered from the credit note series, holds its tax at the invoice's rate and takes reason_code and credit_outcome: reduce_balance (default) lowers what is owed; refunded_outside records a refund the business made outside Simpler, moves no money and is how a 'paid' invoice gets one. write_off and discount_post_issue need a 'sent' invoice. Money is integer CENTS (amount_cents) or a decimal STRING (amount); caps: see preconditions. Refuses a draft, a cancelled invoice, an amount over its cap and dispute_settlement; each refusal names the fix. An agent's call parks for approval. NEXT: invoice_read.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "invoice_adjustment_record"
  }
}

Input Schema

NameRequiredDescriptionDefault
amountNoMoney as a decimal STRING ("1500.00" = $1,500.00), parsed server-side. Use amount_cents for integer CENTS instead — never convert units yourself.
reasonNo
partialNoConfirms a deliberate PARTIAL write_off below the invoice's full remaining balance (checked only when adjustment_type is write_off) — resend the SAME call with partial:true; without it a below-remainder write_off refuses as a likely mis-carried amount.
currencyNo
invoice_idNo
occurred_atNo
reason_codeNo
amount_centsNo
credit_outcomeNo
invoice_numberNoAlias of invoice_id — the invoice's own number (tenant-unique), resolved server-side.
adjustment_typeNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Far exceeds the annotations: it discloses that the call requires approval and parks for approval, that credit notes draw from a numbered series and inherit the invoice's tax rate, that refunded_outside moves no money, what is refused (draft, cancelled, over-cap, dispute_settlement), and the retry semantics for partial write-offs. Mutations, side effects and failure modes are all surfaced.

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 approval requirement is bracketed at the very front, then type semantics, then units, then refusals, then the next call. Dense but every clause carries a decision-relevant fact; nothing is filler.

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 mutation with no output schema and an approval gate, it covers preconditions, side effects, unit handling and the follow-up read. It does not describe what the parked call returns (pending id, approval state), which leaves a small gap an agent will hit after the call.

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?

Schema coverage is only 27% with 11 params, so the description must carry weight and largely does: it defines amount_cents as integer CENTS vs amount as a decimal string with 'never convert units yourself', ties credit_outcome values to balance effects, and explains partial as a deliberate confirmation resent with partial:true. Gaps remain for reason, currency and occurred_at, which are undocumented in both places.

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?

Opens with a specific verb and named resource set: 'Records a credit note, write-off or post-issue discount on an issued invoice.' The three adjustment kinds are enumerated, letting an agent distinguish this from invoice_adjustment_read/list/delete and from invoice_debit_note without opening a 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?

Explains selection conditions inside the tool: write_off and discount_post_issue require a 'sent' invoice, credit_outcome chooses reduce_balance vs refunded_outside, and each refusal names the fix. It also routes forward with 'NEXT: invoice_read'. It stops short of explicitly naming sibling alternatives (e.g. invoice_debit_note) as the right call for a different need.

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