Custom Field Information for Badges

Overview

To create a flexible badges platform, it is important to give brands the ability to include additional, custom information when creating badges. This custom data can be used for various purposes such as displaying personalized information within the app or website, and for accounting or reporting purposes.
Additionally, this custom data can also help brands to track and analyze the performance of their badges, and make data-driven decisions to improve their badges strategy. Furthermore, the ability to include custom data can also help brands to comply with legal and regulatory requirements, and to report on the performance of the badges to stakeholders.

Usecase

A retail brand aims to establish a badges platform to reward loyal customers and foster engagement through their mobile app. To personalize the badge experience, the brand intends to display custom information associated with each badge earned by users. To implement this the brand can perform the following:

  1. Create a custom field named "Terms & Conditions" with the data type set as STRING.
  2. Create a badge and assign this custom field "Terms & Conditions," ensuring to populate it with relevant information.

When a customer earns the badge, it will be showcased along with the "Terms & Conditions" field, providing users with pertinent details about the badge. Examples of custom field content may include terms and conditions, redemption instructions, brief descriptions, legal text, exclusivity status, purpose, etc.

Notes

  1. Custom fields can be created, updated, or disabled.
  2. There can be only one active custom field with the same name. If the existing custom field is disabled, then a new custom field with the same name can be created.
  3. It is mandatory to define the default value for a custom field which is mandatory for the badge. In case a badge doesn't define a mandatory custom field with it, the default value will be considered.
  4. Data types supported in custom fields: boolean, integer, string, and date.
  5. Once the custom field is disabled, it can't be enabled again.
  6. Only active custom fields will be returned in all the getcalls.
  7. Only below fields can be updated while updating the custom field:
    1. Name : can be updated
    2. Isactive : can be updated from true to false but false to true is not allowed
    3. Default value can be updated
    4. Ismandatory can be updated from true to false or false to true
    5. Data type can’t be updated
  8. There is no limit on the number of custom fields that can be defined at an org level for badges.

Creating Custom Fields from Badges UI

  1. Start by navigating to the badges UI and go to Settings.
  1. Select the option to Create Custom field.
  1. In the Name field, enter a name for the custom field and from the Data type drop-down, select the appropriate data type. The supported data types are Boolean, Date, Number and String. There is no limit set on the number of characters.
  1. To set the custom field to mandatory, set it to Yes. When a custom field is set to mandatory, it is linked to the Badges and will be part of the creation process.
  1. Click Done to finish creating the custom field.

The custom field is now successfully created.

Editing a custom field

  1. Custom field can be edited by clicking on the Edit option.
  1. Make the required changes.

📘

Notes

  • When a mandatory field is changed to optional, it will be unlinked from all badges that previously relied on it. This means the field will no longer be required for those badges, and any validation or functionality tied to it will be removed.
  • The data type cannot be changed in edit mode.

Verify the creation of a custom field

  1. To verify the addition of the custom field, return to the badges UI and hover over New badges to see the option to Create a badge. Click on it.
  1. Enter the necessary information to create a badge and click Next.
  2. Select the owner of the badge.
  3. Scroll down to see the mandatory custom fields under the Custom fields section. The custom fields that were created as non-mandatory are available as a selection.

Creating custom fields for badges using APIs

For more information on the APIs related to custom fields for badges, check the below links: