Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
CommercePromotions Class
Namespace
CommercePromotions Methods
decreaseRedemption(couponCodeRedemption)
API Version
58.0
Available to Guest Users
58.0
Requires Chatter
No
Signature
public static ConnectApi.CouponCodeRedemptionCollection decreaseRedemption(ConnectApi.CouponCodeRedemptionInput couponCodeRedemption)
Parameters
- couponCodeRedemption
- Type: ConnectApi.CouponCodeRedemptionInput
- Tracks each coupon code redemption.
Return Value
evaluate(salesTransaction)
API Version
57.0
Available to Guest Users
57.0
Requires Chatter
No
Signature
global static ConnectApi.PromotionEvaluation evaluate(ConnectApi.PromotionEvaluateInput salesTransaction)
Parameters
- salesTransaction
- Type: ConnectApi.PromotionEvaluateInput
- Find promotions that the customer is eligible for and compute their discounts.
Return Value
increaseRedemption(couponCodeRedemption)
API Version
58.0
Available to Guest Users
58.0
Requires Chatter
No
Signature
public static ConnectApi.CouponCodeRedemptionCollection increaseRedemption(ConnectApi.CouponCodeRedemptionInput couponCodeRedemption)
Parameters
- couponCodeRedemption
- Type: ConnectApi.CouponCodeRedemptionInput
- Tracks each coupon code redemption.