Skip to main content
Glama

Book invoice

book_invoice

Step 2: record the booking for an uploaded invoice — amounts, VAT, and the chart-of-accounts (SKR) account — then create the posting and mark the document approved so it's ready for sevDesk. Pass skr_account_number to book it to a specific account; the account is validated against the chart of accounts.

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": "book_invoice"
  }
}

Input Schema

NameRequiredDescriptionDefault
currencyNoBooking currency, default EUR
due_dateNoPayment due date, YYYY-MM-DD. PASS IT — it is optional in the schema but not in practice: it becomes the voucher's paymentDeadline in sevDesk and the Faelligkeit in list_payables, and a voucher without it shows no due date in the payment list the bookkeeping works from. Measured on 22.11.2026: all 68 open payables of ToasterNET read faellig:null, because nothing ever passed this. When the invoice prints no term, the invoice date is the honest answer (due on receipt), not null.
vat_codeNoTax rule code from the tenant's tax rules, e.g. 'VAT19'
frameworkNoWhich chart the number is from: 'SK03' or 'SK04'. Defaults to the tenant's preferred_skr_framework. Worth passing explicitly — the same number is a different account in each chart (4600 is Werbekosten in SKR03 and Erlöse Vermietung in SKR04).
contact_idNoBook-AI-ze contact id for the supplier. Needed for the voucher to carry a sevDesk supplier.
issue_dateNoInvoice date, YYYY-MM-DD — required before it can go to sevDesk
vat_amountNoVAT included in the gross total. 0 for a reverse-charge invoice.
cost_centerNoOptional cost centre for the posting
document_idYesFrom create_invoice_upload_url
vendor_nameNoSupplier name
total_amountNoGross total in the BOOKING currency (EUR for German books). For a foreign-currency invoice this is the converted figure, not the printed one.
exchange_rateNoRate used to convert original_amount into the booking currency (e.g. 0.8726)
tax_treatmentNoHow it is taxed — set this explicitly, it is never guessed: 'standard' (19%), 'standard_7' (7%), 'reverse_charge_eu' (§13b, EU supplier), 'reverse_charge_non_eu' (§13b, third-country supplier — e.g. a US company invoicing 0% with 'tax to be paid on reverse charge basis'), 'not_taxable' (service to a third-country recipient, place of supply abroad), 'small_business' (§19 UStG), or 'no_vat' for something that is not a taxable supply at all — Geldtransit, durchlaufende Posten, a transfer between own accounts. All the others are VAT treatments of REVENUE, and sevDesk refuses them on a balance-sheet account. A 0% invoice is ambiguous without this and will be refused at push time.
invoice_numberNoThe supplier's invoice number
original_amountNoThe gross total as printed on the invoice, in original_currency (e.g. 200.00)
mark_for_sevdeskNoAlso mark it ready to push to sevDesk (default true)
original_currencyNoThe currency actually printed on the invoice, if it differs from the booking currency (e.g. 'USD')
skr_account_numberNoChart-of-accounts (SKR) expense account, e.g. '6815'. Validated against the chart; the result reports which sevDesk category it maps to, and warns if it maps to none (which would push the voucher without a category).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / due_date / description
      Previous value: -"Payment due date, YYYY-MM-DD"New value: +"Payment due date, YYYY-MM-DD. PASS IT — it is optional in the schema but not in practice: it becomes the voucher's paymentDeadline in sevDesk and the Faelligkeit in list_payables, and a voucher without it shows no due date in the payment list the bookkeeping works from. Measured on 22.11.2026: all 68 open payables of ToasterNET read faellig:null, because nothing ever passed this. When the invoice prints no term, the invoice date is the honest answer (due on receipt), not null."
  2. First observed

TDQS

A3.6/5.0
Behavior4/5

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

Annotations only declare this is a non-readonly, non-idempotent, non-destructive call; the description adds that it writes a posting, flips the document to approved, and stops short of pushing to sevDesk. It does not warn that re-invoking is not idempotent and can duplicate postings, which is the main residual risk.

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 sentences, front-loaded with the step number and action, with the side effects stated before the optional-parameter note. The second sentence largely duplicates the schema's skr_account_number description, so it is not entirely waste-free.

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

Completeness3/5

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

For an 18-parameter mutation with no output schema, the description conveys sequence and side effects but leaves open whether it pushes to sevDesk or only prepares the voucher, and gives no prerequisites for the many non-required-but-critical fields. Adequate, not complete.

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% and the property descriptions are unusually detailed, so the schema already does the heavy lifting. The description's only added parameter meaning – that skr_account_number is validated against the chart of accounts – merely restates the schema text, so baseline 3 applies.

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?

Uses a specific verb+resource ('record the booking for an uploaded invoice') and enumerates the effects: create the posting, mark the document approved, ready for sevDesk. The 'Step 2' framing positions it relative to the upload tool, though it never names a sibling outright.

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

Usage Guidelines3/5

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

Implicit sequencing ('Step 2' after an uploaded invoice) and one conditional hint ('Pass skr_account_number to book it to a specific account'), but no explicit when-to-use/when-not or named alternative for related tasks such as extraction or sevDesk finalization.

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