Create Reward Category

Create a new reward category.

This API lets you create a new 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

Resource information

URL/api_gateway/rewards/core/v1/metadata/category/create
HTTP methodPOST
PaginationNA
Rate limitNA
Batch supportNA

API endpoint example

https://eu.api.capillarytech.com/api_gateway/rewards/core/v1/metadata/category/create

Request body parameters

Parameter (Parameters marked with * are mandatory)Data TypeDescription
brandId*LongUnique identifier for the brand. To retrieve brandId, refer to the Retrieve Brand ID API.
name*StringName of the reward category to be created. The name supports special characters, is not case-sensitive, and can be up to 255 characters in length.
{
  "brandId": 61,
  "name": "DOCDEMO22"
}

Response parameters

ParameterDescription
statusContains the status details for reward category creation.
-successIndicates whether the operation was successful. Values: true or false.
-codeResponse code for the operation. Example: 2002
-messageMessage describing the result of the operation.
categoryContains the reward category details.
-idUnique identifier for the created reward category.
-nameName of the created reward category.
-enabledCurrent active status of the reward category. If true, the reward category is currently active, else it is inactive.**Values: **true or false. When creating a reward category, the value is true.
lastUpdatedOnIndicates the timestamp when the reward category was updated. The timestamp is in Epoch time format.
lastUpdatedByThe till ID of the user who last updated the reward category.
createdByThe till ID of the user who created the reward category.
createdOnIndicates the timestamp when the reward category was created. The timestamp is in Epoch time format.
createdOnDateTimeIndicates the date and time when the reward category was created, formatted in ISO 8601.
lastUpdatedOnDateTimeIndicates the date and time when the reward category was updated, formatted in ISO 8601.

{
    "status": {
        "success": true,
        "code": 2002,
        "message": "Category save successfully"
    },
    "category": {
        "id": 344,
        "name": "DOCDEMO22",
        "enabled": true,
        "createdOn": 1748950177000,
        "lastUpdatedOn": 1748950177000,
        "createdBy": 75161973,
        "lastUpdatedBy": 75161973,
        "createdOnDateTime": "2025-06-03T11:29:37Z",
        "lastUpdatedOnDateTime": "2025-06-03T11:29:37Z"
    }
}
{
    "status": {
        "success": false,
        "code": 3004,
        "message": "Brand not found"
    },
    "category": null
}
{
    "status": {
        "success": false,
        "code": 400,
        "message": "name can't be null or empty."
    }
}

Error Codes

Error codeMessageDescription
3004brand not foundInvalid brandId in the request.
400name can't be null or empty.Name of the category has to be provided.
Language
Credentials
Basic
base64
:
URL
Click Try It! to start a request and see the response here!