Skip to Content
Haven Documentation is the shared home for product guides, plugin setup, and release docs.
PluginsDaily RewardsCommands and Workflow

Daily Rewards Commands And Workflow

Command

CommandBehavior
/dailyrewards updateCreates the calendar message or updates the existing one for the current configured day.

The reply is private. The default command permission is management, and the command wording can be changed in the language config.

Startup And Scheduled Updates

When the plugin starts with enabled: true, it immediately builds the current calendar. The repeating scheduler then checks settings.updateCheckIntervalMs and updates once per local date after settings.updateTime is reached.

The plugin stores the calendar message ID and edits the same message. If that message no longer exists, it posts a new one.

Claim Workflow

  1. A member presses the current day’s claim button.
  2. The plugin verifies the calendar’s year, month, and day.
  3. It checks the active month and configured day range.
  4. It rejects duplicate claims for that calendar date.
  5. It applies the short button cooldown.
  6. It chooses a rarity using the current month’s chance weights.
  7. It randomly selects one reward from that rarity pool.
  8. It applies the reward and sends a private response.
  9. It stores the claim, optionally logs it, and refreshes the calendar and leaderboard.

Reward Delivery

  • XP and COINS update Athena’s member data.
  • ROLE assigns the configured Discord role when permissions and hierarchy allow it.
  • MESSAGE sends the configured reward text for staff-fulfilled prizes.

A claim is stored only after the reward handler reports success.

Calendar Components

The message contains:

  • A generated calendar image with the current day highlighted
  • A generated leaderboard image for the day’s successful claims
  • A claim button for the active day
  • An informational countdown button showing the time until the next local day

The current-day button is disabled outside the configured event month or day range.

Claim Logs

When daily_rewards_log is configured, each successful claim logs the member, day, reward type, rarity, and displayed value. Logging is optional and does not control reward delivery.