Try our conversational search powered by Generative AI!

Retrieve the promotions/discounts applied on a purchase order.


Dear Team,
Request you to provide me the instructions to retrieve the promotions/discounts applied on a purchase order.

I am using the below code
_promotionEngine.Run(purchaseOrder, new PromotionEngineSettings(RequestFulfillmentStatus.Fulfilled, true))

However I am unable to get the reward information of the expired discounts .

EPiServer Version :10.2

Venkata Phani kumar R

Jun 09, 2017 1:50

The information of applied discounts are stored in IOrderForm.Promotions. Here you can get the information about the promotions applied and the amounts saved. So if you have an order, just access its .Forms (normally you only have one form so) 


Jun 09, 2017 10:15

Quan Mai,

We have custom promotions with custom fields. How can I access the data on these custom fields from the order form like you showed?


Nov 09, 2017 17:58

Either store it in AdditionalInformation in the PromotionInformation or load the promotion object and read it from there. Downside is that if you load the promotion and read it in real time you can't really use it on purchaseOrders, since they should always have a snapshot of the promotion data that was applied.

Nov 09, 2017 18:21

Thanks Joel, could you point me in the right direction to load up the promotion object?

Nov 09, 2017 18:26

Promotions are IContent, just use the content loader to load them from the PromotionInformation.ContentLink :)

Nov 09, 2017 18:27

Ah, I did not realize that. Thanks!

Nov 09, 2017 18:28
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.