Skip to main content

Cart pipelines

The integration and engagement logic used in the Cart API is implemented by pipelines that you can customize as needed. There is a pipeline for each method on the API. Some pipelines call other common pipelines such as the SaveCart and LoadCart pipelines. In some cases, the logic is split into several subpipelines to handle if-than-else situations, such as those used in the CreateOrResumeCart pipeline.

Name:

GetCarts

Description:

The pipeline is responsible for performing a search against all carts and return a list of CartBase instances for carts found, matching the specified search criteria.

The carts might be persisted in both the ECS and/or EA state.

Depending on the location of the main cart repository, the processors configured for the pipeline will differ between different Connect provider implementations.

Usage:

Called via the GetCarts method on the Connect API when searching for carts.

Args:

Request - contains the search criteria: UserID, CustomerID, CartName, CartStatus, IsLocked, and ShopName. It is set prior to calling the pipeline.

Response - contains the cart objects. It is read after the pipeline is executed.

Processors:

GetCartsFromEAState –

Responsibility - to execute a query against carts stored in EA states across all users that match the input parameters: UserID, CustomerID, CartName, and ShopName.

In default implementation, the processor is split into two, named:

  • BuildQuery.

  • ExecuteQuery. Queries the EA repository

Usage: the processor is generic for searching in EA state and returning lists of carts. If the external commerce system supports persisting carts then the processor(s) should be replaced by the custom GetCarts processor querying against ECS, see below.

Ownership: the processor is provided with Connect

Customization: if more search parameters are needed then the processor should be inherited and overwritten to search in

GetCarts –

Responsibility - to execute a query against carts stored in the external commerce system that match the input parameters: UserID, CustomerID, CartName, and ShopName.

Usage: if ECS supports persistence of carts, then this processor replaces the default Connect processor(s) querying against EA state.

If not supported, EA state and GetCartsFromEAState processor(s) must be used instead .

Ownership: ECS vendor

Customization: the processor is custom to the ECS. If more search parameters are needed then the processor should be extended to support that.

Name:

CreateOrResumeCart

Description:

Initiates the creation of a shopping cart and in the process:

  • Loads a persisted, potentially abandoned cart, if present and returns that.

  • Triggers an event in DMS if a new cart is created.

  • Enters a user in the Engagement Automation plan with the ID of the new shopping cart.

The pipeline calls different pipelines depending on whether an existing cart is found and can be resumed or not.

Usage:

Called via the CreateOrResumeCart method on the Connect API.

Args:

Request - Contains the essential cart parameters also used to search for existing cart. Is set prior to calling the pipeline.

Response - Contains the cart objects or a list of CartBase instances in case multiple carts exist that match the given parameters. Is read by the Cart Provider after the pipeline is called.

Processors:

FindCartInEAState

Responsibility:To locate a cart in the current contact’s / visitor’s EA state which matches the input parameters UserID, CustomerID, CartName, and ShopName.

If a match is found then the Cart ID is set in custom pipeline argument CartID (args.CustomData[“CartID”])

The processor is needed to retrieve the cart ID of the existing cart before the LoadCart method can be called

Usage: The processor is generic for searching in the EA state and returning the cart ID for a cart matching the given input parameters.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality, unless further query parameters are introduced

RunLoadCart –

Responsibility: To call the LoadCart pipeline and load a cart with the given ID. The ID is specified in the CartId parameter.

If the cart was not found, the cart is null or empty in the pipeline arguments.

Usage: Mandatory. The processor is generic for calling the LoadCart pipeline that loads a cart by CartID and can be used in other pipelines.

It is assumed that the CartID to be used for loading the cart is stored in the customer pipeline: arg “CartID” (args.CustomData[“CartID”])

The RunResumeCart pipeline assumes that the cart to be resumed is loaded before it is executed.

Ownership: The processor is provided with Connect

Customization: No immediate need for overwriting the default functionality.

RunResumeCart –

Responsibility: To call the ResumeCart pipeline in order to resume a loaded cart if possible.

It is expected that a cart is present in the pipeline arguments.

If no cart is present, then the processor will not call the ResumeCart pipeline.

Usage: Mandatory. The processor is generic for calling the ResumeCart pipeline.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

RunCreateCart –

Responsibility: To call the CreateCart pipeline in order to create a new cart.

It is expected that no cart is present in the pipeline arguments.

If a cart is present, then the processor will not call the CreateCart pipeline.

Usage: Mandatory. The processor is generic for calling the CreateCart pipeline.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

Name:

CreateCart

Description:

Creates and saves a new shopping cart and in the process:

  • Triggers an event in DMS for a new cart.

  • Enters the visitor/contact into an Engagement Automation plan with the new shopping cart.

Usage:

Called from the CreateOrResumeCart pipeline as one of the branches when no cart exists.

Args:

Request - Contains the same parameters as the CreateOrResumeCart pipeline. It is carried over from the CreateOrResumeCart pipeline.

Response - Contains the cart objects. Is read by the Cart Provider after the pipeline is called.

Processors:

CreateCart –

Responsibility: To create a new cart, initialize values from arguments and return it.

If a cart already exists in pipeline arguments, it is ignored and will be overwritten.

Usage: Optional. The default processor is generic for creating a domain model cart and initialize values, but it never calls the ECS.

In some integration scenarios, it will be relevant to call the ECS at this point in time to create a new cart. In that case, this processor can be used as a base class and extended, as it does initialize the cart domain object, or it can be replaced altogether.

In other integration scenarios, the ECS will not be called at this point in time. Instead, it will likely be called when manipulating cart lines or only when saving the cart. It depends on the system that is being integrated with.

Ownership: The processor is provided with Connect

Customization: It can be useful to use the processor as a base class and extend it by calling the ECS after initializing the cart domain model object.

RunSaveCart –

Responsibility: To call the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but should always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventForResultCart –

Responsibility: To trigger a specified page event and register the cart values: ExternalCartId, UserId, CartName, CartStatus.

The Page Event text is localized by looking up in Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event with the specified parameters from the cart stored in the args.Result argument.

The event to be triggered is specified in the PageEventName processor parameter.

The event text to be used is specified in the PageEventText processor parameter.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor if you want to register other values from the cart.

Name:

CreateOrResumeCart

Description:

Validates and resumes the cart specified in arguments and in the process:

  • Changes the state to the initial state in the abandoned cart Engagement (reboot).

  • Updates the cart state

  • Saves the cart

  • Triggers an event in DMS.

Usage:

Called via the Connect API from Sitecore.

Args:

Request - Contains the search criteria and is set by the Cart Provider prior to calling the pipeline.

Response - Contains the cart objects and is read by the Cart Provider after the pipeline is called.

Processors:

ChangeCartStatus –

Responsibility: To update the cart status field with the InProcess value taken from the constant CartStatus.InProcess.

Usage: Optional. The processor is generic but the status value set on the cart is fixed to InProcess.

Ownership: The processor is provided with Connect.

Customization: The processor could be updated to take the state value from the parameter instead of constant in code.

RunSaveCart –

Responsibility: To call the SaveCart pipeline, which saves the specified cart.

Usage: Mandatory. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventForResumedCart –

Responsibility: To trigger a specified page event when resuming the cart and register the following cart values:

  • ExternalCartId, UserId, CartName, CartStatus, StateName (containing the previous state that it was moved from).

The Page Event text is localized by looking up in the Sitecore dictionary.

Usage: Optional. The processor is specific for resuming a cart and for triggering a page event with the specified parameters from the cart stored in the args.Result argument.

The value for previous state is found in the PreviousState pipeline args and is inserted in the page event text along with the ExternalCartId.

The event text to be used is specified in the PageEventText processor parameter

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or change the text formatting.

Name:

LoadCart

Description:

Loads the cart that matches the specified criteria. For example, ID and ShopName.

This pipeline is responsible for reading data for a specific cart that is managed by the commerce system. This pipeline reads the cart data from the commerce system and/or from the Engagement Automation state.

Usage:

  • Called directly via the Connect API LoadCart method from Sitecore.

  • Called indirectly via the Connect API CreateOrResumeCart method.

Args:

Request - Contains the criteria that determine which cart should be retrieved; is set prior to calling the pipeline.

Response - Contains the cart object after the pipeline is called.

Processors:

LoadCartFromEAState –

Responsibility:

Load existing cart from the EA state with given CartID and in the shop specified with the ShopName parameter.

For performance reasons, the default implementation works as follows:

  • Firstly, carts are loaded from the current visitor/contact EA state data and filtered by the given parameters. If found, it is written to the Response arg property of the pipeline and execution stops.

  • If not found, then all carts across all contacts are loaded and filtered by the given parameters. Searching across all contacts is an expensive operation.

  • If the cart is found in the EA state, it is written to the Response arg property of the pipeline.

Usage: The processor is generic for loading a cart from the EA state.

The processor might be used alone in the LoadCart pipeline, if cart persistence is not available in the ECS or if handling of carts occurs in Sitecore alone.

It might also be left out of the pipeline if the ECS manage the cart repository alone.

Some ECS systems do not provide all the information specified in the cart domain model and a hybrid configuration might be used where the main data is read from the ECS and augmented with additional cart data stored in the EA state by inserting an additional processor.

Abandoned carts might be purged from the ECS but still remain in the EA state in Sitecore. In this case, it might make sense to have both processors in the pipeline. Sitecore will then act as a backup storage for carts.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality

LoadCart –

Responsibility :

Loads the existing cart from the ECS with the given CartID and in the shop specified with the ShopName parameter.

Usage: The processor is specific for loading a cart from the ECS.

The processor might be used alone in the LoadCart pipeline if cart persistence is available in the ECS. See also scenarios in the description for the LoadCartFromEAState processor.

Some ECS systems do not provide all the information specified in the cart domain model and a hybrid configuration might be used where the main data is read from the ECS and augmented with additional cart data stored in the EA state by inserting an additional processor.

If used in combination with the LoadCartFromEAState, even though the cart might already be loaded from EA state, it is important to check with the ECS and load the cart from there to ensure the latest version is used.

If the cart is found in an external commerce system it can overwrite or merge with the cart already stored in the Response arg property of the pipeline. It is up to the Connect provider implementation with the ECS.

Ownership: The processor is provided by the ECS.

Customization: Must be built specifically for the ECS.

Name:

SaveCart

Description:

Saves the cart both to the external commerce system and in the Engagement Automation state.

Usage:

Called from other service layer methods, but rarely, if never, called explicitly.

Args:

Request - Contains the criteria that determine which cart should be retrieved; is set prior to calling the pipeline.

Response - Contains the cart object after the pipeline is called.

Processors:

SaveCart –

Responsibility:

Saves the given cart to the ECS.

Usage: The processor is specific for saving a cart to the ECS.

The processor should not be used alone in the SaveCart pipeline because the feature for resuming existing carts depends on the cart being stored in the EA state as well. The FindCartInEAState processor looks up the cart in the EA state in order to get the CartId for loading the cart with the LoadCart from the ECS:

Some ECS systems do not provide all the information specified in the cart domain model and a hybrid configuration might be used where the main data is saved to the ECS and the additional cart data is stored in the EA state.

In some ECS implementations the SaveCart pipeline is the first and only place the ECS system is provided a cart from Connect.

Since the ECS is the primary repository for carts, it is assumed that the unique CartID key is provided by the ECS.

Ownership: The processor is provided by the ECS.

Customization: Must be built specifically for the ECS.

SaveCartToEAState –

Responsibility :

Saves the cart to the EA state.

Usage: Mandatory. The processor is generic for saving a cart to the EA state.

The processor might be used alone in the LoadCart pipeline, if cart persistence is not available in the ECS or if handling of carts occurs in Sitecore alone.

The processor should be used in the SaveCart pipeline because the feature for resuming existing carts depends on the cart being stored in the EA state as well. The FindCartInEAState processor looks up the cart in the EA state in order to get the CartId for loading the cart with the LoadCart pipeline from the ECS:

Some ECS systems do not provide all the information specified in the cart domain model and a hybrid configuration might be used where the main data is read from the ECS and augmented with additional cart data stored in the EA state by inserting an additional processor.

Abandoned carts might be purchased from the ECS but still remain in the EA state in Sitecore. In this case, it might make sense to have both processors in the pipeline. Sitecore will then act as a backup storage for carts.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

Name:

AddCartLines

Description:

This pipeline is responsible for adding a new line to the shopping cart and recording a corresponding page event in the DMS. This happens when a product is added to the cart.

Usage:

Called from Sitecore.

Args:

Request - Contains the cart to be updated, along with what lines should be added to the cart.

Is set prior to calling the pipeline.

Response - Contains the updated cart object after the pipeline is called.

Processors:

CheckIfLocked

Responsibility: Checks if the cart is locked and aborts the pipeline if so, returning SystemMessages to signal the locked state.

Usage: Optional. The processor is generic for checking if the cart is locked. The processor is and must be used in all pipelines that potentially modify the cart content.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

AddLinesToCart –

Responsibility: Adds the given lines to the provided cart.

Calling this method will always add the given lines to the existing collection of lines in the cart, even if lines already exist on the cart containing the same product. Alternatively, the UpdateLinesOnCart method can be called if a line already exists with a product where the quantity simply should be adjusted.

Usage: Optional. The processor is generic for adding lines to cart, but potentially should be replaced by an ECS specific implementation.

Ownership: The processor is provided with Connect.

Customization: The default implementation operates on the cart domain model in Sitecore only.

In most ECS integrations, it will be relevant to inherit and overwrite or replace this implementation and call the ECS, so that the changes to the cart are passed on and any business logic can be applied.

RunSaveCart -

Responsibility: Calls the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but must always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventsForCartLines

Responsibility: Triggers a specified page event when adding lines to the cart and registers the following values:

  • Product ID, QTY, Price and Currency

The event to be triggered is passed in as a parameter as well as the Page Event Text.

In this case the event is: Lines Added To Cart. The Page Event text is localized by looking up in Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event when modifying cart lines.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or to change the text formatting.

TriggerAddToCartStockStatusPageEvent

Responsibility:Triggers thepage event AddToCartStockStatus, along with the ShopName, Cart ID, Product ID , Stock Status, Pre-orderable, In-Stock Date, and Shipping Date, if and only if, the stock status is NOT InStock

Usage: Mandatory.

Ownership: The processor is provided with Connect.

Customization: Not needed.

UpdateVisitorInAutomationPlan –

Responsibility: Enrolls the current contact to the AbandonedCart campaign processor.

Usage: Optional. Used in Commerce Marketing Automation campaigns.

Ownership: The processor is provided with Connect.

Customization: Enrolls the current contact in the Abandoned Cart marketing automation campaign using these parameters:

  • basePlanName is the campaign plan name. The default value is Abandoned Cart.

  • allowDuplicateContacts indicates whether to allow the same contact to be enrolled multiple times in the marketing automation campaign. The default value is false.

  • allowUnauthenticatedContacts indicates whether to allow anonymous and unregistered users to enroll. The default value is true.

For further customization, the processor can be inherited.

Name:

RemoveCartLines

Description:

Responsibility is to remove cart lines from the cart.

Usage:

Called from Sitecore.

Args:

Request - Contains the cart to be updated along with the cart lines to be removed.

Is set prior to calling the pipeline.

Response - Contains the updated cart object after the pipeline is called.

Processors:

CheckIfLocked

Responsibility: Checks if the cart is locked and aborts the pipeline if so, returning a SystemMessage to signal the locked state

Usage: Optional. The processor is generic for checking if the cart is locked. The processor must be used in all pipelines that potentially modify the cart content.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

RemoveLinesFromCart –

Responsibility: Removes the given lines from the provided cart.

The list of lines to remove must be references directly to the lines in the CartLines collection on the cart. They will be removed by the reference: cart.CartLines = cart.CartLines.Except(request.CartLines).ToList();

Usage: Optional. The processor is generic for removing lines from the cart, but potentially should be replaced by an ECS specific implementation.

Ownership: The processor is provided with Connect.

Customization: The default implementation operates on the cart domain model in Sitecore only.

In most ECS integrations, it will be relevant to inherit and overwrite or replace this implementation and call the ECS, so that the changes to the cart are passed on and any business logic can be applied.

SaveCart

Responsibility: Calls the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but should always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventsForCartLines

Responsibility: Triggers a specified page event when adding lines to the cart and registers the following values:

  • Product ID, QTY, Price and Currency

The event to be triggered is passed in as a parameter as well as the Page Event Text. In this case, the event is Lines Removed From Cart. The Page Event text is localized by looking up in the Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event when modifying cart lines.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or to change the text formatting.

UpdateVisitorInAutomationPlan -

Responsibility: Enrolls the current contact to the AbandonedCart campaign processor.

Usage:Optional. Used to enroll contacts in a Commerce Marketing Automation campaign.

Ownership: The processor is provided with Connect.

Customization:Enrolls contacts in the Commerce marketing automation campaign based on these parameters:

  • basePlanName is the campaign plan name. The default value is Abandoned Cart.

  • allowDuplicateContacts indicates whether to allow the same contact to be enrolled multiple times in the marketing automation campaign. The default value is false.

  • allowUnauthenticatedContacts indicates whether to allow anonymous and unregistered users to enroll. The default value is true.

Name:

UpdateCartLines

Description:

Responsibility is to update the lines on the cart.

Usage:

Called from Sitecore.

Args:

Request - Contains the cart along with the cart lines to be updated.

Is set prior to calling the pipeline.

Response - Contains the updated cart object after the pipeline is called.

Processors:

CheckIfLocked

Responsibility: Checks if the cart is locked and aborts the pipeline if so, returning SystemMessages to signal the locked state.

Usage: Optional. The processor is generic for checking if cart is locked. The processor is and should be used in all pipelines that potentially modify the cart content.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

UpdateLinesOnCart –

Responsibility: To update the given lines on the provided cart.

The default implementation does not process the lines on the original cart, but simply returns the cart that was passed in and that already had its cart lines updated.

Therefore, the list of updated lines must be references to the CartLines collection on the cart.

Usage: Optional. The processor is generic for updating lines on the cart, but potentially should be replaced by an ECS specific implementation.

Ownership: The processor is provided with Connect.

Customization: The default implementation operates on the cart domain model in Sitecore only.

In most ECS integrations it will be relevant to inherit and overwrite or replace this implementation and call the ECS, so that the changes to the cart are passed on and any business logic can be applied.

SaveCart

Responsibility: Calls the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but must always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventsForCartLines

Responsibility: Triggers a specified page event when adding lines to the cart and registers the following values:

  • Product ID, QTY, Price and Currency

The event to be triggered is passed in as a parameter as well as the Page Event Text. In this case, the event is Lines Updated On Cart. The Page Event text is localized by looking up in the Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event when modifying cart lines.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or to change the text formatting.

UpdateVisitorInAutomationPlan –

Responsibility: Enrolls the current contact to the AbandonedCart campaign processor.

Usage: Optional. Used to determine who is enrolled in a Commerce Marketing Automation campaign.

Ownership: The processor is provided with Connect.

Customization: Determines who is enrolled in the Commerce marketing automation campaign based on these parameters:

  • basePlanName is the campaign plan name. The default value is Abandoned Cart.

  • allowDuplicateContacts indicates whether to allow the same contact to be enrolled multiple times in the marketing automation campaign. The default value is false.

  • allowUnauthenticatedContacts indicates whether to allow anonymous and unregistered users to enroll. The default value is true.

For further customization, the processor can be inherited.

Name:

DeleteCart

Description:

Responsibility is to delete a cart permanently:

  • The cart is deleted.

  • Triggers an event in DMS telling that the cart is deleted.

Usage:

Called from Sitecore.

Args:

Request - Contains the cart to be deleted.

Is set prior to calling the pipeline.

Response – SystemMessages

Processors:

CheckIfLocked

Responsibility: Checks if the cart is locked and aborts the pipeline if so, returning SystemMessages to signal the locked state

Usage: Optional. The processor is generic for checking if the cart is locked. The processor must be used in all pipelines that potentially modify the cart content.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

DeleteCart –

Responsibility: Deletes and removes the cart from storage in the ECS.

Usage: Mandatory.

Ownership: The processor is provided by the ECS.

Customization: Must be built specifically for the ECS.

DeleteCartFromEAState –

Responsibility: Locates and deletes the cart from the EA state.

Usage: Optional. The processor is generic for deleting the cart in the EA state.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventForRequestCart

Responsibility: Triggers a specified page event when deleting a cart and registers the following values:

  • ExternalCartId, UserId, CartName, CartStatus

The event to be triggered is passed in as a parameter as well as the Page Event Text. In this case, the event is Cart Deleted. The Page Event text is localized by looking up in the Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event for processors that take an argument based on the CartRequest parameter type.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or to change the text formatting.

Name:

UpdateCart

Description:

Responsibility is to pass an updated cart to the external commerce system

Triggers an event in DMS telling that the cart is being updated.

Usage:

Called from Sitecore.

Args:

Request - Contains the cart and the data to be updated in Cart Base.

Is set prior to calling the pipeline.

Response - Contains the updated cart object after the pipeline is called.

Processors:

CheckIfLocked

Responsibility: Checks if the cart is locked and aborts the pipeline if so, returning SystemMessages to signal the locked state.

Usage: Optional. The processor is generic for checking if the cart is locked. The processor must be used in all pipelines that potentially modify the cart content.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

SetAnonymousPreferredEmail -

Responsibility: Retrieves an email address for an anonymous user from the billing page and sets it as the preferred email.

Usage: Used in Commerce marketing automation campaigns to obtain an email address for anonymous users. Works in conjunction with the UpdateVisitorinAutomationPlan processor.

Ownership: The processor is provided with Connect.

Customization:

UpdateCart –

Responsibility: To update the cart with the updated values of the cart body (CartBase object only, not lines and so on).

The default implementation will update all default properties on the CartBase except CustomerID; CartName, and ShopName. Everything, including null and black values, are included.

Usage: Optional. The processor is generic for updating the cart body.

Ownership: The processor is provided with Connect.

Customization: If the default Connect domain model is customized, the processor should be overwritten to include the customized properties.

TriggerPageEventForRequestCartChanges

Responsibility: Triggers a specified page event when deleting a cart and registers the following values:

  • CustomerId, CartName, ShopName

The event to be triggered is passed in as a parameter as well as the Page Event Text. In this case, the event is Cart Deleted. The Page Event text is localized by looking up in the Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event for processors that take an argument based on the UpdateCartRequest parameter type.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or to change the text formatting.

RunSaveCart –

Responsibility: Calls the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but must always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

UpdateVisitorInAutomationPlan –

Responsibility: Enrolls the current contact to the AbandonedCart campaign processor.

Usage: Optional. Used to determine who is enrolled in a Commerce Marketing Automation campaign.

Ownership: The processor is provided with Connect.

Customization: Determines who is enrolled in the Commerce marketing automation campaign based on these parameters:

  • basePlanName is the campaign plan name. The default value is Abandoned Cart.

  • allowDuplicateContacts indicates whether to allow the same contact to be enrolled multiple times in the marketing automation campaign. The default value is false.

  • allowUnauthenticatedContacts indicates whether to allow anonymous and unregistered users to enroll. The default value is true.

For further customization, the processor can be inherited.

Name:

LockCart

Description:

Sets the cart in a locked state and prevents any modifications.

Usage:

Called from Sitecore.

Args:

Request - Contains the cart to be locked.

Is set prior to calling the pipeline.

Response - Contains the cart object after the pipeline is called.

Processors:

LockCart –

Responsibility: Sets the cart to a locked state (IsLocked = true).

Usage: Optional. The processor is generic for locking a cart.

Ownership: The processor is provided with Connect.

Customization: The default implementation does not call the ECS. It might be relevant to overwrite or replace the implementation to call the ECS when locking.

RunSaveCart –

Responsibility: Calls the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but must always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventForRequestCart

Responsibility: Triggers a specified page event when deleting a cart and registers the following values:

  • ExternalCartId, UserId, CartName, CartStatus

The event to be triggered is passed in as a parameter as well as the Page Event Text. In this case the event is CartLocked. The Page Event text is localized by looking up in the Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event for processors that take an argument based on the CartRequest parameter type.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or to change the text formatting.

Name:

UnlockCart

Description:

Sets the cart in an unlocked state.

Usage:

Called from Sitecore.

Args:

Request - Contains the cart to unlock.

Is set prior to calling the pipeline.

Response - Contains the cart object after the pipeline is called.

Processors:

UnlockCart –

Responsibility: Sets the cart to not-locked state (IsLocked = false).

Usage: Optional. The processor is generic for unlocking a cart.

Ownership: The processor is provided with Connect.

Customization: The default implementation does not call the ECS. It might be relevant to overwrite or replace the implementation to call the ECS when unlocking.

RunSaveCart –

Responsibility: Calls the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but must always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.

TriggerPageEventForRequestCart

Responsibility: Triggers a specified page event when deleting a cart and registers the following values:

  • ExternalCartId, UserId, CartName, CartStatus

The event to be triggered is passed in as a parameter as well as the Page Event Text. In this case the event is Cart Unlocked. The Page Event text is localized by looking up in the Sitecore dictionary.

Usage: Optional. The processor is generic for triggering a page event for processors that take an argument based on the CartRequest parameter type.

Ownership: The processor is provided with Connect.

Customization: Overwrite the processor to register other values from the cart or to change the text formatting.

Name:

MergeCart

Description:

Merges a User cart with an Anonymous cart.

Usage:

Called from Sitecore.

Args:

Request - Contains the User cart and the Anonymous cart.

Response - Contains the merged User cart.

Processors:

MergeCart –

Responsibility: Merges the User and Anonymous carts.

Usage: Optional. The processor is generic for merging carts.

Ownership: The processor is provided with Connect.

Customization: The default implementation does not call the ECS. It might be relevant to overwrite or replace the implementation if custom merging rules are required.

RunSaveCart –

Responsibility: Calls the SaveCart pipeline, which saves the specified cart.

Usage: Optional, but must always be called when changes have been made to the cart, which is the case here. The processor is generic for calling the SaveCart pipeline and can be used in other pipelines.

Ownership: The processor is provided with Connect.

Customization: No immediate need for overwriting the default functionality.