Introduction

The Loyalty Rewards API allows you to manage rewards that customers can redeem with their loyalty points. For example, you can create a reward that is redeemed for a coupon for free shipping or for a coupon with a discount that applies to an entire purchase.

With the Loyalty Rewards API, you can create and update the rewards you offer.

Terminology

  • Discount amount: A specific reward type that is only available for Wix Restaurants.
  • Coupon reward: All other types of rewards other than “discount amount.” The details included here dictate what type of coupon will be created when this reward is redeemed.
Was this helpful?
Yes
No

Reward Object

A loyalty reward is an object a customer can redeem with loyalty points. Redeeming a reward then creates a loyalty coupon that the customer can use.

Properties
idstringRead-onlyformat GUID
Reward ID.

namestringminLength 1maxLength 50
Reward name.

activeboolean
Whether the reward is active. Default: "false"

typestring
4 enum supported values:
UNDEFINEDDISCOUNT_AMOUNTCOUPONCOUPON_REWARD
Reward type.

revisionintegerRead-onlyformat uint64
Revision number, which increments by "1" each time the loyalty reward is updated. To prevent conflicting changes, the current revision must be passed when updating the loyalty reward.

createdDatestringRead-onlyformat date-time
Date and time the reward was created.

updatedDatestringRead-onlyformat date-time
Date and time the reward was last updated.

ONE OF:


discountAmountobject
Discount details.

couponRewardobject
Coupon details.
Was this helpful?
Yes
No

GetList Rewards

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a list of rewards.

Only rewards with "active" set to "true" will be retrieved. The list includes rewards that are currently unredeemable due to insufficient points held by any customers.

Note: This endpoint requires visitor or member authentication.

Permission Scopes

For app development, you must have one of the following permission scopes:
Read Loyalty
Manage Loyalty
Learn more about permission scopes.
Endpoint
GET
https://www.wixapis.com/loyalty-rewards/v1/rewards

Was this helpful?
Yes
No

PostCreate Reward

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Creates a reward that can be redeemed with loyalty points.

When a customer redeems a reward, a loyalty coupon is created based on the specifications detailed in either the discountAmount or couponReward fields. This coupon can then be used by the customer to receive the discount. Note that while the Rewards API uses coupon scopes and specifications, no coupon is actually created until a reward is redeemed with points. See the Coupons API for more information about coupons. The type of reward cannot be updated.

A reward's active status defaults to false. To make the reward available to customers, either set the active field to true during creation or call Update Reward to change the status.

To customize a reward for each loyalty tier, use the configsByTier parameter. This allows you to specify the amount of the earned discount, the cost in loyalty points to redeem the reward, and the tier to which this configuration applies. Each tier requires its own configsByTier configuration. To create a reward that is available to loyalty accounts in the base tier, leave the tierId field empty. See the Tiers API for more information on tiers.

Note: This endpoint requires visitor or member authentication.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Loyalty
Learn more about permission scopes.
Endpoint
POST
https://www.wixapis.com/loyalty-rewards/v1/rewards

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

GetGet Reward

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a reward.

Note: This endpoint requires visitor or member authentication.

Permission Scopes

For app development, you must have one of the following permission scopes:
Read Loyalty
Manage Loyalty
Learn more about permission scopes.
Endpoint
GET
https://www.wixapis.com/loyalty-rewards/v1/rewards/{id}

Was this helpful?
Yes
No

DeleteDelete Reward

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Deletes a reward.

Note: This endpoint requires visitor or member authentication.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Loyalty
Learn more about permission scopes.
Endpoint
DELETE
https://www.wixapis.com/loyalty-rewards/v1/rewards/{id}

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

PutUpdate Reward

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Updates a loyalty reward.

Use this endpoint to update details of a reward, such as the name, whether or not a reward is active, or the amount of points it costs to redeem. Also use this endpoint to add new tiers that are eligible to redeem a reward.

You may not change the type of a reward. That is set upon creation and cannot be updated.

Note: This endpoint requires visitor or member authentication.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Loyalty
Learn more about permission scopes.
Endpoint
PUT
https://www.wixapis.com/loyalty-rewards/v1/rewards/{reward.id}

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

Reward Created

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a reward is created.

Permission Scopes

For app development, you must have one of the following permission scopes:
Read Loyalty
Manage Loyalty
Learn more about permission scopes.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring
Unique event ID. Allows clients to ignore duplicate webhooks.

entityFqdnstring
Fully qualified domain name of the entity associated with the event. Expected wix.loyalty.v1.reward.

slugstring
Event name. Expected created.

entityIdstring
ID of the entity associated with the event.

eventTimestringformat date-time
Event timestamp.

triggeredByAnonymizeRequestboolean
Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).

originatedFromstring
If present, indicates the action that triggered the event.

createdEventobject
Event information.
Was this helpful?
Yes
No

Reward Updated

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a reward is updated.

Permission Scopes

For app development, you must have one of the following permission scopes:
Read Loyalty
Manage Loyalty
Learn more about permission scopes.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring
Unique event ID. Allows clients to ignore duplicate webhooks.

entityFqdnstring
Fully qualified domain name of the entity associated with the event. Expected wix.loyalty.v1.reward.

slugstring
Event name. Expected updated.

entityIdstring
ID of the entity associated with the event.

eventTimestringformat date-time
Event timestamp.

triggeredByAnonymizeRequestboolean
Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).

originatedFromstring
If present, indicates the action that triggered the event.

updatedEventobject
Event information.
Was this helpful?
Yes
No

Reward Deleted

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a reward is deleted.

Permission Scopes

For app development, you must have one of the following permission scopes:
Read Loyalty
Manage Loyalty
Learn more about permission scopes.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring
Unique event ID. Allows clients to ignore duplicate webhooks.

entityFqdnstring
Fully qualified domain name of the entity associated with the event. Expected wix.loyalty.v1.reward.

slugstring
Event name. Expected deleted.

entityIdstring
ID of the entity associated with the event.

eventTimestringformat date-time
Event timestamp.

triggeredByAnonymizeRequestboolean
Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).

originatedFromstring
If present, indicates the action that triggered the event.

deletedEventstruct
Event information.
Was this helpful?
Yes
No