Actions88
- Purchase Credit Note Actions
- Purchase Invoice Actions
- Purchase Delivery Note Actions
- Purchase Down Payment Actions
- Purchase Order Actions
- Purchase Quotation Actions
- Purchase Request Actions
- Purchase Return Actions
- Purchase Tax Invoice Actions
Overview
This node integrates with the SAP Service Layer to manage various purchase-related documents, including Purchase Tax Invoices. Specifically, for the Purchase Tax Invoice resource and the Cancel operation, it sends a request to cancel an existing purchase tax invoice identified by its DocEntry. This is useful in scenarios where a previously recorded tax invoice needs to be invalidated or reversed due to errors, changes in the transaction, or compliance reasons.
Practical examples:
- Automatically cancel a purchase tax invoice when a related purchase order is voided.
- Integrate cancellation workflows into your ERP automation to maintain accurate financial records.
- Use in audit processes to programmatically reverse incorrect tax invoices.
Properties
| Name | Meaning |
|---|---|
| DocEntry | The unique identifier (number) of the purchase tax invoice document to be canceled. |
Output
The node outputs a JSON object representing the response from the SAP Service Layer API after attempting to cancel the specified purchase tax invoice. This typically includes confirmation details or error information.
If the cancellation is successful, the output JSON will contain the updated state of the purchase tax invoice or a success message.
If an error occurs, the output JSON will include an error field with the error message describing what went wrong.
No binary data output is produced by this operation.
Example output on success (simplified):
{
"DocEntry": 123,
"Canceled": true,
"Message": "Purchase tax invoice canceled successfully."
}
Example output on error:
{
"error": "Document not found or already canceled."
}
Dependencies
- Requires connection to an SAP Service Layer instance.
- Needs credentials including base URL, username, password, and company database name.
- The node performs login to SAP Service Layer to obtain session cookies before making API calls.
- No additional external dependencies beyond the SAP Service Layer API and valid credentials.
Troubleshooting
Common issues:
- Invalid or missing
DocEntry: Ensure the document number exists and is correct. - Authentication failures: Verify that the provided SAP credentials are correct and have sufficient permissions.
- Network or SSL errors: Check connectivity to the SAP Service Layer endpoint and SSL certificate validity.
- Document state errors: Attempting to cancel a document that is already canceled or closed may result in errors.
- Invalid or missing
Error messages and resolutions:
"Document not found": Confirm theDocEntryvalue corresponds to an existing purchase tax invoice."Unauthorized"or"Authentication failed": Recheck credentials and user permissions."Cannot cancel document in current status": The document might be in a state that disallows cancellation; verify document status in SAP."Network Error": Ensure the SAP Service Layer URL is reachable and no firewall blocks exist.
Links and References
- SAP Business One Service Layer Documentation
- SAP Service Layer API Reference
- OData Query Options (for
$selectand$filterusage)
This summary focuses on the Purchase Tax Invoice resource and the Cancel operation as requested, based on static analysis of the provided source code and property definitions.