Minecraft: Java Edition - Discord Whitelist Bot (API Version)
Run an invite-only community and want to give your community members access to a private Minecraft: Java Edition server?
This bot is exactly what you need to do just that!
Using this bot, Discord members can use the /whitelist
command inside Discord to whitelist their Minecraft account on your server.
Each member can only whitelist one account, and the bot will prevent two members whitelisting the same account.
This app supports all Vanilla, Spigot and Paper servers running most Minecraft versions. If you use a custom whitelist plugin, you might need to modify the code which checks if the account is already whitelisted.
This code is powered by Autocode's Minecraft API!
πΊ Demo

π Setup
Before installing this app, you'll need to ensure RCON is enabled on your Minecraft server. Follow this guide to learn how to do that!
Once you've enabled RCON you're ready to setup your bot!
- Install this app using the green
Install Free
button above.
- Choose your app's name, then click
Next
.
- Follow the instructions to link your Discord bot and Minecraft server to this app. If this is your first time connecting a Discord bot, you'll need to set one up. Then click
Continue
.
- Set the following environment variable:
Kv Prefix
- we use Autocode's key-value store to remember who has already whitelisted an account. If you're running multiple instances of this bot on the same account you should use a different KV prefix for each one. If you're only running one instance, we recommend using MC_WHITELIST
as your prefix.
- Click
Install App
and wait for Autocode to work it's magic
- Once your app is installed, head over to your Discord server and type
!registerwhitelistcommands
in a channel your bot has access to.
Congratulations! Your server should now have a /whitelist
command!
π€ FAQ
- I use a custom Minecraft whitelist plugin. Will this work for me?
- Yes, but you might need to change a small bit of code on
line 78
if your plugin changes the message sent to the console when the player is already whitelisted.
- Will this work for large Discord/Minecraft servers?
- Yes, but if you run a really big server then you'll likely want to rework this code to use something like a MySQL database to store your whitelisted player data.
- Can I modify/customise this code?