Actions26
- Item Actions
- Production Order Actions
- Warehouse Actions
- Product Tree Actions
- Inventory Gen Entry Actions
- Inventory Gen Exit Actions
- SQL Query Actions
- Custom API Call Actions
Overview
This node integrates with the SAP Service Layer API to perform operations on various SAP resources. Specifically, for the Item resource and the Get operation, it retrieves a single item record from SAP by its unique identifier. This is useful when you need detailed information about a specific material or product in your SAP system.
Common scenarios include:
- Fetching detailed data of an inventory item for reporting or processing.
- Retrieving item attributes before creating related documents or transactions.
- Integrating SAP item data into other systems or workflows.
Example: You want to get the details of an item with ID "12345" including only certain fields like ItemCode and ItemName, and also expand related entities such as DocumentLines.
Properties
| Name | Meaning |
|---|---|
| Select | Comma-separated list of fields to retrieve for the item (e.g., ItemCode, ItemName). Leave empty to get all fields. |
| Expand | Comma-separated list of related entities to expand in the response (e.g., DocumentLines, Attachments2). |
Output
The output is a JSON object representing the retrieved item record from SAP. It contains the fields requested via the Select property or all fields if none specified. If Expand is used, related entities are included as nested objects or arrays within the JSON.
Example output structure:
{
"ItemCode": "12345",
"ItemName": "Sample Item",
"PurchaseItem": true,
"SalesItem": false,
"DocumentLines": [
{
"LineNumber": 1,
"Description": "Line detail"
}
]
}
No binary data output is produced by this operation.
Dependencies
- Requires connection credentials to the SAP Service Layer API, including URL, company database name, username, password, and optionally language.
- Uses HTTPS requests with disabled SSL certificate verification (
rejectUnauthorized: false). - The node logs in to SAP Service Layer at runtime to obtain a session cookie for authentication.
- No additional external dependencies beyond standard HTTP client libraries bundled with n8n.
Troubleshooting
- Failed to get session cookie: Indicates login to SAP Service Layer failed. Check credentials and network connectivity.
- Operation not supported: Occurs if an unsupported operation or resource is selected. Verify correct Resource and Operation settings.
- Empty or invalid ID parameter: The Get operation requires a valid item ID; ensure the ID is provided and correct.
- Network or SSL errors: Since SSL verification is disabled, network issues or incorrect URLs can cause failures.
- API errors returned by SAP: These will be surfaced in the node output under an error field if "Continue On Fail" is enabled.
To resolve errors:
- Double-check SAP credentials and permissions.
- Confirm the item ID exists in SAP.
- Validate any select or expand parameters for correctness.
- Ensure the SAP Service Layer endpoint URL is reachable.
Links and References
- SAP Business One Service Layer Documentation
- OData Query Options (for
$selectand$expand)