Moderation Category Commands

These are tools designed to help with moderating a server.


+kick [Kick]

"makes me kick a user"

Permission: [Kick] This command requies the caller to have Kick Members.
This command kicks a member from the server. The member must be on the server.
The bot requires Kick Members to use this command and cannot kick members with equal or higher standing in the role hierarchy.

Usage:
+kick 'member' ['message']
Member is who to kick, message is an optional message to be PM'd to the target before being kicked.

+ban [Ban]

"makes me ban a user"

Permission: [Ban] This command requires the caller to have Ban Members.
This command bans (with delete) a member on the server.
The bot requires Ban Members to use this command and cannot ban members with equal or higher standing in the role hierarchy.

Usage:
+ban 'member' ['message']
Member is who to ban, message is an optional message to be PM'd to the target before being banned.

+softban [Softban]

"makes me kick a user and deletes their messages"

Permission: [Softban] This command requires the caller to have either Ban Members or Kick Members and Manage Messages
This command kicks a user and deletes all their recent messages.
Because the mechanic behind this is to ban (with delete) and then unban, the bot requires Ban Members. She also cannot softban members with equal or higher standing in the role hierarchy.

Usage:
+softban 'member' ['message']
Member is who to kick, message is an optional message to be PM'd to the target before being kicked.

+xban [Ban]

"bans an ID from the server"

This command is used to preemptively ban members from a server, or ban members who have left already.
Unlike most other similar commands, this one only accepts an ID (not Discord Tag.)
Also unlike ban, this command will fail if your target is a member of the server. You should use +ban instead.
The bot requires Ban Members.

Usage:
+xban 'ID'
ID is the 17-18 digit ID number of the target. This can be found by enabling developer mode and right clicking on a users name or avatar.

+remove [Server Mod]

"makes me delete messages from chat"

This command purges messages from a channel that matches a specific criteria.
Limit is number of messages that will be scanned, not removed, and defaults to 100.
(i.e. If you remove with a limit of 200 from a specific user, it might catch closer to 60 messages than 200.)

All remove commands will return a small chart of who sent the messages that were deleted, or in the case of purging reactions, which reactions were most common and who posted them.

Due to the nature of Delete Many, you cannot delete messages older than 2 weeks, and due to how the bot handles it, this means you cannot even include 2 week old messages inside the limit range at all.

Usage:
+remove all ['limit']
Deletes all messages in the limit regardless of what it says and who sent it.
+remove user 'member' [['member' ...] 'limit']
Deletes messages sent by the given members. To include multiple members, you must add the limit.
Because of how the bot selects members, supplying a role mention will not purge from members of the role and instead ask which singular member of the role to use.

+remove contains 'content' ['limit']
Deletes messages that contain a given keyword. This must be at least 3 letters long.
+remove embeds ['limit']
Deletes messages that contain any embeds or attachments. Useful for image spam.
+remove command 'call' ['call' ...] ['limit']
Deletes messages that start with a given call character. This follows tulpa compliancy.
+remove reactions ['limit']
Does not delete any messages, instead removes reactions posted to all messages within the range.
This command is slow because it scans each message individually instead of purging them all at once.

"Try using +remove finebros instead, it works the same, but is funner~!"
=remove system ['limit']
Deletes any system messages such as "Message Pinned" notifications.

+giverole [Server Admin]

"manages my role distribution system"

There are currently 5 types of roles that 42 can handle:

  • Givemes
  • Colourmes
  • Giveyous
  • Voice Bindings
  • Welcome Roles
Giverole is just the command that is used to set up roles for these features.

Server admins cannot use this command to elevate their own role. This means that if they couldn't normally assign a role, then they cannot create a giveme for it.

The bot requires Manage Roles and can only interract with roles that are lower in the hierarchy than her own.

Note: Giverole only registers roles. It does not create them. You will need to create your roles before you can use them in giverole commands.


Givemes

Givemes are roles that user's are able to request.
Each giveme has a name that users can use (which may be different to the role name) and can also have a set of optional restrictions.

+giverole giveme command 'name' 'role'
Creates a giveme.
Name is the giveme name, role is the role to assign.
+giverole giveme delete 'name'
Removes a giveme.
Name is the name of the giveme to remove.

Restrictions

There are 3 kinds of restrictions you can apply to a giveme. A member must pass all 3 in order to give the role.

  • A user must have ALL Requirement roles.
  • A user must NOT have ANY Ignore roles.
  • A user must be on the server for longer than the Delay time.
+giverole giveme require 'name' 'role' Adds a required role.
Name is the giveme to add the requirement to, role is the role to require.

If a giveme requires the role it assigns, it becomes remove only.
+giverole giveme ignore 'name' 'role' Adds an ignored role.
Name is the giveme to add the ignore to, role is the role to ignore.

If a giveme ignores the role it assigns, it becomes apply only.
+giverole giveme delay 'name' 'time' Adds a delay time to the tag.
Name is the name of the giveme, time is one of Xd, Xw or Xm, where X is the number of days, weeks or months.

Example use case

Lets say you're setting up a server and need an NSFW role. This role should:

  • Make sure the user is a "Member"
  • Make sure the user is not a "Child"
  • Make sure the user is not "Muted"
  • Make sure the user has been on the server for 2 weeks

And if this sounds familliar, gee, I wonder why...

We need to run 5 commands.

+giverole giveme create nsfw "NSFW Access"
+giverole giveme require nsfw "Member"
+giverole giveme ignore nsfw "Child"
+giverole giveme ignore nsfw "Muted"
+giverole giveme delay nsfw 2w

Chaining create

You can create a giveme with all its restrictions in a single command. This is basically just string a bunch of commands together.

Here is what is happening:

+giverole giveme create nsfw "NSFW Access"
                 require      Member
                 ignore       Child
                 ignore       Muted
                 delay        2w

Here is what it looks like:

+giverole giveme create nsfw "NSFW Access" require Member ignore Child ignore Muted delay 2w
I have set +giveme nsfw to assign NSFW Access.
I have set +giveme nsfw to require users to have Member.
I have set +giveme nsfw to reject users with Child.
I have set +giveme nsfw to reject users with Muted.
I have set the delay period for this giveme to 14 days.

Colourmes

Colourmes are similar to givemes in how they work except instead of having a set of optional restrictions, a user can only have 1 colourme at a time.
This is because colourmes are designed for, well, colours.
When a user requests a role, the bot will remove any other colourme roles that user has.

+giverole colourme create 'name' 'role' ['name' 'role'...]
This creates a colourme.
Name is the name of a colourme, role is the role to assign.
This command accepts multiple name/role pairs to create multiple colourmes at the same time.
+giverole colourme delete 'name' ['name' ...] This deletes a colourme.
Name is the name of the colourme to delete.
Multiple names can be given to delete many colourmes at once.

Giveyous

Giveyous are a way of allowing your mods who don't have Manage Roles to still apply or remove roles from people.

+giverole giveyou create 'name' 'role' ['name' 'role'...]
This creates a giveyou.
Name is the name of a giveyou, role is the role to assign.
This command accepts multiple name/role pairs to create multiple giveyous at the same time.
+giverole giveyou delete 'name' ['name' ...] This deletes a giveyou.
Name is the name of the giveyou to delete.
Multiple names can be given to delete many giveyous at once.

Bound voice roles

Bound voice roles are roles that are given to users when they join a voice channel, and then removed when they leave the channel. This is useful for if you have a complimentary text channel for your voice channel.

Note: This will not affect admins. If admins want to give or take roles from themselves, they can do so themselves. Having roles granted or revoked that they may not want granted or revoked only serves as a pain for most moderators.

+giverole voice bind 'channel' 'role'
Binds a role to a channel. Each channel can only have 1 role.
Channel is the voice channel, role is the role to assign.
+giverole voice unbind 'channel'
Unbinds a channel's voice role.
Channel is the channel to unbind the voice role for.
+giverole voice persist 'channel'
Tells 42 to not remove a role from a user when they leave the channel.
Channel is the channel to not remove roles from.

Welcome roles

Here is where the roles 42 uses in her welcome command.

+giverole welcome ['role']
Gets or sets the welcome role.
Role is the role to set, if no role is given, it fetches the current welcome role.
+giverole welcome stop
Removes the welcome role.
+giverole bots ['role']
Gets or sets the welcome bot role.
Role is the role to set, if no role is given, it fetches the current welcome bot role.
+giverole bots stop
Removes the welcome bot role.

+giveme [No PM]

"lets you collect a preset role"

Givemes are set up with the giverole command.
To recieve a giveme, a user must meet 3 requirements, all of which are set by the server admins:

  1. A user must have all the requirement roles.
  2. A user must have none of the ignore roles.
  3. A user must have been on the server for longer than the delay time.
You can remove a giveme role by requesting the bot to add it again.

Usage:
+giveme 'name'
Assigns or removes a giveme role. Name is the name of the giveme.
+giveme list
Lists the available giveme roles as well as their requirements.

+colourme [No PM]

"gives you a preset colour"

Colourmes are set up with the giverole command.
This command is functionally identical to givemes with 2 differences.

  1. Colourmes cannot take requirements, ignores or delays.
  2. A user may only have one colourme at a time.
Requesting the colourme that you have already will remove the colour role you have.

Usage:
+colourme 'name'
Assigns or removes a colourme role. Name is the name of the colourme.
+colourme list
Lists the available colourme roles.
+colourme visualise
Shows the colourme colours in an image.

+giveyou [Server Mod]

"gives a role to another user"

Giveyous are set up with the giverole command.
This command allows mods who normally do not have permissions to assign roles to assign preset roles to users.
Assigning a giveyou to a member who already has the role will remove it.

Usage:
+giveyou 'member' 'name'
Assigns or removes a member. Member is who is affected, name is the giveyou name.
+giveyou list
Lists the available giveyous.

+welcome [Server Admin]

"welcomes new users"

This command lets you send messages and assign roles to new users as they join the server.
There are two main features here. Sending messages and assigning roles.

Welcome messages

There are 3 parts to sending a message. The content, the destination and the delay.

  • Message: This is what to send.
  • Destination: This is where to send it.
  • Delay: This is when to send it.
Message Types

This is what message should be sent. It is also how you completely disable messages.

  • none This turns off sending welcome messages.
  • basic This sends a simple welcome message.
  • hug This sends a more friendly message.
  • tag This tells 42 to use your custom message.

Welcome tags are set up using the +tag command
They also allow for almost all yna to be used. The exceptions are:

  • {me} and {meid} are unavailable. To get the owner of the server, use {server.owner.name}
  • {args} are unavailable. {arglen} is always 0.
  • {mentionlen} is always 1, and {mention1} is the new user.
  • {uses} returns the number of members on the server.
  • {user} and {@user} are shortcuts for the new user's name and mention.
+welcome message 'type'
Sets the welcome message. Type is the type from the list above.
Destinations

This is where the message should be sent. Any combination of message type and destination works.

  • here This sends the message to where the +welcome command was performed.
  • owner This DMs the owner.
  • new This DMs the new user.
  • message This sends the message to the channel the user is in.

A note about the message type. This only works when you have set the delay to typing or message.

+welcome dest 'type'
Sets a message's destination. Type is the type from the list above.
Delayed posting

This says whether 42 should wait to post a welcome message or not. By default this is set to instant.

  • instant This sends the message as soon as the member joins.*
  • typing This wait until the new member starts typing.**
  • message This waits until the new member sends a message.

*Does not work when the destination is message.

**Most bots do not send typing, so this generally wont work for bots.

+welcome delay 'type'
Sets a message's delay. Type is the type from the list above.
Responding to bots

By default, new member messages will be triggered by bots however, this can be disabled.

+welcome bots listen
Tells 42 to respond when bots join.
+welcome bots ignore
Tells 42 to not respond when bots join.
Combined setup command

You may think needing to do 3 commands to set up welcome messages is a lot. (I know this because a lot of people have complained about it already...)
42 has a function that allows you to set up all 3 main steps of the welcome message at once.

+welcome setup 'message' 'dest' 'delay'
Equivalent to running all 3 commands seperately. Message, dest and delay are types from those commands.

Example usages
Greeting channel/quarentine:
+welcome setup basic here instant
Unintrusive:
+welcome setup hug message typing


New member roles

These are roles assigned to the new member as soon as they join. There is also a specific set of roles that will only be assigned to bots.

Welcome role

This is the role assigned to all new members.

  • none This disables the new member role.
  • new This creates a new role for the member.*
  • newcol This creates a role and sets it to a random** colour.*
  • giverole This gives the user the role defined with giverole

*Due to Discord's 250 role limit, this is absolutely not suitable for large or public servers

**The colour is based on a users ID. The algorithm is here

+welcome role 'type'
Sets what role to grant when a member joins. Type is from the list above.
+welcome role giverole 'rolename' A shortcut command to set and use a role via giverole.
Bots role

This is a role assigned only to bots.
It is assigned using +giverole bots

This can be triggered instead of, or in conjunction with the user role.

  • [none] This disables the bot role, instead only assigning the regular user role.
  • [only] This prevents bots from getting the user role, only giving them the bot role.
  • [both] This assigns both roles.
+welcome botrole 'type'
Sets which role(s) to grant to bots. Type is from the list above.

+modlog [Server Manager]

"tracks events in your server"

While yes it is true that audit logs have just been released and that they completely outshine the modlog, it still exists.
The largest setback in the audit log is that logs are only kept for 90 days.
The modlog exists as a kind of pseudo-audit log. It can't see who does something, but it can track when things are done.
... Well... It actually handles more than the audit log.

The bot requires Manage Channels as it can create a new channel if required.

Usage:
+modlog
Creates a new channel with a default topic and assigns it as the modlog.
+modlog here
Moves the modlog into the channel the command is called in. The topic will remain unchanged.
+modlog stop
Stops posting to the modlog. The channel will not be deleted.

The channel topic:

All the configuration for the modlog is done inside the channel topic by setting different variables, for example member_join = true
If you have other bots in the channel that use the topic for config, you can start the line with "42" 42 member_join = true
Whitespaces are optional and you can use as many as you want     member_join=  true

member_join When a member joins the server.


member_leave When a member leaves (or is kicked) from the server.


member_stats Shows the member count when a member joins and the leave score when they leave.


member_ban When a member is banned. (Responsible mod will be unknown)


member_unban When a member is unbanned.


name_changed When a member changes their username.

nick_changed When a member changes their nickname.

message_delete When a message is deleted.


show_content Displays the content of the message.


show_bots Shows messages by bots.


exclude_bulk_delete Ignore when several messages are deleted in quick succession.


bulk_delay_timer [int] How long to wait for bulk deletes (2 - 10)


max_shown_messages [int] Max messages to show individually (<= delay)


deleted_before Only show messages deleted before a number of seconds has passed.


deleted_after Only show messages deleted after a number of seconds has passed.


message_edit When a message is edited.


show_old_content Shows content before the edit.


show_new_content Shows content after the edit (req. before)


min_edit_distance [int] The minimum required change to post (> 0).


hours_offset [int] The offset in the timestamp on messages (-12 - 12)

channel_update When a channel is edited.


channel_list_update When a channel is created or deleted.


server_update When the server is edited.


permission_edited When a role is edited.


permission_assigned When a role is assigned or removed.


permission_saved When roles are stored via rolestate

command_called When a 42 command is called.


show_full_command Shows all args of a command


bot_channels [ID list] A comma seperated list of channel IDs. Channels in this list will be ignored when the bot is used.


show_failed_calls Show failed command calls and explain what happened.

log_all Turns on all logging. Individual features can be disabled.


allow_reports Allows use of the report command.


+report [Active Modlog Reports]

"sends a message to the modlog"

Permission: [Active Modlog Reports] This command requires both a modlog to exist and said modlog to have allow_reports = true.
This command simply sends a non-anonymous report message to the modlog.
The command call is instantly deleted to protect the people who make reports.
This command can be used to send tips off to the moderators of the server if they aren't accepting PMs.

Usage:
+report 'message' Message is the message to send.

+log [Active Modlog Mod]

"sends a message to the modlog"

Permission: [Active Modlog Mod] This command requires both a modlog to exist and the caller to have any permission based auth level.
This command sends a non-anonymous log message to the modlog.
The command call is instantly deleted because when squas was updating +report he accidentally hit this command first instead.
This command can be used to add reasons as to why certain things happened, like members being banned or roles being updated.

Usage:
+log 'message' Message is the message to send.

+blacklist [Server Mod]

"this controls my automoderation function"

This command checks for specific words and when someone sends a message containing one of said words, the message is deleted.
Messages sent by Server Mods or any higher powers will not be hit by the blacklist.

This command takes direct interraction with the server modlog and can actually start tracking infractions, and when they hit a limit, actions can be taken.

bl tracking Enables tracking of blacklist infractions.


bl show_all Shows the full content of the message.


bl warn_after [int] Take action after n deletes. 0 = off.


bl timeout [int] Days until a warning expires. 0 = never.


bl action [str] One of either 'message', 'ban' or 'kick'


bl message [str] Message to send when warning limit is hit.


bl alert_channel [ID] Alternate channel to send warning limit messages.


bl ignore [ID list] Comma seperated list of channels that ignore the blacklist.


Usage:
+blacklist add 'term'
Adds a new term to the blacklist. Teem is what to add.
+blacklist remove
Removes an item from the blacklist. This command is semi-interractive.
+blacklist list
Lists all the words on the blacklist.

+spamlimit [Bot Admin]

"makes me size limit my commands"

This command sets the bot such that outside of any preset channels, she will ensure that the amount she posts doesn't exceed a certain limit.
This line counting is applied to all messages, but the blocking affect is only applied to command calls.
This function does not affect Bot Mods and by proxy, Server Mods. This is so as to not block access to vital moderation tools like +cleanup. However the output will still be counted.

Due to how lines are counted (number of newline characters in the content + 1), message that consist solely of embeds are only counted as one line no matter how big.
Because every message adds to the line count, messages alerting users they have reached the spamlimit are counted towards the spamlimit

To use the spamlimit function, you must assign at least one bot channel.

Usage:
+spamlimit channels '#channel' [...]
Changes the defined bot channels. #channel is the mention of the channel to use. You can use multiple mentions.
This automatically starts tracking spamlimit with the default limits of 10 lines every 30 seconds.

+spamlimit limit 'lines' ['cooldown']
Sets the maximum number of lines the bot can send. Lines is the number of lines before stopping, cooldown is the seconds for those lines to ware off, if omitted, the value is unchanged.
+spamlimit stop
Stops counting lines.

+rolestate [Server Admin]

"saves a persons roles when they leave the server"

Rolestate is a simple feature but in my opinion, one of the strongest ones.
When a member leaves the server, 42 remembers what roles they had.
When they return, 42 returns those roles to them.

She will refuse to save any roles that are above her in the hierarchy, so this will not work if a mod leaves.

This is best coupled with givemes as it will reduce the number of times users need to call commands.
Especially more useful for timed roles as members who leave do not need to wait again for the timer unless they want to remove the role.

Usage:
+rolestate
Enables the rolestate. The bot will ask for confirmation.
+rolestate stop
Disables the rolestate. The bot will ask for confirmation.
This will delete all associated data.
+rolestate addrole 'userid' 'role'
Adds a rolestate. Userid is the ID of the user to affect, Role is the role that will be applied when the user joins.
This is useful for when a user tries to leave before you rolemute/ban them.
+rolestate delrole 'userid' 'role'
Removes a rolestate for a user. Userid is the ID of the user to affect, role is the role to remove.
+rolestate setnick 'userid' 'nick'
Adds a saved nickname. Userid is the ID of the user to affect. Nick is the nick to apply to them when they join.
+rolestate setnick 'userid' none
Removes a saved nickname. Userid is the user to affect.
+rolestate deluser 'userid'
Deletes all rolestate data for a user. Userid is the ID of the user to delete.

+warning [No DM]

"manages your server warnings"

This is a very simple feature that just keeps tracks of how many warnings a user has recieved.
The bot however does not take any moderator actions. She can however track when warnings expire.

You may have noticed how this command doesn't have a stated authority level. This is because users can also use this command. When a non-staff member uses this command, the bot will ignore whatever they requested and only DM them their current warnings on that server.
Users will be able to see when a warning was made, what its reason is and if it has been marked as Void, Perma or Expired.
Staff will see all this information as well as each warning's ID and notes. The ID is required to edit individual warnings.

Usage:

As a user, you can access

+warning
DMs you your warnings for this server

As a moderator, you can access

+warning search 'user'
Shows a user's warnings.
+warning add 'user' ['reason' ['note']] [perma]
Adds a new warning. User is who to apply it to.
Warnings will be shown to the user. Notes will be kept private.
If Perma is marked, the warning will never expire.
+warning edit 'id' ['reason' ['note']] [perma]
Edits an existing warning. ID is found in the search
+warning void 'id'
Voids a warning. ID is the warning to void. This ignores Perma warnings.
+warning voiduser 'user'
Voids all warnings for a user. User is whos warnings to void.

As an admin, you can access

+warning setexpire 'days'
Sets the number of days before a warning should be marked as expired.
+warning del 'id'
Deletes a warning. ID is the warning to delete.
+warning deluser 'user'
Deletes all warnings for a user. User is whos warnings to delete.
+warning export
Exports all the server's warnings into a csv file.
+warning delall
Deletes all warnings from the server


Return to top.