The parameters for cancelling the document. This includes:
doctype: The document type of the document to be canceled.name: The name or identifier of the document to be canceled.A promise that resolves to the canceled document of type T. The returned document includes
the data as updated to reflect its cancelled state.
Cancels a document, typically reverting it to a draft or canceled state.
This function performs an asynchronous request to the server to cancel a document of the specified type. Cancelling a document usually means it will be marked as "canceled" or moved to a state where no further processing can be done, effectively halting any ongoing workflows or actions related to the document.
Example
Example
Example
Throws
Throws an error if the request fails or if there is an issue with cancelling the document.