bLoyal API Documention and Samples

Method: CalculateSalesTransaction

Description

CalculateSalesTransaction() is the primary method used to integrate the bLoyal Promotions and Loyalty engine with an application.  You pass in a sales transaction (e.g. a POS sale, shopping cart, or order) and bLoyal processes it and returns any Discounts that applied, Loyalty Benefits that will accrue, and any suggested Offers

Parameters
Name  Type  Description 
credential  Credential  The web service account login for the bLoyal client account.
calcRequest  CalcRequest  Contains the input sales transaction to process along with any calculate options.
Returns

A CalculateSalesTransactionResult element having the structure defined by the following table.

Name  Type  Description 
AppliedCoupons  ArrayOfCouponSummary  This is a list of Coupons that were applied.
AppliedDiscounts  ArrayOfDiscountSummary  The list of bLoyal Discounts that were automatically applied.
LoyaltyCurrencyAccrued  decimal  The amount of loyalty currency that may accrue if the sale is completed.
LoyaltyPointsAccrued  int  The number of loyalty points that will accrue if the sale is completed.
LoyaltyPointsUsed  int  The numer of customer loyalty points that will be used if the sale is completed.
Offers  ArrayOfOffer  A list of potential Offers the customer may be eligible for.  You should display the offer message along with a link to the offer details.
Transaction  SalesTransaction  The modified sales transaction with any bLoyal discounts applied.
Faults
Name  Content  Description 
RedirectFaultFault  RedirectFault  The client account is on another service cluster.
SystemFaultFault  SystemFault   
BusinessFaultFault  BusinessFault   
SecurityFaultFault  SecurityFault