Cancel invoice
Cancel (stornieren) a finalised invoice. The number stays blocked.
POST https://cotlet.dev/api/v1/lexware-office/documents/{document_id}/invoice/cancel
Opens Weitere Aktionen > Stornieren on an open invoice. The original shows a Storno stamp and its booking is reversed, and the cancellation cannot be undone; the cancelled number stays blocked even if you change the number range. A paid invoice needs its payment deleted first, and the restricted role "Belege, Kontakte & Produkte" cannot cancel paid invoices. Use create_invoice for the corrected one. 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. |
Request
curl -X POST https://cotlet.dev/api/v1/lexware-office/documents/document_8c41d2/invoice/cancel \
-H "Authorization: Bearer $COTLET_API_KEY" result = client.call("lexware-office", "cancel_invoice", {"document_id":"document_8c41d2"}) const result = await cotlet.call('lexware-office', 'cancel_invoice', {"document_id":"document_8c41d2"}); cotlet call lexware-office cancel_invoice --data '{"document_id":"document_8c41d2"}' Example response
{
"document_id": "d_9c31be",
"number": "RE1031",
"status": "voided"
}