PlantScanner - SAP Service Layer icon

PlantScanner - SAP Service Layer

Interact with SAP Service Layer API

Actions26

Overview

This node integrates with the SAP Service Layer API to manage various SAP resources programmatically. Specifically, for the Inventory Gen Exit resource with the Update operation, it updates an existing inventory exit record in SAP by sending partial data changes via a PATCH request.

This node is beneficial in scenarios where automated or bulk updates to SAP inventory exit records are needed, such as adjusting quantities, correcting details, or updating statuses without manual intervention in the SAP GUI.

Practical example:
A manufacturing company wants to update the details of an inventory exit after a physical stock count reveals discrepancies. Using this node, they can send updated JSON data reflecting the corrected quantities or notes directly to SAP, ensuring their system stays synchronized.

Properties

Name Meaning
Data The JSON object containing the fields and values to update on the Inventory Gen Exit record. This must be a valid partial representation of the record with only the fields to change.

Output

The node outputs an array of JSON objects corresponding to each input item processed. For the Update operation on Inventory Gen Exit, each output JSON contains the response data from SAP after the PATCH request, typically including the updated record's details or confirmation of the update.

Example output structure (simplified):

{
  "json": {
    "DocEntry": 123,
    "DocNum": 456,
    "Comments": "Updated comment",
    "Status": "Closed",
    ...
  }
}

No binary data output is produced by this node.

Dependencies

  • Requires an active connection to the SAP Service Layer API.
  • Needs credentials including the SAP Service Layer URL, company database name, username, password, and optionally language.
  • Uses HTTPS requests with disabled SSL certificate verification (rejectUnauthorized: false), which may require appropriate network security considerations.
  • The node handles session login by posting credentials to the /Login endpoint and uses the returned session cookie for subsequent requests.

Troubleshooting

  • Failed to get session cookie: Indicates login to SAP Service Layer failed. Check credentials and SAP Service Layer availability.
  • Operation not supported: If an unsupported operation or resource is selected, the node throws an error. Verify that the Resource is set to "Inventory Gen Exit" and Operation to "Update".
  • Invalid JSON in Data property: Ensure the JSON provided in the Data field is well-formed and matches SAP's expected schema for Inventory Gen Exit updates.
  • Network or SSL errors: Since SSL verification is disabled, network issues or firewall restrictions might cause failures. Confirm network access to the SAP Service Layer endpoint.
  • SAP API errors: Errors returned from SAP (e.g., validation errors) will be included in the output if "Continue On Fail" is enabled; otherwise, they will stop execution. Review error messages for required field corrections or permission issues.

Links and References

Discussion