curl --request POST \
--url https://uat-api.clinkbill.com/api/coupon \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--header 'X-Timestamp: <x-timestamp>' \
--data '
{
"couponName": "Summer Sale",
"discountType": "percentage",
"percentage": 20,
"applyType": "product",
"applicableProducts": [
"prd_xxxxx"
],
"durationType": "once",
"maxRedemptionCount": 100,
"validPeriodStart": 1780660800000,
"validPeriodEnd": 1783252800000,
"promotionCodes": [
{
"code": "SUMMER2026",
"maxRedemptionLimit": 100
}
]
}
'{
"code": 200,
"msg": "success",
"data": {
"couponId": "<string>",
"couponName": "<string>",
"discountType": "percentage",
"percentage": 123,
"fixedAmounts": {},
"durationType": "once",
"durationMonths": 123,
"maxRedemptionCount": 123,
"redeemedCount": 123,
"validPeriodEnd": 1754819711382,
"mirroring": true,
"terms": "<string>"
}
}"<string>"Create Coupon
Create a coupon and optionally create promotion codes for it.
curl --request POST \
--url https://uat-api.clinkbill.com/api/coupon \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--header 'X-Timestamp: <x-timestamp>' \
--data '
{
"couponName": "Summer Sale",
"discountType": "percentage",
"percentage": 20,
"applyType": "product",
"applicableProducts": [
"prd_xxxxx"
],
"durationType": "once",
"maxRedemptionCount": 100,
"validPeriodStart": 1780660800000,
"validPeriodEnd": 1783252800000,
"promotionCodes": [
{
"code": "SUMMER2026",
"maxRedemptionLimit": 100
}
]
}
'{
"code": 200,
"msg": "success",
"data": {
"couponId": "<string>",
"couponName": "<string>",
"discountType": "percentage",
"percentage": 123,
"fixedAmounts": {},
"durationType": "once",
"durationMonths": 123,
"maxRedemptionCount": 123,
"redeemedCount": 123,
"validPeriodEnd": 1754819711382,
"mirroring": true,
"terms": "<string>"
}
}"<string>"Authorizations
Your secret API key obtained from the Clink dashboard (Developers section)
Headers
Current timestamp in milliseconds since Unix epoch (required for request signing)
"1783513683000"
Body
Parameters required to create a coupon
Coupon name
40Discount type
percentage, fixed_amount Coupon applicability type
none, product, price Discount duration type
once, repeating, forever Percentage discount. Used when discountType is percentage.
0 <= x <= 100Fixed discount amount by currency. Used when discountType is fixed_amount.
Show child attributes
Show child attributes
{ "USD": 5, "EUR": 4.5 }
Product IDs this coupon applies to
Price IDs this coupon applies to, grouped by product ID
Show child attributes
Show child attributes
Number of billing periods for repeating coupons
Maximum total redemptions for this coupon
Coupon validity start time as a 13-digit Unix timestamp in milliseconds
1780660800000
Coupon validity end time as a 13-digit Unix timestamp in milliseconds
1780660800000
Promotion codes to create together with the coupon
20Show child attributes
Show child attributes