π Secret Codes
Secret codes are reward phrases you hand out however you like β in announcements, at events, hidden in messages β and members redeem in Discord with /redeem. Each code pays out XP, a role, or coins, and can be limited to a single use.
Overviewβ
When configured, the agent can:
- Reward the members who redeem a code with XP, a role, or coins
- Enforce single-use codes β first member to redeem wins
- Delete the message that contained a code once it's been redeemed
- Log redemptions to a channel of your choice
Configurationβ
To configure secret codes:
- Open your project in the Fren One webapp.
- Select the Discord server you want to configure.
- In the sidebar under Agent Configuration, select Gamification, then the Secret Codes tab.
Redemption settingsβ
| Option | Description |
|---|---|
| Delete messages that contain a code after redemption | Cleans up the channel by removing the message that posted the code once a member has redeemed it. Default: on. |
| Log channel | Optional channel to log code redemptions. |
Creating codesβ
Select "New Code" to open the code editor. Each code in the list shows the code itself, Single-use and Inactive pills where they apply, and its reward type, value, and use count.
| Option | Description |
|---|---|
| Code | The phrase members type to redeem the reward, e.g. LAUNCH2024. Required; cannot be changed after creation. |
| Reward Type | XP (default), Role, or Coins. |
| Reward Value | The size of the reward. Default: 100. |
| Single use | Only the first member to redeem gets the reward. Default: off. |
| Active | Whether the code can currently be redeemed. Default: on. |
How it works in Discordβ
Members redeem a code with /redeem and receive the reward immediately β XP added to their balance, the role granted, or coins credited. Single-use codes are enforced: once redeemed, later attempts fail. When a Log channel is set, each redemption is logged there, and redemptions can also appear in the mod log.
With the deletion setting on, the agent removes the message that contained the code after it's redeemed, so a code posted in chat doesn't linger once it's spent.
For role rewards, the agent's role must sit above the granted role in your server's role hierarchy.
Saving your changesβ
This page uses a batched save β edits stay local until you select Save in the bar that appears at the bottom of the page. Deleted codes stay visible with an Undo option until you save. Leaving the page with unsaved changes shows a warning first.
Best practicesβ
- Use single-use codes as prizes β drop one in chat during an event and let the fastest member claim it.
- Deactivate codes instead of deleting them when a campaign ends; you can reactivate the same code later.
- Set a Log channel so you can see who redeemed what, especially for high-value rewards.
- Pick memorable, typo-proof codes like
LAUNCH2024β members type them by hand.
Troubleshooting
/redeem isn't accepting a code?
- Check the code's Active toggle β inactive codes can't be redeemed.
- Single-use codes only work once; if someone beat them to it, the code is spent.
A role reward wasn't granted?
- The agent's role must be above the reward role in the server's role hierarchy.
I made a typo in a code?
- The code itself is immutable after creation. Deactivate or delete the bad code and create a new one.
Related featuresβ
- β¨ XP & Levels - Where redeemed XP counts toward levels and role rewards
- πΊοΈ Quests - Structured challenges alongside one-off code drops
- π Role Manager - Other ways to grant roles automatically