K Khan
Feb 18, 2016
  2177
(4 votes)

Promotions That Drive Customer Engagement - Part1

Offers. Deals. Promotions. Rebates. Coupons. No matter what they are called, offers are a mainstay of loyalty marketing. Customers expect offers from brands and deals have become an integral part of the customer buying behavior. (Recall JC Penney’s recent experience.) This is also true of loyalty programs where promotions drive new or additional purchases. So, promotions create a level of brand engagement. But the experience can be more of a quick hit than a lasting relationship and managing the growing inventory of offers can be a real marketing challenge. (Published in Loyalty Management, the online magazine of Loyalty360.org, By: Brett Battles, EcoRebates)

EPiServer came with a revoltionary solution for Promotions to answer the changing demands of sharp brains of Mr. Marketing guy. There is a long list of promotions that we are/will be reciving in updates*. 

1. Buy any entry contained within a single [category] and receive a [discount] on all entries located within all child categories.
2. Buy [N] items from [category / set of categories/ catalog entry] and receive a [discount] off any item in different [category / set of categories/ catalog entry].
3. Buy [N] quantity from [category / set of categories/ catalog entry] at a [discount (for every selected item)].
4. Buy [N] quantity from [category / set of categories/ catalog entry] and get the cheapest item for free.
5. Buy [N] items from [category / set of categories/ catalog entry] and get the most expensive item for free.
6. Buy [N] items from [category / set of categories/ catalog entry] and get a [discount] on everything in the cart.
7. Buy any product from [category / set of categories /catalog entry] and receive [discount] off shipping costs.
8. Buy any product from [category / set of categories /catalog entry] and receive free shipping.
Order
9. Spend [currency amount] and receive a [discount] from [N] items from [category / set of categories / catalog entry]
10. Spend [currency amount] and receive a [discount]
11. Spend [currency amount] and receive free item(s)
12. Spend more then [currency amount] and receive [discount] off shipping [type, all types] costs.
13. Spend more then [currency amount] and receive free shipping [type, all types] costs
14. Multiple coupon codes per promotion with the ability to limit the number of times and maybe expiration dates
15. Calculate the discounted prices without having to add a product to a cart

*this is a preliminary list and is subject to change.

And that's not end of it, As a developer we will be able to develop new kind of promotions very rapidly also. In order to use the new promotion system in the workflows WorkflowsVNext feature must be switched on in ecf.app.config

<Features>
    <add feature="WorkflowsVNext" state="Enabled" type="Mediachase.Commerce.Core.Features.WorkflowsVNext, Mediachase.Commerce" />
  </Features>

or use the service locator.

var featureSwitch = ServiceLocator.Current.GetInstance<IFeatureSwitch>();
featureSwitch.Features.Add(new WorkflowsVNext());
featureSwitch.EnableFeature(WorkflowsVNext. FeatureWorkflowsVNext);

Campaigns provide a way to organise marketing activities. In new promotions system, Campaigns are content-based (a type of IContent). It is similar to pages, blocks and catalog data. You work with them in the same way using API, as we do for other Content Types inherited from IContent (e.g. IContentRepository). All Compaigns are managed under a compaign folder i.e. direct child of root node. EPiServer.Commerce.Marketing.SalesCampaign is a out of the box commerce-specific campaign extending the EPiServer.Core.CampaignData with a revenue goal. To create custom campaign we preferabbly can inherit from EPiServer.Commerce.Marketing.SalesCampaign

A custom campaign:

public class CustomCampaign : EPiServer.Commerce.Marketing.SalesCampaign
    {
        [Display(Name = "Region")]
        public virtual string Region { get; set; }
    }

Creating Campaign programatically

public static class CampaignHelper
    {
        public static CustomCampaign CreateCampaign(string name, string code, string description, string region)
        {
            var repository = ServiceLocator.Current.GetInstance<IContentRepository>();
            var campaign = repository.GetDefault<CustomCampaign>(CampaignFolder.CampaignRoot);

            campaign.Name = name;
            campaign.Description = description;
            campaign.Code = code;
            campaign.Region = region;
            campaign.IsActive = true;
            campaign.ValidFrom = DateTime.Today;
            campaign.ValidUntil = DateTime.Today.AddMonths(1);
            campaign.RevenueGoal = 1000000;

            repository.Save(campaign, SaveAction.Publish, AccessLevel.NoAccess);

            return campaign;
        }
    }

Creating Custom Promotions: Part 2

Feb 18, 2016

Comments

Feb 18, 2016 06:29 PM

Nice write up. Looking forward to reading part 2 ;)

Mark Prins
Mark Prins Mar 31, 2016 02:28 PM

You create a custom Campaign here. Would it be possible to create a campaign of this custom type from the editor? It seems by default you can only create campaigns of the type SalesCampaign in the editor.

K Khan
K Khan Mar 31, 2016 04:08 PM

Have you tried with the latest version?

Please login to comment.
Latest blogs
Vulnerability in CMS 12 shell module configuration

Introduction A potential security vulnerability has been identified in Optimizely CMS 12, triggered by a certain shell module configuration. To be...

Magnus Rahl | Sep 28, 2023

AI-Assistant: The 'Change Tone' Shortcut

The AI-Assistant for Optimizely is constantly evolving, adjusting, and transforming to meet your digital needs, providing a cutting-edge advantage...

Luc Gosso (MVP) | Sep 27, 2023 | Syndicated blog

How to fix scheduled job 'Remove Abandoned BLOBs' if it keeps failing

Optimizely inlcudes a job named 'Remove Abandoned BLOBs'. This post will help you fix it if it's no longer working.

Henning Sjørbotten | Sep 26, 2023 | Syndicated blog

Optimizely Web Experimentation Metrics

Within the domain of Optimizely Web Experimentation Metrics, the emphasis is on objective key performance indicators (KPIs) selected to assess an...

Matthew Dunn | Sep 23, 2023 | Syndicated blog