Skip to main content
Glama

Update invoice

mercoa_update_invoice
Destructive

WRITE — updates an existing invoice/bill (all fields optional). Commonly used to advance status (e.g. DRAFT→NEW→SCHEDULED) or change amounts, dates, or payment methods. POST /invoice/{invoiceId}.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
amountNoTotal invoice amount.
statusNoNew invoice status, e.g. NEW, APPROVED, SCHEDULED.
dueDateNoDue date (ISO 8601).
payerIdNoPayer entity ID.
currencyNoCurrency code, e.g. USD.
metadataNoArbitrary key/value metadata.
vendorIdNoVendor entity ID.
invoiceIdYesInvoice ID to update.
lineItemsNoReplacement line items array.
noteToSelfNoInternal note.
invoiceDateNoInvoice date (ISO 8601).
deductionDateNoScheduled payment/deduction date (ISO 8601).
invoiceNumberNoHuman-readable invoice number.
paymentSourceIdNoPayment method ID to pay from.
paymentDestinationIdNoPayment method ID to pay to.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior3/5

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

Annotations already indicate destructiveHint=true. The description adds WRITE label and example status progression, which provides some behavioral context beyond annotations, but not extensive detail.

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 a single sentence with prefix 'WRITE', followed by examples and endpoint. No redundant information, perfectly 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 tool with 15 parameters and nested objects, the description covers high-level purpose and typical usage. No output schema, but endpoint and common modifications are included.

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 coverage is 100%, so baseline is 3. The description notes all fields are optional for partial updates, adding value beyond schema descriptions.

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 it updates an existing invoice/bill, gives concrete examples like advancing status or changing amounts, and differentiates from create_invoice and get_invoice via context.

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?

The description provides common use cases such as status advancement and field changes, and implies partial updates. It could explicitly mention alternatives, but the sibling list and context make it clear.

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.