-
Notifications
You must be signed in to change notification settings - Fork 2
Extension: roles
Allows users to opt-in/out to/from configurable roles.
-
database
: The database configuration. This must be set explicitly, as it otherwise defaults to an in-memory cache that does not persist data.
Note that in all cases, a role
argument must match the corresponding role name exactly. If the role has spaces, use quotes "
to surround it.
These commands are available to all regular users.
roles show
roles
Prints a list of roles, but only those that are relevant to the user who ran the command. For example: non-joinable roles will not be displayed for regular users.
roles join <role>
join <role>
Join role
. Has no effect if the acting user already has the role or the role is not joinable.
roles leave <role>
leave role
Leave role
. Has no effect if the acting user does not already have the role or the role is not leavable.
These commands are available to administrators of the guild, as well as select users/roles on a per-guild basis.
roles add <role> [members...]
Add role
to one or more members
. Has no effect on members that already have the role.
roles remove <role> [members...]
Remove role
from one or more members
. Has no effect on members that do not already have the role.
roles all
Prints a list of all roles, regardless of their relevance.
These commands are available only to administrators of the guild.
roles register <role> [joinable=True] [leavable=True] [description]
Adds a role to the list of managed roles, with the given flags:
-
joinable
: whether regular users can opt-in to the role. -
leavable
: whether regular users can opt-out of the role. -
description
: an optional description of the role that will be visible to regular users.
roles deregister <role>
Removes a role from the list of managed roles. This does not remove the role itself from the guild.