This API is used to update catalog promotion and link/de-link to a reward(s)
Expired: Do not allow any of the fields to be edited.
Running:
- Cannot change: start date, discount_type, discount_value.
- Can change (impacts rewards discounted points)
end date: end date >= now and end date >= start date.
isEnabled - Disable but cannot enable again. After disabling, the linked reward can be linked to another active promotion. Re-enabling will violate the constraint of only one reward linked to an active promotion.
Linking a reward - update the link table accordingly.
Unlinking a reward - Set isActive = false in the link table.
- Can change other details of the promotion (name, desc….etc)
Scheduled: Similar to running but start_date, discount_type, discount_value fields also can be updated.
Cannot delete a promotion similar to a reward.
NoteFor detailed information about our APIs and for hands-on testing, refer documentation in API overview and step-by-step guide on making your first API call in Make your first API call.
Example request
curl --location --request PUT 'https://eu.api.capillarytech.com/api_gateway/rewards/core/v1/promotion/14862/brand/61' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'accept: application/json' \
--header 'Authorization: Basic bWFkaHV2YQ==' \
--header 'Cookie: _cfuvid=qrR26fiL9O7hSaVDD64eltEicRcuyxTkMuk2MPS2moc-1764581884487-0.0.1.1-604800000' \
--data '
{
"startTime": "2025-12-04T10:08:00.000Z",
"endTime": "2025-12-14T06:10:00.000Z",
"discountType": "PERCENTAGE",
"discountValue": 20,
"brandId": "61",
"languageSpecificInfo": [
{
"languageCode": "en",
"name": 72738382,
"description": 7273838,
"enabled": true
}
],
"rewardIds": [
496584
]
}
'Prerequisites
- Authentication: Basic or OAuth authentication
- Default access group
Resource information
| URI | /api_gateway/rewards/core/v1/promotion/{promotionId}/brand/{brand Id} |
| HTTP Method | PUT |
| Pagination | No |
| Batch support | No |
| Rate limit information | None |
Request path parameters
| Parameter | Data Type | Description |
|---|---|---|
| brandId* | Long | You can use the API and retrieve the brand ID of your brand. |
| Promotion Id* | String | Unique identifier for the promotion. Ex: 112295 |
Request body parameters
| Parameter | Data Type | Description |
|---|---|---|
| endTime | String | The end time of the promotion. Ex: 2024-10-25T11:16:00Z |
| startTime | String | The start time of the promotion. For example: 2025-12-04T10:08:00.000Z |
| discountType* | Enum | Type of discount applied to the promotion. Supported values: ABSOLUTE, PERCENTAGE, FIXED |
| discountValue* | Number | Value of the discount. |
| languageSpecificInfo | Array | Array containing language-specific information. |
| .languageCode | String | Language code for the specific entry. Ex: en |
| .name | String | Name of the item in the specified language |
| .description | String | Description of the item in the specified language |
| .enabled | Boolean | Indicates if the language specific info is enabled |
| rewardIds* | Array of Integers | Array of reward IDs associated with the promotion |
Example response
{
"status": {
"success": true,
"code": 11021,
"message": "Catalog promotion updated successfully."
},
"catalogPromotion": {
"id": 14862
},
"failedRewards": []
}Response parameters
| Parameter | Data Type | Description |
|---|---|---|
| status | Object | Container for the status information |
| success | Boolean | Indicates the success of the operation |
| code | Integer | Status code for the operation |
| message | String | Description message of the operation status |
| catalogPromotion | Object | Container for catalog promotion information |
| id | Integer | Unique identifier of the catalog promotion |
| failedRewards | Array (Empty in this case) | Array containing any failed rewards information |
{
"status": {
"success": true,
"code": 11021,
"message": "Catalog promotion updated successfully."
},
"catalogPromotion": {
"id": 8
},
"failedRewards": []
}Error codes
| Error code | Description |
|---|---|
| 11021 | Catalog promotion updated successfully |
| 11025 | Invalid discount value. This error occurs when the discountValue parameter is missing. |
| 11020 | Catalog promotion end time cannot be before start time. |
| 11015 | Reward expired or disabled or free. Cannot apply catalog promotion. Ensure to provide a active rewardId. |
| 6004 | Reward not found or disabled. Ensure to provide a valid rewardId. |
| 500 | Internal server error. |
