Orders service layer

The orders service layer is essentially an extension of the cart service layer.

You can find all configuration for the order subsystem in the Sitecore.Commerce.Orders.config file. Here you will find all details for the entities, pipelines, and repositories used by the cart system.

For the most part the default order entities for Commerce Connect are the same classes used by the cart, with the exception of the Order and OrderHeader entities. 

The Order entity simply extends Cart and adds an OrderId property, and the OrderHeader entity extends from CartBase  that simple serves as a class with some basic information about an order.

To extend any of the default entities, you create a new class that inherits from the appropriate type, and then patch the appropriate entity under <commerce.Entities> in the Sitecore.Commerce.Orders.config file.

The order layer ships with the following pipelines: submitVisitorOrder, getVisitorOrder, getVisitorOrders, visitorCancelOrderreorder, getAvailableCountries, getAvailableRegions, SynchronizeOfflineOrders, and orderStatusChanged.

By default, these pipelines trigger a goal, except for the submitVisitorOrder pipeline, which adds the order to an Engagement Automation Plan, and the reorder pipeline, which calls the relevant cart pipelines to add the reordered items to the customers cart. Each of these pipelines must have a relevant processor that can communicate with an external commerce system (ECS).

Note

For more information, see the Commerce Connect Developer Reference.