Finalise document
Finalise a draft invoice or quote: it gets its number and can no longer be edited.
MCP tool lexware_office_write → finalize_document
write Confirm
Clicks Abschließen on a draft. The invoice or quote gets its final number from your number range, appears in the list as open, and a PDF is generated. A finalised invoice is legally binding and cannot be edited; the only way back is cancel_invoice, which blocks the number for good. By default you confirm each call; you can switch that off for this tool.
Parameters
| Name | Type | Description |
|---|---|---|
| document_id string required | string | Document ID from list_documents or create_invoice. |
tools/call
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "lexware_office_write",
"arguments": {
"operation": "finalize_document",
"arguments": {
"document_id": "d_c44e19"
}
}
}
} Example response
{
"content": [
{
"type": "text",
"text": "{ ... same JSON as structuredContent ... }"
}
],
"structuredContent": {
"document_id": "d_c44e19",
"type": "invoice",
"number": "RE1043",
"status": "open",
"total_gross": 1130.5,
"currency": "EUR"
},
"isError": false
}