Skip to main content
Glama

Sevdesk book payment

sevdesk_book_payment

Book the payment for a document's voucher in sevDesk, attaching the bank transaction so the voucher settles to 0 open and shows as fully paid. This is the LAST step of the round trip: run it after sevdesk_push_documents has created the voucher and match_invoice_transaction has linked the payment. Without it the voucher stays open in sevDesk even though the payment is linked in Book-AI-ze. Reads the amount and date from the linked bank transaction rather than taking them on trust, and verifies the result by reading the voucher back. REFUSES a voucher that is ALREADY on status 1000: sevDesk does not replace a payment, it stacks a second one, and the result is a double payment on a settled voucher. The check reads sevDesk, not the local status — which is the point, because a local status can be stale. Pass reset_first:true to take the old payment back and book once. The dry run reports voucher_now, so the voucher's real state is visible before anything is written.

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": {
      "document_id": "<document_id>"
    },
    "name": "sevdesk_book_payment"
  }
}

Input Schema

NameRequiredDescriptionDefault
amountNoOverride the amount to book. Rarely needed: the linked transaction's own amount is used by default, which is correct for a full payment including any FX difference. Pass a positive number; the direction is derived from the transaction.
dry_runNoDefault TRUE. Resolves the voucher, transaction and bank account and reports exactly what would be sent, without writing. Pass false to really book it.
document_idYesThe document whose voucher should be marked paid. Must already have a sevdesk_id.
reset_firstNoReset the voucher to open before booking (PUT /resetToOpen). Use this to correct a previous wrong booking — booking again without it stacks a second payment on top. Default false.
transaction_idNoWhich transaction paid it. Optional — defaults to the one already linked to the document, which is what match_invoice_transaction wrote.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only cover the generic safety profile (readOnly=false, destructive=false, idempotent=false); the description goes well beyond them by disclosing that sevDesk stacks a second payment rather than replacing one, that the guard reads sevDesk state rather than a possibly-stale local status, that the amount/date are read from the linked transaction instead of trusted input, and that the result is verified by reading the voucher back. This is exactly the double-payment failure mode an agent needs to know before calling.

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?

Front-loaded with purpose and pipeline position, then the refusal guard, then the recovery option, then the dry-run caveat — a sensible order with no filler. It loses a point for mild repetition around the status-1000 case, which is restated as both 'stacks a second one' and 'a double payment on a settled voucher'.

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?

With no output schema, the description still covers what a dry run returns (voucher_now), what real execution verifies, the default-safe dry-run posture, and the recovery path. Nothing an agent needs to invoke this destructive-adjacent operation correctly is missing.

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 100%, so the baseline is 3 and the schema already documents each parameter. The description nonetheless adds meaningful semantics: dry_run is TRUE by default and reports 'voucher_now', reset_first is the tool for undoing a wrong booking, and amount is rarely needed because the transaction amount is authoritative including FX differences.

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?

States a specific verb and resource ('Book the payment for a document's voucher') and immediately qualifies the outcome ('settles to 0 open and shows as fully paid'). It also distinguishes itself from the two siblings it depends on by naming the round-trip sequence, so an agent can tell it apart from sevdesk_push_documents and match_invoice_transaction without opening schemas.

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

Usage Guidelines5/5

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

Explicitly positions the tool as 'the LAST step of the round trip' and names the prior steps it must follow, plus the consequence of skipping it ('the voucher stays open'). It also states a hard when-not condition (refuses vouchers already on status 1000) and the corrective path (reset_first:true), leaving nothing to inference.

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