Slash Command Cooldown¶
Note
The cooldown API is an old and rarely used feature. Thus, revisiting it isn't a top priority in JDA-Commands development. If you want it to be improved, feel free to open an issue.
Slash commands can have a cooldown to limit their usage. The cooldown is applied globally, per user, per command.
You can add a cooldown by annotating a slash command method with @Cooldown
.
Example
If a command still has a cooldown, an error message gets sent to the user.
You can customize this error message, find more about it here.