Limit the number of discount coupon uses
Discount coupons can additionally be limited by the number of their uses. This allows you to create one-time use coupons for customers.
If you have an existing discount coupon, you can limit its usage to new or regular customers only with the following API call:
PUT /api/v3/STOREID/discount_coupons/DISCOUNTCOUPONID
Host: app.ecwid.com
Content-Type: application/json
Authorization: Bearer secret_token
{
"usesLimit": "ONCEPERCUSTOMER"
}where usesLimit must be one of:
UNLIMITED- no uses limit (use it to remove the limitation).ONCEPERCUSTOMER- discount coupon can be applied only once by every customer. Unique customers are defined by the email they enter at the checkout.SINGLE- discount coupon can be applied only once.
Change STOREID with your store ID, DISCOUNTCOUPONID with the discount coupon ID (find discount coupon ID), and the secret_token with the secret access token of your app.
Last updated
Was this helpful?
