Skip to main content
Glama
Dolibarr MCP Server

Dolibarr MCP Server

Validate a supplier invoice, set it back to draft or delete it

dolibarr_supplier_invoice_action
Destructive

Validate a supplier invoice, return an unpaid invoice to draft, or permanently delete it—preview changes first and require confirmation plus an audit reason.

Instructions

Moves a supplier invoice to another status. Actions: validate (the draft gets its final ref and becomes payable; this is an accounting document); set_draft (an unpaid validated invoice goes back to draft); delete (deletes the supplier invoice permanently). This step cannot simply be undone: without confirm=true it only returns a preview.

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": {
      "supplier_invoice_id": "<supplier_invoice_id>",
      "action": "<action>"
    },
    "name": "dolibarr_supplier_invoice_action"
  }
}

Input Schema

NameRequiredDescriptionDefault
actionYes
reasonNoOne line on why, kept in the audit log. Required when confirm is true.
confirmNofalse (default) = change nothing, only show what would happen. true = do it. Set true only after the user has explicitly agreed to this exact step.
supplier_invoice_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.7/5.0
Behavior5/5

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

The description adds substantial behavior beyond annotations: it explains that validate creates the final accounting reference and makes the invoice payable, that delete is permanent, and that without confirm=true the tool returns a preview rather than making the change. These are exactly the side effects an agent needs before calling a destructive tool.

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 text is dense and front-loaded: the general purpose comes first, action semantics follow, and the confirm warning is placed last. Every clause adds information, with no repeated or redundant wording.

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?

For a four-parameter destructive mutation tool without an output schema, this covers the critical gaps: what each action does, the preconditions, and the preview-only default. The remaining parameter details, including reason length and allowed values, are fully specified in the schema.

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?

The description adds meaning to the action enum by explaining what each value does and what state it requires. It also reinforces the confirm parameter's preview-versus-execute semantics. The reason parameter is left to the schema, which is acceptable given 50% schema coverage and the reason field's clear schema description.

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 first sentence names a specific verb and resource ('Moves a supplier invoice to another status'), and the enumeration of the three actions makes the scope unambiguous. An agent can immediately distinguish this from sibling get/search/create tools because the description only deals with status transitions.

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 per-action preconditions: validate is for a draft that will become payable, set_draft only applies to an unpaid validated invoice, and delete removes permanently. It also explains the confirm gate for preview versus execution. It stops short of naming sibling alternatives or exclusions, but the action-selection guidance is clear.

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