Skip to main content
Glama
ninetails-io

gnucash-mcp

unpost_document

DestructiveIdempotent

Reverse a posted invoice, bill, voucher, or credit note back to open state for editing. Void any applied payments first; otherwise the reversal is refused.

Instructions

Reverse a posted customer invoice, vendor bill, employee voucher, or credit note (each keeps its type through the round-trip).

Deletes the posting transaction and lot, and clears the invoice's posted-state metadata. The invoice returns to "open" state and can be edited or re-posted. Refuses if the invoice has any payments applied — void payments first, then unpost.

Args: id: Document ID (e.g., "000001"). document_type: "invoice", "bill", "voucher", or "credit_note" — disambiguates when IDs collide. party_type: Owner side, credit notes only.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
party_typeNo
document_typeNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Addedv1.4.4

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already signal destructiveness and idempotency, but the description adds substantial behavioral detail beyond them: it deletes the posting transaction and lot, clears posted-state metadata, returns the document to 'open' state, and refuses when payments exist. This gives the agent a clear model of side effects and preconditions.

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 well-structured: purpose, behavior, refusal condition, then argument explanations. Each sentence contributes useful information without redundancy or filler, making it easy for an agent to parse quickly.

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

Completeness5/5

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

Given that an output schema exists, the description does not need to detail return values, and it covers the essential operational aspects: what gets deleted, what state results, what blocks execution, and how parameters disambiguate. The destructive and idempotent hints are reinforced with concrete behavioral context, leaving little an agent needs to infer.

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 description coverage is 0%, so the description must compensate, and it does: it explains id with an example, document_type with its accepted values and disambiguation purpose, and party_type as 'Owner side, credit notes only.' This adds real meaning beyond the raw schema, though party_type could be a bit more explicit about when it is required.

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 opens with a specific verb and resource: 'Reverse a posted customer invoice, vendor bill, employee voucher, or credit note.' It clearly describes what the tool does and helps distinguish it from closely related siblings like delete_document or void_transaction by emphasizing the reverse-posting workflow and the round-trip type preservation.

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 gives clear usage context: it applies to posted documents that need to return to an editable state, and it explicitly warns that unposting is refused if payments are applied, directing the agent to void payments first. It does not explicitly contrast with sibling tools, but the operational conditions are strong enough for correct selection.

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ninetails-io/gnucash-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server