World is now on Opti ID! Learn more

Shannon Gray
Jun 29, 2013
  6509
(0 votes)

EPiServer Commerce Promotion Examples

Sometimes the best way to learn how something works is to see some examples of how its used. Below are a number of promotion examples built in EPiServer Commerce (out of the box) that will illustrate how dynamic promotions work. Specifically, you’ll see how to customize the Build Your Own Discount promotion templates to create a wide array of discounts. They come in three flavors : Entry (for giving discounts on individuals SKUs, independent of the cart, like on a category landing page), Order (for cart discounts on the cart or items in the cart), and Shipping (for providing discounts on shipping charges). Here are the examples with some explanation.

One general note is that the promotion descriptions are in $ but aren’t specific to a currency (unless specifically noted).

For orders which contain more than $60 of a combination of one or more skus, give a free gift

[Order: Building Your Own Discount]

image

The ExtendedPrice of LineItems represents the total cost for a “row” in a cart. For example, if you are getting 3 bottles of wine at $10 each, your ExtendedPrice would be $30. CatalogEntryId is the code or ID associated with a SKU. This term is a little confusing because it is *not* the CatalogEntryId of the SKU. The hierarchy of the dynamic purchase conditions means that the condition looks for a combination of lineitems in the cart which match an ExtendedPrice sum of 60 and any combination of the SKUs that matched the CatalogEntryIDs separated by OR statements. If the ORs weren’t present, it would require all three SKUs to be present in the cart and have a total sum of extended prices more than $60.

Buy 3 or more of a combination of one or more skus, give $5 off for a particular sku for the month of May only. This is limited to the first two quantity of the particular sku.

[Order: Building Your Own Discount]

image

This essentially says : For any combination of SKUs with a total quantity of 3 and have any combination of the following SKU codes, give the following reward.

Buy more than $25 in an order, give 10% off and free shipping

This is really two promotions : an Order promotion and a Shipping promotion. If your promotion is complicated, consider breaking it into multiple promotions.

[Order: Building Your Own Discount]

image

[Shipping: Building Your Own Discount]

freeShipping

Notice this uses Subtotal. Subtotal is the total of all of the ExtendedPrice values in the cart. It doesn’t include shipping charges or taxes. Note that the exception with taxes is that, if taxes are included in the SKU prices, as they often are with VAT, the tax amount won’t be separated from the SKU price. The property Total is available to provide a discount against the the total of the order including shipping… but that isn’t usually the intent of the promotion.

Also notice that the shipping promotion accesses the cart subtotal a little differently than the Order promotion.

Buy either an decanter or a glass and get 2 free bottles of a particular wine.

[Order: Building Your Own Discount]

image

The CatalogEntryIds here are for decanters and glasses. This is in contrast with the next promotion..

Buy a decanter and at least two glasses, get a free bottle of wine

[Order: Building Your Own Discount]

image

In this case, the first conditions of the purchase condition contains two decanter SKU codes and the second OrderForm.LineItems conditions contain two wine glass SKU codes. When two conditions are stacked without an Or statement between (as they are here, OrderForm.LineItems with children on top of another OrderForm.LineItems), they are assumed to be AND.

Buy more than 10 items, get 20% off of all of the items in the cart

[Order: Building Your Own Discount]

clip_image001[4]

Here,  the sum of the quantities is great than 10, meaning the total quantities of all of the lineitems. Gift items won’t be included in the count here.

Buy more than 20€ of an item, get 10% off of order

This allows you to target the discount to a particular currency.

[Order: Build Your Own Discount]

clip_image002

Note that this is for the cart, not items on a category page as they haven’t been associated with your cart – so BillingCurrency won’t be available for promotion discounts in the Entry : Build Your Own Discount.

Give $20 off anything in a category

[Entry: Build Your Own Discount]

clip_image002[5]

This could be used with any type of Build Your Own Discount. It will also apply to SKUs in a category page/detail page.

Buy 3 items from one category or 1 from another (with a value great than $100), get $20 back

[Order: Build Your Own Discount]

clip_image002[1]

Important note : When you specify a % or $ off whole order reward, the reward will be calculated as a discount off the subtotal, not total.

Buy an item worth more than $100, get free shipping

[Shipping : Build Your Own Discount]

clip_image002[3]

One final note : make sure to double check your promotion settings. Not only is it easy to make errors, but often the dynamic controls are quirky and don’t record or save the values you’ve entered. Its always worthwhile re-opening a promotion after creation to confirm you set it and the application saved it properly.

Jun 29, 2013

Comments

Please login to comment.
Latest blogs
Make Global Assets Site- and Language-Aware at Indexing Time

I had a support case the other day with a question around search on global assets on a multisite. This is the result of that investigation. This co...

dada | Jun 26, 2025

The remote server returned an error: (400) Bad Request – when configuring Azure Storage for an older Optimizely CMS site

How to fix a strange issue that occurred when I moved editor-uploaded files for some old Optimizely CMS 11 solutions to Azure Storage.

Tomas Hensrud Gulla | Jun 26, 2025 |

Enable Opal AI for your Optimizely products

Learn how to enable Opal AI, and meet your infinite workforce.

Tomas Hensrud Gulla | Jun 25, 2025 |

Deploying to Optimizely Frontend Hosting: A Practical Guide

Optimizely Frontend Hosting is a cloud-based solution for deploying headless frontend applications - currently supporting only Next.js projects. It...

Szymon Uryga | Jun 25, 2025

World on Opti ID

We're excited to announce that world.optimizely.com is now integrated with Opti ID! What does this mean for you? New Users:  You can now log in wit...

Patrick Lam | Jun 22, 2025

Avoid Scandinavian Letters in File Names in Optimizely CMS

Discover how Scandinavian letters in file names can break media in Optimizely CMS—and learn a simple code fix to automatically sanitize uploads for...

Henning Sjørbotten | Jun 19, 2025 |