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>"Coupon
创建优惠券
Create a coupon and optionally create promotion codes for it.
POST
/
coupon
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>"请求头
请求体
application/json
Parameters required to create a coupon