Rewards (redemption by code)
Access Prerequisites
- Permission (module):
viewCommissionsORmanageCommissions - License/Feature: None
- Menu container: GENERAL → group Commissions and Rewards
What it is / when to use
Screen for reward campaigns by redemption code. You register a reward (a Token or an NFT) associated with a redemption code and a campaign window (start/end date). The system generates a QR Code / link that, when scanned by the user, opens Midas-Web already with the redemptionCode in the URL for redemption.
Use for promotional campaigns (gift by code), distribution of event NFTs, or token bonuses tied to a printed/published code. Do not confuse with the Rewards Club (missions/tiers) — here it is a one-off redemption by code.
Prerequisites
- Permission:
viewCommissionsormanageCommissions(dual permission: CPM enum + dynamic module in the DB). - License/Feature: None.
- Dependencies from other screens: the Token (Tokenization → Manage Tokens) or the NFT (Tokenization → NFTs/Assets) to be given as a reward must exist beforehand — the form only accepts selecting an already-registered asset/token (validated autocomplete).
Step by step
- Access the menu Commissions and Rewards → Rewards (
/manage-reward-config/list). - The list shows rewards with name, asset, type, and an activation toggle. Use the search and pagination (server-side) to locate entries.
- Click New to open the creation form.
- Choose the Reward type (NFT or Token), search and select the asset/token (the "validated" chip appears upon selection), set name, redemption code, campaign dates, and, for Token, the quantity.
- Save. The redemption QR Code/link is built from the code and can be copied or downloaded.
Fields
| Field | What it is | Required? | System/backend effect |
|---|---|---|---|
Name (name) | Internal name of the reward campaign | Yes | Identifies the configuration; max. 200 characters. |
Reward type (rewardType) | NFT or Token | Yes | Defines which catalogue the autocomplete searches (NFTs/assets or tokens) and whether the Quantity field is shown. Changing the type clears the selected asset. |
Asset/Token (assetId) | Asset (NFT) or token granted as a reward | Yes | Resolved by validated autocomplete against the real catalogue. Backend errors handled: "NFT not found" / "Token not found". |
Redemption code (redemptionCode) | Code the user enters to redeem | Yes | Must be unique; backend rejects with "redemption code is already in use". Composes the redemption URL/QR. Max. 50 characters. |
Quantity (quantity) | Number of tokens to credit | Conditional (Token only) | Only shown and sent when rewardType = Token; discarded for NFT. |
Start date (campaignStartDate) | Campaign validity start | Yes | Defines when the redemption becomes valid. Timezone adjustment applied on load/edit. |
End date (campaignEndDate) | Campaign validity end | Yes | Defines the closing of the redemption window. |
QR Code / Link (qrcodeImg) | Redemption image/URL | Generated | Built as <host>/home?redemptionCode=<code>; can be copied or downloaded as PNG. |
Active (isActive) | Turns the campaign on/off | — | Toggle in the listing; opens a confirmation before activating/deactivating. An inactive reward cannot be redeemed. |
Actions and modals
- New / Edit / View: the form operates in three modes. In view mode fields are disabled and an Edit button is shown. The Save button is only enabled when name, asset, type, redemption code, and both dates are filled in.
- Copy URL / Download image: copies the redemption link or downloads the QR Code as
code-reward-<code>.png. - Active toggle: activates/deactivates the campaign with a confirmation (bottom-sheet). On error, the toggle is reverted.
- Delete (trash icon): confirms and removes the configuration.
Business rules / considerations
Attention
- The redemption code is unique per tenant — reusing an existing code is rejected by the backend.
- The asset/token must exist and be valid at the time of creation; the autocomplete does not allow typing an arbitrary id without validation.
- The campaign window (start/end) delimits the redemption; outside that window the code does not grant the reward.
- Financial values: the token quantity is handled with precision; check the decimal places of the chosen token.