v1

latestSwagger 2.0MIT2026-07-17233380637.0 KB
Coupons

Update a coupon collection by id

patch/couponCollections/{id}

Path parameters

idstring uuidv4 required

Id of the collection to update

Request body

defaultCouponstring

A default coupon to be used in case there are no coupons left

expirationDatestring date-time

Specify an expiration date for the coupon collection in RFC3339 format. Use null to remove the expiration date.

remainingDaysAlertinteger

Send a notification alert (email) when the remaining days until the expiration date are equal or fall bellow this number. Use null to disable alerts.

remainingCouponsAlertinteger

Send a notification alert (email) when the remaining coupons count is equal or fall bellow this number. Use null to disable alerts.

Example request

{
  "defaultCoupon": "10 OFF",
  "expirationDate": "2024-01-01T00:00:00Z",
  "remainingDaysAlert": 5,
  "remainingCouponsAlert": 5
}

Response

Coupon collection updated

idstring uuidv4 required

The id of the collection

namestring uuidv4 required

The name of the collection

defaultCouponstring

The default coupon of the collection

Example response

{
  "name": "SummerPromotions",
  "id": "23befbae-1505-47a8-bd27-e30ef739f32c",
  "defaultCoupon": "10 OFF"
}