The config
command allows you to configure all settings for the server, such as roles, channels, reaction roles,
and other customizable behavior of MoonlightBot. To get the current configuration of a setting, just use the
corresponding sub command without any optional options.
{% hint style="info" %}
If an option provides you with the option Open Editor
like the option custom-notification-text
of
the roles on-expire
command, it means that a modal textbox will open for
you to input your desired text.
All default values are either 0
, false
or empty for their respective options, unless stated otherwise.
{% endhint %}
MoonlightBot requires the following permissions to successfully execute this command:
No specific permissions required
By default, a user is required to have the following permissions to use this command:
- Manage Server
For more information on editing permission requirements for specific users/roles, refer to the permissions tutorial
This command allows you to set a role to be persistent or not. A persistent role means that when the user rejoins the server, they will automatically get the role back.
{% hint style="info" %} This command may be expanded in the future to allow for more role settings. {% endhint %}
/config roles edit <role> [persistent]
role
: The role to be editedpersistent
: Whether the role should be persistent or not (True/False)
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command allows you to set up a custom notification for when a temporary role expires.
/config roles on-expire <role> [notify] [custom-notification-text]
role
: The role for which the notification should be setnotify
: Whether to notify the user when the role expires (True/False)custom-notification-text
: This opens a modal textbox to set a custom notification message
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command allows you to set up a role to be self-assignable by users. This allows them to assign the role to
themselves via the /selfrole
command without needing a moderator to do it
for them, and they can remove it themselves as well. It works on a vice versa basis.
/config roles self-assignable <role> [enabled] [duration] [max-times]
role
: The role to be set as self-assignableenabled
: Whether the role should be self-assignable or not (True/False)duration
: The duration for which the role should be assignedmax-times
: The maximum number of times the role can be assigned
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command allows you to set up a role to be assigned to a user when they join the server. This role can be set up to be a temporary role, and it can be set up to be assigned a maximum number of times.
/config roles join-assignable <role> [enabled] [duration] [max-times]
role
: The role to be assigned when a user joins the serverenabled
: Whether the role should be assigned when a user joins the server (True/False)duration
: The duration for which the role should be assignedmax-times
: The maximum number of times the role can be assigned
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command allows you to set up a detection system for a role that is assigned to a user by another bot or a moderator. It will change the role to a temporary role and remove it after a certain duration.
{% hint style="warning" %} This setting requires that MoonlightBot has access to the audit logs to detect the assignment of roles by other bots or moderators. {% endhint %}
/config roles detect-assignment <role> [enabled] [duration] [include-bots]
role
: The role to be detectedenabled
: Whether the detection system should be enabled or not (True/False)duration
: The duration for which the role should be assignedinclude-bots
: Whether to include bots in the detection system (True/False)
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command allows you to set up in which channels MoonlightBot logs, ignores mute evasion bans, and sends ephemeral replies.
/config channels <channel> [logs] [ignore-mute-evasion-ban] [ephemeral-replies]
channel
: The channel to be configuredlogs
: To open the editor to set up the logs. You can view the available logs under the List of log namesignore-mute-evasion-ban
: Whether the Bot should consider messages sent in this channel to be an evasion of a mute or not (True/False)ephemeral-replies
: Whether the Bot should mark command replies as only viewable by the user who triggered the command (True/False)
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command allows you to set up and manage groups for reaction roles. If the group does not exist, it will be created.
{% hint style="info" %}
For information on how to delete a group, refer to
the /reaction-roles delete
command and for information on how to set up
reaction roles, refer to the Setting up reaction roles
tutorial.
{% endhint %}
/config reaction-roles <group> [join-only] [leave-only] [reverse] [max-roles] [dm-notification] [freeze] [duration]
group
: The group to be configured or createdjoin-only
: Prevents the user from removing their role(s)leave-only
: Prevents the user from assigning the role(s)reverse
: When the message is reacted to, it will remove the role instead of assigning it, and vice versamax-roles
: The maximum amount of roles within the group a user can assign themselvesdm-notification
: When a role is assigned/removed, the bot will message the user (true by default)freeze
: When true, the group will not function. This is a quick way to disable reaction roles without taking irreversible actions, such as deleting the group/message or removing reactions from the messageduration
: How long the user will keep their assigned role(s)
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command allows you to set up the settings for the server, such as the mute role, mute evasion ban, and locale.
{% hint style="info" %}
Note that you can make exceptions to the mute-evasion-ban
via the
channels
subcommand.
{% endhint %}
/config settings [mute-role] [mute-evasion-ban] [locale]
mute-role
: The role to be used as the mute role which can be created via the/create-muterole
commandmute-evasion-ban
: If the bot should automatically ban anyone who sends a message and has the mute role to avoid punishment evasionlocale
: The language to be used for the server
MoonlightBot requires the following permissions to successfully execute this subcommand:
No specific permissions required
This command does not trigger any log events.
For more information on setting up those logs, refer to the log setup tutorial