unpost_invoice
Reverse a posted invoice or bill to return it to open state for editing or re-posting. Requires voiding applied payments first.
Instructions
Reverse a posted invoice or bill.
Deletes the posting transaction and lot, and clears the invoice's posted-state metadata. The invoice returns to "open" state and can be edited or re-posted. Refuses if the invoice has any payments applied — void payments first, then unpost.
Args: id: Invoice or bill ID (e.g., "000001"). owner_type: "customer" or "vendor" for disambiguation when IDs collide.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| owner_type | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |