Change Coupon Status
Using this API, you can change the status of a coupon code.
Request Type
- GET
Scope required
- ZohoCampaign.campaign.UPDATE
Other alternative scopes
- ZohoCampaign.campaign.CREATE-UPDATE (CREATE + UPDATE)
- ZohoCampaign.campaign.WRITE (CREATE + UPDATE + DELETE)
- ZohoCampaign.campaign.ALL (CREATE + UPDATE + DELETE + READ)
Header
Authorization: Zoho-oauthtoken <access_token>
Request URL
https://campaigns.zoho.com/api/v1.1/coupon/changestatus
API Limit
- Duration: 10 mins
- Number of calls: 100
- Lock Period: 30 mins
You can send 100 API calls per 10 minutes. If you hit this limit, you can't use this API for the next 30 minutes due to security reasons, but you can still use other APIs if their lock period hasn’t been reached.
List of Parameters --Version 1.1
| Parameter | Data Type | Description |
| type | String | XML (or) JSON |
| couponCode* | String | Get it from recent coupon campaign. |
| changeStatus | String | Give the value as "used" to update the coupon status. |
* - Mandatory Parameters
Sample XML Request
Copiedhttps://campaigns.zoho.com/api/v1.1/coupon/changestatus?type=xml&changeStatus=usedcoupon&Code=[CouponCode]
Sample Response
Copied<response uri="/api/coupon/changestatus" version="1.1">
<code>200</code>
<message>Coupon status changed to 'Used'</message>
</response>
Sample JSON Request
Copiedhttps://campaigns.zoho.com/api/v1.1/coupon/changestatus?type=json&changeStatus=used&couponCode=[CouponCode]
Sample Response
Copied{
"response": {
"message": "Coupon status changed to 'Used'",
"code": "200",
"uri": "/api/coupon/changestatus",
"version": "1.1"
}
}