Create Rich Text Content Metadata for Rewards

The Rich Content Metadata feature allows brands to define and manage rich text content for rewards. Rich text includes content such as:

  • Detailed reward descriptions.
  • Custom terms and conditions.
  • Any dynamic content to enhance the reward experience.
    This metadata is stored separately and can be linked to a reward using the Create Reward API.


    Note You can add a maximum of 20 Rich Content Metadata for an organization.

Prerequisites

  • Authentication: Basic or OAuth authentication

Resource information

URI/api_gateway/rewards/core/v1/brand/richContentMeta
HTTP MethodPOST

API endpoint example

https://{host}/api_gateway/rewards/core/v1/brand/richContentMeta

Request Body Parameters

ParameterTypeDescription
name*StringUnique identifier for the rich content metadata (Max: 256 characters).
descriptionStringDescription of the metadata (Max: 256 characters).
isMandatory*BooleanIndicates whether metadata is mandatory (true or false).
scope*EnumMust be "REWARD" (case-sensitive).
defaultValueStringThe default value is shown when rich text content is unavailable for a specific reward.

- Required: Only if isMandatory is set to true.
- Optional: If isMandatory is false.
- Max Length: 50,000 characters.
isActiveBooleanDefaults to true during Rich Text Content Metadata creation, even if set to false.

Note: defaultValue is required only when isMandatory is true.

Example Request

{
    "name": "terms&conditions",
    "description": "RC2_desc",
    "isMandatory": true,
    "isActive": true,
    "scope": "REWARD",
    "defaultValue": "here is your rich content"
}

 

Example Response

{
    "id": 9,
    "name": "terms&conditions",
    "description": "RC2_desc",
    "isMandatory": true,
    "isActive": true,
    "scope": "REWARD",
    "defaultValue": "here is your rich content",
    "createdBy": 75161973,
    "createdOn": 1743268460227,
    "lastUpdatedBy": 75161973,
    "lastUpdatedOn": 1743268460227
}

Response Parameters

Parameter NameData TypeDescription
idLongUnique identifier for metadata.
nameStringMetadata name.
descriptionStringMetadata description.
isMandatoryBooleanWhether metadata is mandatory.
isActiveBooleanStatus of metadata.
scopeEnumScope of the metadata.
defaultValueStringDefault assigned value.
createdByLongUser ID of the creator.
createdOnLongIndicates Creation timestamp. Timestamps are in UTC (milliseconds since epoch).
lastUpdatedByLongUser ID of the last updater.
lastUpdatedOnLongIndicates Last update timestamp. Timestamps are in UTC (milliseconds since epoch).

Note createdBy and lastUpdatedBy fields are automatically set based on the authenticated user.

Error Handling

HTTP Status CodeResolution
400 - Invalid request parameters.Ensure all required parameters are included in the request body.
400 - value is not one of declared EnumEnsure provided Enum field matches one of the supported values.
400 - defaultValue is required when isMandatory is true.Ensure defaultValue is not set to null, when isMandatory is set to true.
500 - Internal server error.Retry the request after a short delay. The issue may be temporary.
Language
Credentials
Basic
base64
:
URL
Click Try It! to start a request and see the response here!