Update Coupon
PUT/payments/coupon
The "Update Coupon" API enables you to modify existing coupon details such as discount values, validity periods, usage limits, and other promotional parameters. Use this endpoint to adjust or extend promotional offers for your customers.
Request
API Version
v3- application/json
- Body
- Example (auto)
Bodyrequired
Location Id
Alt Type
locationCoupon Name
Coupon Code
Discount Type
percentageamountDiscount Value
Start date in YYYY-MM-DDTHH:mm:ssZ format
End date in YYYY-MM-DDTHH:mm:ssZ format
Max number of times coupon can be used
Product Ids
Price Ids
Variant Ids
Is Coupon applicable on upcoming subscription transactions
trueIf coupon is applicable on upcoming subscription transactions, how many months should it be applicable for a subscription
{"type":"forever"}Limits whether a coupon can be redeemed only once per customer.
falseCoupon Id
{
"altId": "BQdAwxa0ky1iK2sstLGJ",
"altType": "location",
"name": "New Year Sale",
"code": "LEVELUPDAY2022",
"discountType": "amount",
"discountValue": 10,
"startDate": "2023-01-01T22:45:00.000Z",
"endDate": "2023-01-31T22:45:00.000Z",
"usageLimit": 10,
"productIds": [
"6241712be68f7a98102ba272"
],
"priceIds": [
"6241712be68f7a98102ba272"
],
"variantIds": [
"6241712be68f7a98102ba272"
],
"applyToFuturePayments": true,
"applyToFuturePaymentsConfig": [
{
"type": "fixed",
"duration": 5,
"durationType": "months"
},
{
"type": "forever"
}
],
"limitPerCustomer": true,
"id": "6241712be68f7a98102ba272"
}
Successful response
- application/json
- Schema
- Example (auto)
Schema
Unique MongoDB identifier for the coupon
Number of times the coupon has been used
Maximum number of times a customer can use this coupon (0 for unlimited)
Location Id
Type of entity
Display name of the coupon
Redemption code for the coupon
Type of discount (percentage or amount)
percentageamountValue of the discount (percentage or fixed amount)
Current status of the coupon
scheduledactiveexpiredDate when the coupon becomes active
End date when the coupon expires
Indicates if the coupon applies to future recurring payments
Configuration for how the coupon applies to future payments
User ID associated with the coupon (if applicable)
Creation timestamp
Last update timestamp
Unique identifier for tracing this API request
{
"_id": "67f6c132d9485f9dacd5f123",
"usageCount": 12,
"limitPerCustomer": 5,
"altId": "79t07PzK8Tvf73d12312",
"altType": "location",
"name": "NEWT6",
"code": "NEWT6",
"discountType": "percentage",
"discountValue": 25,
"status": "scheduled",
"startDate": "2025-04-30T18:30:00.000Z",
"endDate": "2025-05-30T18:30:00.000Z",
"applyToFuturePayments": true,
"applyToFuturePaymentsConfig": {
"type": "fixed",
"duration": 3,
"durationType": "months"
},
"userId": "q0m15dTLGeiGOXG123123",
"createdAt": "2025-04-09T18:49:22.026Z",
"updatedAt": "2025-04-09T18:49:22.026Z",
"traceId": "c667b18d-8f5e-44cf-a914"
}