Skip to main content
Glama
Prime MCP Server

Prime MCP Server

by MikahDev

prime_update_ap_invoice

Update an accounts payable invoice by invoice ID using the current version for optimistic locking. Change fields like totals, dates, invoice number, description, or notes.

Instructions

Update an accounts payable invoice. Requires version for optimistic locking.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "invoice_id": "<invoice_id>",
      "version": "<version>"
    },
    "name": "prime_update_ap_invoice"
  }
}

Input Schema

NameRequiredDescriptionDefault
notesNo
totalNoCurrency amount (must be >= 0)
versionYesCurrent version for optimistic locking
due_dateNo
subtotalNoCurrency amount (must be >= 0)
invoice_idYesThe invoice ID to update
tax_amountNoCurrency amount (must be >= 0)
descriptionNo
invoice_dateNo
invoice_numberNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.9/5.0
Behavior3/5

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

With no annotations supplied, the description carries the full burden, and it does disclose one genuinely useful behavioral trait: optimistic locking via a required version. It does not say whether this is a full replacement or partial update, what happens on a version mismatch (error type? retry?), whether fields omitted are cleared or preserved, or what permissions are required for a financial mutation.

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?

Two short sentences, front-loaded with the action, with no filler or repetition. The brevity is efficient, though it borders on under-specification given the tool's complexity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

A ten-parameter financial mutation with no annotations, no output schema, and half the parameters undocumented needs far more than two sentences. Missing update semantics (full vs partial), version-mismatch behavior, and required permissions leave the agent likely to call it incorrectly.

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

Parameters2/5

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

Ten parameters with only 50% schema description coverage, and the description only echoes the version parameter that the schema already documents. The monetary fields (subtotal, total, tax_amount), invoice_date, due_date, invoice_number, notes, and description have no semantic explanation in either place, and the description adds nothing about how total/subtotal interact.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource ("Update an accounts payable invoice"), which cleanly separates it from siblings like prime_create_ap_invoice and prime_get_ap_invoice. It does not, however, differentiate itself from prime_update_ap_invoice_status, which also mutates the same resource, so an agent must infer that this tool edits fields while the sibling changes status.

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

Usage Guidelines2/5

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

There is no guidance on when to use this tool versus prime_update_ap_invoice_status or the other invoice siblings, and no stated preconditions beyond the version requirement. The agent gets no explicit when-not-to-use conditions and must derive routing from names alone.

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

Deploy Server

Other Tools