Commerce Services Implementation
The section explains how to implement the features of the Commerce Services module including cart management, payment options, and security.
Finding User by Property
The service userMatchingService looks up a user based on various attributes. This service is used by facades and validators to support all places of the Commerce Web Services, where the userId comes directly from a URL as a path variable or request parameter. The implementation of this service is DefaultUserMatchingService, which contains a list of strategies of type UserPropertyMatchingStrategy.
Inserting Customer IDs in API Calls
Inserting a customer ID into an OCC API call allows a service agent to act on behalf of the customer. A typical use case for this feature is emulating customer actions in the Assisted Service Module, which uses OCC APIs to support customers.
Cart Merging
The cart merge functionality is intended to provide a consistent cart experience across multiple touchpoints.
Converters and Populators
Data objects are constructed from Models or other Service Layer objects using Converters and Populators. Converters create new instances of Data objects and call Populators to populate these data objects.
Value Resolvers
The value resolvers are a more efficient replacement for the current value providers.
Populating the In-Store Customers List with IoT Device Data
An Assisted Service agent working physically in a store can look up the customers who are currently in that particular store. At the moment, the information about which customers are present in a given store is mocked and imported via an ImpEx file, but this data may come from any source, including an IoT device.
Commerce Quotes
Learn about the classes in commerceservices that are used for the Commerce Quotes feature.
Cart Entry Grouping Functionality
Entry Grouping functionality allows to group multiple cart entries into single package and operate with it as with one entity.
Voucher Redemption, Validation, and Brute Force Attack Detection
Vouchers are redeemed upon placing an order. Previously this functionality was left up to the partner to implement.
Integrating with Adobe Experience Manager
SAP Commerce Cloud can easily integrate with Adobe Experience Manager (AEM). This allows you to connect the SAP Commerce Cloud solution responsible for controlling product data, shopping carts, checkout and order fulfillment, while AEM controls the data display and marketing campaigns.
Removing Old Carts with Cronjob
Carts are not deleted after the session is closed. This way it is still possible to restore the cart later when the user gets back online. However, to avoid storing large amount of old carts you can use the cronjob to remove them.
Extend Commerce Services
Commerce Services can be extended by creating an AddOn with one additional Controller class and using appropriate methods. However, in most cases some more complex changes are required to build an AddOn which adds the functionality to Commerce Services.