Loyalty Plan Model

ActionMethodResourceDescription
Get allGET/loyalty_plans/Get all loyalty plans.
GetGET/loyalty_plans/loyalty_plan_idGet loyalty plan by id.
UpdatePOST/loyalty_plans/loyalty_plan_idUpdate loyalty plan.
Only admins
CreatePOST/loyalty_plansCreate loyalty plan.
DeleteDELETE/loyalty_plans/loyalty_plan_idDelete loyalty plan by id.

The loyalty plan model is composed of the following attributes:

AttributeTypeRequiredDescriptionwhereable
idIntegerNoIdentifier of the loyalty plan
nameStringYesName of the loyalty plan
typeStringYesType of the loyalty plan:
credit_point,cashback
redemption_rateFloatYesRedemption rate of the loyalty plan
accumulation_rateFloatYesAccumulation rate of the loyalty plan
maximum_redemption_typeIntegerNoMaximum redemption type of the loyalty plan:
1, 2
maximum_redemption_rateFloatNoMaximum redemption rate of the loyalty plan
maximum_accumulationFloatNoMaximum accumulation of the loyalty plan
expire_after_minutesIntegerNoExpire after minutes of the loyalty plan
businessesarrayYesBusiness of the loyalty plan
created_atTimestampNoDate when the loyalty plan was created
updated_atTimestampNoDate when the loyalty plan was updated

Data of business

AttributeTypeRequiredDescription
idIntegerYesIdentifier of the business
redeemsBooleanNo
accumulatesBooleanNo
redemption_rateFloatNo
accumulation_rateFloatNo
maximum_redemption_typeIntegerNoType: 1, 2
maximum_redemption_rateFloatNo
maximum_accumulationFloatNo
expire_after_minutesIntegerNo