Skip to content

Latest commit

 

History

History
46 lines (37 loc) · 2.92 KB

loyalty-event.md

File metadata and controls

46 lines (37 loc) · 2.92 KB

Loyalty Event

Provides information about a loyalty event. For more information, see Search for Balance-Changing Loyalty Events.

Structure

LoyaltyEvent

Fields

Name Type Tags Description
id string Required The Square-assigned ID of the loyalty event.
Constraints: Minimum Length: 1
type string Required The type of the loyalty event.
createdAt string Required The timestamp when the event was created, in RFC 3339 format.
Constraints: Minimum Length: 1
accumulatePoints LoyaltyEventAccumulatePoints | undefined Optional Provides metadata when the event type is ACCUMULATE_POINTS.
createReward LoyaltyEventCreateReward | undefined Optional Provides metadata when the event type is CREATE_REWARD.
redeemReward LoyaltyEventRedeemReward | undefined Optional Provides metadata when the event type is REDEEM_REWARD.
deleteReward LoyaltyEventDeleteReward | undefined Optional Provides metadata when the event type is DELETE_REWARD.
adjustPoints LoyaltyEventAdjustPoints | undefined Optional Provides metadata when the event type is ADJUST_POINTS.
loyaltyAccountId string Required The ID of the loyalty account associated with the event.
Constraints: Minimum Length: 1, Maximum Length: 36
locationId string | undefined Optional The ID of the location where the event occurred.
source string Required Defines whether the event was generated by the Square Point of Sale.
expirePoints LoyaltyEventExpirePoints | undefined Optional Provides metadata when the event type is EXPIRE_POINTS.
otherEvent LoyaltyEventOther | undefined Optional Provides metadata when the event type is OTHER.
accumulatePromotionPoints LoyaltyEventAccumulatePromotionPoints | undefined Optional Provides metadata when the event type is ACCUMULATE_PROMOTION_POINTS.

Example (as JSON)

{
  "type": "OTHER",
  "accumulate_points": null,
  "create_reward": null,
  "redeem_reward": null,
  "delete_reward": null,
  "adjust_points": null,
  "source": "SQUARE",
  "expire_points": null,
  "other_event": null,
  "accumulate_promotion_points": null
}