rebootpy.ext.commands extension provides a framework for building command-based bots with features like command parsing, argument handling, checks, and cooldowns.
Installation
The commands extension is included with rebootpy:Bot Class
TheBot class extends rebootpy.Client with command functionality:
Command Prefix
The command prefix determines what triggers a command. It can be: String prefix:Creating Commands
Use the@bot.command() decorator to create commands:
Command with Arguments
Command Attributes
Command Groups
Group related commands together:!party join, !party leave
Invoke Without Command
Checks
Restrict command usage with checks:Built-in Checks
Custom Checks
Check Any
Allow command if any check passes:Global Checks
Apply checks to all commands:Check Once
Check that runs only once per command invocation:Cooldowns
Limit command usage rate:Bucket Types
BucketType.default- Global cooldownBucketType.user- Per userBucketType.party- Per party