Update Reward Category

Enable or disable a particular reward category.

This API lets you enable or disable a particular reward category. A Reward Category is a metadata attribute used to classify rewards into predefined groups based on their nature or purpose. For example, categories can include fashion, electronics, or groceries.

👍

Note

For 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 .

Prerequisites

  • Authentication - Basic or OAuth authentication details
  • Default access group
  • Brand ID
  • Category ID

Resource information

URL/api_gateway/rewards/core/v1/metadata/category/{categoryid}/status/{action}/brand/{brandid}
HTTP methodPUT
PaginationNA
Rate limitNA
Batch supportNA

API endpoint example

https://eu.api.capillarytech.com/api_gateway/rewards/core/v1/metadata/category/129/status/enable/brand/55

https://eu.api.capillarytech.com/api_gateway/rewards/core/v1/metadata/category/129/status/disable/brand/55

Request path parameters

Parameter
(Parameters marked with * are mandatory)
Data TypeDescription
categoryId*IntegerUnique identifier for the reward category that needs to be enabled or disabled. It is generated when a reward category is created.
brandId*IntegerUnique identifier for the brand under which the reward category is associated. To retrieve brandId, refer to the Retrieve Brand ID API .
action*EnumAction to be performed.
Supported values: enable or disable
Enable - To enable the reward category.
Disable - To disable the reward category.
curl --location --request PUT 'https://eu.api.capillarytech.com/api_gateway/rewards/core/v1/metadata/category/129/status/enable/brand/55' \
--header 'Content-Type: application/json' \
--header 'Accept: */*' \
--header 'Authorization: Basic Ymxpc3M6MWYjNzU5MWI1NzY='
curl --location --request PUT 'https://eu.api.capillarytech.com/api_gateway/rewards/core/v1/metadata/category/129/status/disable/brand/55' \
--header 'Content-Type: application/json' \
--header 'Accept: */*' \
--header 'Authorization: Basic Ymxpc3M6MWY5OzU5MWI1NzY=' \
--header 'Cookie: _cfuvid=01ByJlrmtNbRIQOhhldILHP3lz5mNj3NHtc7Tkf5cH0-1733290794337-0.0.1.1-604800000'

Response parameters

ParameterData TypeDescription
statusObjectContains information about the success or failure of the API call.
-successBooleanIndicates whether the operation was successful. Values: true or false.
-codeIntegerStatus code indicating the result of the operation. Example: 2006 for success.
-messageStringDescriptive message about the result of the operation. Example: Category updated successfully.
{
    "status": {
        "success": true,
        "code": 2006,
        "message": "Category updated successfully"
    }
}

API error codes

Error CodeMessageDescription
3004Brand not foundInvalid brandId
2004Category not foundInvalid categoryId
Language
Credentials
Basic
base64
:
URL
Click Try It! to start a request and see the response here!