Custom Commands

Your own slash commands and right-click commands on users and messages, with options, permissions, cooldowns, forms, buttons and menus with their own actions, 31 actions, requirements, variables, 26 templates, a test mode and a log of every use.

Custom Commands lets you create your own Discord commands without writing code. Each command can ask for options, check who uses it and where, and run actions in order: reply, send messages with buttons and menus that have their own actions, open a form, give roles, moderate, update counters and much more.

There are three kinds of command:

KindHow it's used
Slash commandTyping / in the chat, like /8ball. It can ask for options: text, numbers, yes/no, users, channels, roles or files.
User commandNot typed: right-click a member (on a phone, tap their profile) › Apps › the command. Its actions run on that member, like Show avatar.
Message commandNot typed: right-click a message (on a phone, long-press it) › Apps › the command. Its actions run on that message: reply to it, react, pin, copy or delete it, like Report message.

Note

Looking for rules that react to what happens in the server (a member joins, a message contains a word…)? That's Automations. Custom Commands is for things members start themselves.

Quick start

  1. Open Custom Commands and click New command, or pick a template like Magic 8-ball.
  2. Choose Slash command, write a name like hello and a description.
  3. In What it does, add Reply visibly and write Hi {user}!.
  4. Click Save command. A few seconds later, type /hello in your server.

If the command doesn't show up, restart Discord (Ctrl+R).

Templates

GroupTemplates
FunMagic 8-ball (/8ball), Coin flip (/coinflip), Dice roll (/roll), Hug (/hug @user), Rate anything (/rate).
InformationShow avatar and User info (right-click a user), Server info (/serverinfo), Rules (/rules), Useful links (/links, with link buttons), FAQ (/faq with a list of topics).
UtilityIdeas box (/idea), Report message (right-click a message: asks for a reason and copies it to a staff channel), Report user (right-click a user), Bookmark (sends you the message by DM), Quote, 10-minute timer (/timer), AFK (/afk adds or removes [AFK] in your nickname).
CommunityStaff application (/apply: a form, then a staff post with Accept and Deny buttons), Verification panel (/verify-panel), Self-roles menu (/roles-panel).
ModerationWarn (/warn @user reason), Clean bot messages (/cleanup).
Economy and progressDaily reward (/reward), Reputation (/rep @user), My points (/points).

Every part of a template can be changed. When a template needs something from you (a channel, a role, a link), the missing parts are marked in amber.

Your commands

The list shows each command with its kind and whether it's on, with search, folders and filters (On, Off, With problems, and by kind). From each one you can edit, duplicate, copy its export code, turn it on or off or delete it. Each change is saved on its own, so several people can edit different commands at the same time, and the Change history shows who created, edited or deleted each one.

Export copies a code (starting with DOTBOT-CMD:) and Import pastes it in this or any other server. A single command opens in the editor so you can pick that server's channels and roles.

You can have up to 40 custom commands per server.

The command

SettingWhat it does
Command nameSlash commands: lowercase letters, numbers, - and _ (max 32). Right-click commands: the text shown in the Apps menu, with spaces and capitals. It can't be the name of a DotBot command or of a slash command created with Automations.
DescriptionShown under a slash command in Discord (max 100 characters).
FolderGroups commands in the list.

Options (slash commands)

Up to 25 options, each with a name, a description and a type: Text, Whole number, Number, Yes / no, User, Channel, Role, User or role or File. Options can be required, and depending on the type they can have:

  • a minimum and maximum value (numbers) or length (text);
  • only some kinds of channel (text, voice, category, announcement, stage, forum, thread);
  • fixed values (up to 25 per option) that people pick from a list.

Use them in messages as {option.name}. A user option can also be who the actions apply to (for example /warn @user), and a file option gives its link, so {option.file} can be shown as an image.

Who and where

Everything here is optional.

SettingWhat it does
Permission neededEveryone, or only members with a permission (Manage Messages, Manage Nicknames, Manage Threads, Timeout Members, Mute Members, Move Members, Kick, Ban, Manage Roles, Manage Channels, Manage Events, Manage Server) or administrators. Members without it don't see the command.
Only in age-restricted channelsDiscord only shows it in age-restricted channels.
Only these roles / Never these rolesWho can use it. Members with a denied role can't, even if they also have an allowed one.
Only in these channels / Never in these channelsWhere it can be used. A category includes all its channels and their threads.
More requirementsUp to 20 requirements (see below), all or any of them, each one can be inverted with NOT.
Message when it can't be usedPrivate reply for the roles, channels and requirements above. Supports variables.

Requirements

GroupRequirements
WhereIn specific channels or categories, Within a schedule (hours and days in a time zone; can cross midnight).
WhoHas any of these roles, Has none of these roles, Is a specific user, Account age, Time in the server, Boosts the server.
Text and messageText contains, Contains the exact word, Starts with, Matches a pattern (regex), Has a link, Has a Discord invite, Longer than. In slash commands the text is what was typed in the text options; in message commands it's the message. Message commands can also check Mentions someone, Has attachments, Is a reply, Isn't a reply and Shorter than.
OtherRandom chance, Variable (compares any variable, like {option.amount}, {target_id} or {counter:points}, with a value; numbers compare as numbers).

Cooldown

The time members wait between uses (up to 7 days), for each user, each channel or the whole server. Roles in Roles without cooldown never wait, and you can write your own Message during the cooldown with {time} (for example "in 2 hours"). Cooldowns survive restarts.

What it does

Up to 20 actions per command, run in order, plus up to 10 inside each If… / Otherwise… branch and up to 5 for each button and menu option (100 in total).

GroupActions
MessagesReply privately, Reply visibly, Reply to the message (message commands), Send a message to a channel (the same one or another), Send a direct message (to whoever used the command or another member, such as the user in an option), Edit the message, Copy the message to another channel, Start a thread or post, Add a reaction, Pin the message, Publish the message (announcement channels), Delete the message.
MembersGive roles (optionally temporary, up to 30 days), Remove roles, Give or remove roles (toggle), Change the nickname, Move to a voice channel, Disconnect from voice, Give XP (Levels), Give coins (Economy & Shop), Remove roles from everyone (up to 500 members each time). Roles with powerful permissions (like Administrator, Manage Server, Manage Roles, Kick or Ban Members) can't be given or removed by custom commands.
ModerationTime out (1 minute to 28 days), Warn (added to their Moderation record), Kick, Ban, Delete recent messages (up to 100: all, only from people, only from bots or only from one member).
ChannelsLock the channel, Unlock the channel, Set slow mode.
Counters and integrationsUpdate a counter (add, subtract, set or reset, for the member or the server), Send a webhook (to Zapier, Make, n8n, a Discord webhook or any URL).
FlowAsk with a form, If… / Otherwise… (check requirements at that point and run different actions), Wait (up to 15 minutes, survives restarts), Stop.

Actions on members apply to whoever used the command, the user in one of its options, or the user you right-clicked (in message commands, the message's author).

Messages

A message can be plain text or a colored box with a large image and a thumbnail (links, or variables like {target_avatar}). Add up to 20 alternative texts and DotBot picks one at random each time, which is great for answers and jokes. A message sent to a channel can be deleted automatically after some seconds.

Buttons and menus

A message can have up to 5 buttons and one menu with up to 25 options. Link buttons open a URL; the others run their own actions when clicked (up to 5 each), like Accept giving a role to whoever applied. Each button and menu can be limited to whoever used the command or to some roles, and a menu can let people pick several options at once (each one runs its actions).

Inside a button or menu, actions can apply to whoever clicked, whoever used the command, or the command's target user, and Edit the message can change the message with the button (for example to show who answered and remove the buttons).

Forms

Ask with a form opens a pop-up with up to 5 questions (short or long answers, required or not, with a minimum and maximum length). It has to be the first action of the command or of a button (Discord doesn't allow forms in menus). The answers are available in the next actions as {answer.key}.

Counters

Counters are numbers kept per member or for the whole server. They're shared with Automations: the same name uses the same counter. Show them with {counter:name} (the member's), {target_counter:name} (the target user's), {server_counter:name} or {counter_top:name} (a top 10), and compare them with the Variable requirement.

Variables

Variables work in messages, nicknames, thread names, reasons, form texts (title, labels and hints) and webhook texts. The editor lists the ones available in each place.

VariablesValue
{user}, {user_name}, {user_id}, {user_avatar}, {user_created}, {user_joined}Who used the command (in buttons and menus, who clicked).
{author}, {author_name}, {author_id}In buttons and menus: who used the command.
{target}, {target_name}, {target_username}, {target_id}, {target_avatar}The user you right-clicked, the message's author, or the first user picked in a slash command's options.
{content}, {message_link}The message you right-clicked (in slash commands, {content} is the text typed in the options).
{option.name}, {answer.key}, {selected}Options, form answers and the menu options picked.
{channel}, {server}, {member_count}, {server_boosts}, {command}Where it was used, the server and the command's name.
{random:a|b|c}, {countdown:2026-12-25}One option at random; time left until a date (UTC).
{counter:name}, {target_counter:name}, {server_counter:name}, {counter_top:name}Counters: the member's, the target user's, the server's and a top 10.

Test, activity and health

  • Test: checks whether you could use the command and shows how its messages would look, with example values for the options, the target and the form. Nothing is sent or changed.
  • Activity: the last 50 uses of each command (kept for 30 days), with who used it, where, from what (the command, a button or a menu) and every action's result: ✓ done, – skipped (nothing to do) or ✗ failed with the reason. Recent activity shows the latest uses of all commands.
  • Health: tells you when DotBot can't do everything a command asks: a missing permission, a deleted channel or role, a role above DotBot's or one with powerful permissions, a module that's off, or a command Discord couldn't register (the server is full of commands of that kind, or the name is taken).

A member can use commands up to 10 times in 10 seconds, each command up to 60 times a minute, and a server up to 120 uses a minute and 10,000 a day. If an action fails and nothing else answered, the member gets a private notice saying so.

Limits

LimitValue
Commands per server40 (Discord also allows only 5 user commands and 5 message commands per server, and all of them are yours: DotBot doesn't add right-click commands of its own)
Options25 per command, 25 fixed values each
Requirements20
Actions20 (10 per branch, 5 per button or menu option, 100 in total)
Buttons / menu options per message5 / 25
Form questions5
Alternative texts20
Cooldownup to 7 days
Wait15 minutes
Temporary rolesup to 30 days
Time out1 minute to 28 days
Delete recent messages100 per use, not older than 14 days

Permissions DotBot needs

Each action needs its matching permission: View Channel and Send Messages to send, Manage Messages to delete or publish, Pin Messages to pin, Add Reactions, Create Public Threads, Manage Roles (with DotBot's role above the roles), Manage Nicknames, Timeout Members, Kick Members, Ban Members, Move Members, and Manage Channels to lock channels or set slow mode. Read Message History is needed to delete recent messages.

FAQ

Why doesn't my command show up in Discord?

Discord updates commands a few seconds after saving; restart Discord (Ctrl+R) if it still doesn't appear. If the command has a Health warning, Discord couldn't register it: a server can have up to 100 slash commands (counting DotBot's own and the ones from Automations), 5 user commands and 5 message commands.

Why can't I use my command?

Check Who and where: a permission, roles, channels or requirements may block you, or a cooldown may be running. Activity shows each use with Not allowed or On cooldown, and Test tells you what blocked it.

How do I make a button that gives a role?

Add Reply visibly (or Send a message to a channel), add a button and, in When clicked…, add Give roles. The Verification panel template does exactly that, and Self-roles menu does the same with a menu.

Can a command ask several questions?

Yes. Make Ask with a form the first action and add up to 5 questions. Use the answers in the next actions as {answer.key}, like the Staff application and Report message templates.

What's the difference with Automations?

Automations react to what happens in the server (messages, members joining, level ups…) and can also create simple slash commands. Custom Commands are made for commands: more options with fixed values, right-click commands, forms, permissions, and buttons and menus with their own actions inside the same command. Counters are shared between both.