SAP B1 Service Layer 7 - Inventario icon

SAP B1 Service Layer 7 - Inventario

Interact with SAP B1 Service Layer 7 - Inventario

Overview

This node interacts with the SAP Business One Service Layer (version 7) specifically for Inventory Posting resources. It allows users to perform update operations on inventory posting records by sending a PATCH request to the SAP B1 API. This is useful in scenarios where inventory posting data needs to be modified or corrected after creation, such as adjusting quantities, dates, or other relevant fields.

Practical examples include:

  • Updating an existing inventory posting document with new values.
  • Correcting errors in posted inventory transactions.
  • Automating inventory adjustments based on external system inputs.

Properties

Name Meaning
DocEntry / Key Primary key of the inventory posting resource to identify which record to update.
JSON Body JSON content representing the fields and values to update in the inventory posting entry.

Output

The node outputs an array of JSON objects corresponding to each input item processed. Each output object contains the full response from the SAP B1 Service Layer API after attempting the update operation. The structure reflects the updated inventory posting record as returned by the API.

If an error occurs during the update, the output JSON will contain an error field with the error message describing what went wrong.

No binary data output is produced by this node.

Dependencies

  • Requires connection credentials to the SAP Business One Service Layer API, including:
    • Base URL of the SAP B1 Service Layer.
    • Username and password for authentication.
    • Company database identifier.
  • The node performs a login POST request to obtain session cookies used for subsequent API calls.
  • The environment must allow HTTPS requests to the SAP B1 Service Layer endpoint.
  • No additional external libraries beyond n8n's built-in HTTP request helper are required.

Troubleshooting

  • Authentication failures: If login fails, verify that the username, password, and company database are correct and that the SAP B1 Service Layer is accessible.
  • Invalid DocEntry: Ensure the provided primary key corresponds to an existing inventory posting record; otherwise, the API will return an error.
  • Malformed JSON Body: The JSON body must be valid and conform to the expected schema of the SAP B1 inventory posting resource. Invalid fields or types may cause the update to fail.
  • Network issues: Connection problems or SSL certificate issues can cause request failures. The node disables strict SSL verification (rejectUnauthorized: false), but network connectivity must still be stable.
  • Error messages: Errors returned from the SAP B1 API are passed through in the output under the error property. Review these messages to understand specific issues.

Links and References

Discussion