SAP Service Layer (Purchases) icon

SAP Service Layer (Purchases)

Todas las entidades de Purchases de SAP Service Layer

Overview

This node integrates with the SAP Service Layer to manage various purchase-related entities, specifically here focusing on Purchase Requests. It allows users to perform operations such as creating, updating, deleting, retrieving, and managing the lifecycle of purchase requests within SAP Business One.

For the Update operation on Purchase Requests, the node sends a PATCH request to update an existing purchase request identified by its DocEntry. This is useful when you need to modify details of a purchase request programmatically, for example, updating quantities, descriptions, or approval statuses.

Practical examples:

  • Automatically update purchase request details based on changes in inventory or supplier information.
  • Integrate with external procurement systems to synchronize purchase request data.
  • Modify purchase requests in bulk using workflows triggered by business events.

Properties

Name Meaning
DocEntry The unique identifier (number) of the purchase request to update. Required for this operation.
JSON Body A JSON object containing the fields and values to update in the purchase request. This is the body sent in the PATCH request.

Output

The node outputs an array of JSON objects corresponding to each input item processed. For the update operation, the output JSON contains the response from the SAP Service Layer API after attempting to update the purchase request. This typically includes the updated purchase request data or an error message if the update failed.

If an error occurs during the request, the output JSON will contain an error field with the error message.

No binary data output is produced by this node.

Dependencies

  • Requires connection credentials to the SAP Service Layer API, including:
    • Base URL of the SAP Service Layer.
    • Username and password for authentication.
    • Company database name.
  • The node performs a login POST request to obtain session cookies (B1SESSION and optionally ROUTEID) used for subsequent API calls.
  • The node uses HTTP methods (GET, POST, PATCH, DELETE) to interact with the SAP Service Layer endpoints.
  • No additional external dependencies beyond the SAP Service Layer API and valid credentials.

Troubleshooting

  • Authentication errors: If login fails, check that the base URL, username, password, and company database are correct and that the SAP Service Layer is accessible.
  • Invalid DocEntry: Ensure the DocEntry number corresponds to an existing purchase request; otherwise, the update will fail.
  • Malformed JSON Body: The JSON body must be valid and conform to the SAP Service Layer schema for purchase requests. Invalid fields or types may cause errors.
  • Network issues: Verify network connectivity to the SAP Service Layer endpoint and that SSL certificates are trusted or properly configured (the node disables strict SSL verification).
  • Error messages: Errors returned from the SAP Service Layer API are passed through in the output under the error key. Review these messages for clues on required corrections.

Links and References


This summary focuses exclusively on the Purchase Request resource and the Update operation as requested.

Discussion