Docs / Getting started / Command Access and presets

Command Access and presets

Who can run which command. Presets, role and channel locks, cooldowns, and the order the rules are checked in.

Every built-in command can be limited per server. Open the dashboard, then Services, pick a service and open Commands. The same page exists for every service that registers slash commands.

Two layers

Discord applies a first layer before YourBot sees anything. Each command carries a default permission chosen by the service, for example Manage Messages on /lockdown. Discord hides the command from members without that permission. Server admins can change these under Server Settings, Integrations in Discord itself.

YourBot applies a second layer when the command is run. That is Command Access, and it is what this page describes. It can only narrow, never widen, what Discord allows.

Presets

A preset writes a rule for every command of one service in one click. Each command's docs page shows the category the preset uses.

Preset Moderation and Admin commands Info and Member commands
Default Only the moderator roles you pick Everyone
Strict Only the moderator roles you pick Everyone
Open Everyone Everyone

Default and Strict differ in what else the service does with the moderator roles, not in the command rules, which are the same for both. A preset needs at least one moderator role. Applying one replaces the service's existing command rules.

Per-command rules

After a preset, or instead of one, each command can carry its own rule:

  • Allowed roles. When set, only members holding one of them can run the command.
  • Allowed channels. When set, the command works only in those channels.
  • Cooldown. Seconds a member must wait between two runs.
  • Disabled. Nobody except the server owner can run it.
  • Allowed members and blocked members, for exceptions to the role rules.
  • Admin bypass. Whether members with Discord's Administrator permission skip the role, channel and cooldown checks. On by default.

The order rules are checked

The first matching line decides.

  1. The server owner can always run everything.
  2. A disabled command is refused for everyone else.
  3. A blocked member is refused, even an Administrator.
  4. With admin bypass on, an Administrator is allowed and skips the rest.
  5. An allowed member is allowed and skips the role check.
  6. A member holding a denied role is refused.
  7. If allowed channels are set and this is not one of them, refused.
  8. If allowed roles are set and the member holds none, refused.
  9. If a cooldown is set and the member ran it too recently, refused with the time left.

Marketplace plugin commands are checked by the same rules from the same page.

Renaming a command

A built-in command can be renamed for your server from the same Commands page. The renamed copy keeps the original's options and rules. The new name cannot collide with another command in the server.

What the docs show

Each command's page has a Who can run it block. Discord default is the first layer above. Command Access preset is what the Default preset would set for it. Always allowed reminds you that the owner and, with admin bypass, Administrators are never locked out. Change it points to the dashboard page.

YourBot docs Reference tables are generated from the code that is running. Ask in Discord Suggest a correction