Skip to content

Command rules

A command rule says who can run one command. It can require:

  • a minimum level: everyone at that level or above;
  • one or more roles: anyone holding one of them, whatever their level;
  • one or more members, by name.

These three combine with OR: a member who matches any of them can run the command. Everybody else is refused, including Administrators, except the server's iHorizon owners.

A rule replaces the Discord permission

Without a rule, /mod ban asks for Discord's Ban Members. With a rule, iHorizon only checks the rule: a Perm 5 member can ban without Ban Members, and an Administrator who isn't Perm 5 can't. Put rules on what you want to delegate, and think twice before putting a low level on a powerful command (backup load, perm, mod lock-all…).

/perm command action [command] [permission] [custom-role] [custom-user]

Option What it does
action Change command permission, Delete command permission, Delete permission (role/user/level), List all commands permission set
command The command, as you type it after /, with autocomplete: mod ban, music play, economy rob, ticket close…
permission The minimum level, Perm 1 to Perm 9; Default removes the level
custom-role A role to add to the rule (or remove, if it's already in it)
custom-user A member to add to the rule (or remove, if they're already in it)

Change a rule

Set any mix of permission, custom-role and custom-user in one go. Roles and members toggle: picking a role that's already in the rule removes it. iHorizon answers with what changed:

/perm command action: Change command permission command: mod ban permission: Perm 5 custom-role: @Raid Response
iHorizonAPPToday at 20:30
Subcommand : mod ban
Changed permission level: None ➡️ 5
Added Role: @Raid Response

From now on: Perm 5+ members, and members of @Raid Response at any level, can ban.

If the rule ends up empty (no level, no role, no member), it's removed and iHorizon says "This command has been reset": the command goes back to its Discord permission.

A rule on a whole command

You can put a rule on a top-level command: mod, music, ticket… It then covers every subcommand that has no rule of its own:

  • Rule mod = Perm 3 → mod warn, mod clear, mod kick… all need Perm 3.
  • Add rule mod ban = Perm 5 → mod ban needs Perm 5; the others still Perm 3.

Use this to lock a whole category in one line, then refine the sensitive subcommands.

Only the top-level command works this way. For commands with groups, like economy role add, put the rule on economy (everything) or on each subcommand: a rule on the group alone (economy role) isn't used.

Delete one rule

Delete command permission with command removes the rule of that command entirely. It goes back to its Discord permission (or to the rule of its top-level command, if there is one).

/perm command action: Delete command permission command: mod ban
iHorizonAPPToday at 20:33
Deleted permissions for command: mod ban

Delete a level, a role or a member everywhere

Delete permission (role/user/level) cleans up across all rules at once. Give exactly one of permission, custom-role or custom-user:

You give What is removed
A level Every rule that uses this level is deleted entirely, including its roles and members
A role This role is removed from every rule (rules left empty are deleted)
A member This member is removed from every rule (rules left empty are deleted)

Typical uses: a moderator leaves the team (remove them everywhere), you merge two ranks (drop a level).

List the rules

List all commands permission set shows every rule, grouped: one block per level with its commands, then one block per role and per member. Eight blocks per page, with ◀ ▶ buttons.

/perm command action: List all commands permission set
iHorizonAPPToday at 20:35
Permission 3: mod, mod warn, mod clear
Permission 5: mod ban, mod tempban, mod unban
Permission 9: backup load, perm
@Raid Response: mod ban, mod lock-all
◀▶

What a refused member sees

A member who doesn't match the rule gets a private answer telling them what the command requires: the level, and the roles or members allowed.

/mod ban
iHorizonAPPToday at 20:40
@Noah, you are not allowed to use this command! You need this permission: 5 Roles: @Raid Response
Only you can see this message

Good to know

  • Slash and prefix share the rules. A rule on mod ban also applies to +ban.
  • Rules on /perm itself are possible, for example perm set-user = Perm 8 to let your head admins manage member levels without Administrator. Then only those members (and the owners) can use it. /perm create-roles and /perm edit-roles still require the Discord server owner whatever the rule.
  • Deleted roles in a rule simply never match anyone. Clean them up from the dashboard (module Permissions), or remove the rule.
  • The help shows your rules: padlocks in /help, and +helpall lists the restricted commands a member can use. See What members see.

Next