Skip to main content

BRPromotion

Represents a promotion identified against the receipt, either validated or not.

Declaration

@interface BRPromotion : NSObject <BRSerializable>
class BRPromotion : NSObject, BRSerializable

Quick Reference

Properties

PropertyDescription
slugIdentifies which promotion qualified.
rewardValueThe reward value for this promotion.
rewardCurrencyThe reward currency for this promotion.
errorCodeError code when the promotion did not qualify.
errorMessageError message for failure to qualify.
relatedProductIndexesIf this promotion qualified, contains the indexes of the products in BRScanResults.products which caused it to qualify.
qualificationsIf this promotion qualified, contains an array of each instance of qualification; each instance is an array of product indexes from BRScanResults.products.
qualifiedProductListsIf this promotion qualified, contains an array of each qualified product along with its index in the main products result structure and any product groups it belongs to.

Properties

slug (read-only)

@property (nonatomic, strong, readonly) NSString *slug;
var slug: String! { get }

Identifies which promotion qualified.


rewardValue (read-only)

@property (nonatomic, readonly) float rewardValue;
var rewardValue: Float { get }

The reward value for this promotion.


rewardCurrency (read-only)

@property (nonatomic, strong, readonly) NSString *rewardCurrency;
var rewardCurrency: String! { get }

The reward currency for this promotion.


errorCode (read-only)

@property (nonatomic, readonly) NSInteger errorCode;
var errorCode: Int { get }

Error code for failure to qualify. 0 indicates success.


errorMessage (read-only)

@property (nonatomic, strong, readonly) NSString *errorMessage;
var errorMessage: String! { get }

Error message for failure to qualify.


relatedProductIndexes (read-only)

@property (nonatomic, strong, readonly) NSArray<NSNumber *> *relatedProductIndexes;
var relatedProductIndexes: [NSNumber]! { get }

If this promotion qualified, contains the indexes of the products in BRScanResults.products which caused it to qualify.


qualifications (read-only)

@property (nonatomic, strong, readonly) NSArray<BRPromotionQualification> *qualifications;
var qualifications: [[NSNumber]]! { get }

If this promotion qualified, contains an array of each instance of qualification; each instance is an array of product indexes from BRScanResults.products.


qualifiedProductLists (read-only)

@property (nonatomic, strong, readonly) NSArray<BRQualifiedProduct *> *qualifiedProductLists;
var qualifiedProductLists: [BRQualifiedProduct]! { get }

If this promotion qualified, contains an array of each qualified product along with its index in the main products result structure and any product groups it belongs to.