SimpleD2M is a lightweight Python program that lets you verify players Discord name against their Minecraft Username.
!fabcord - Players run this command in the Discord server. They are sent a DM from the bot asking for their Minecraft Username
!sync_verified - A command to help fix data errors, it will show players who are known to fabcord but don't have a UUID linked.
Visit localhost:5000 - you will see the management console to verify players who have interacted with the bot. Here you can also remove their verification
- Go to https://discord.com/developers/applications and create a new application.
- Give it a name (This will be the bots username in your server)
- Under the bots menu on the left, generate a token. Store this somewhere safe
- Still under bot settings, enable the message content intent
- Under the installation setting, copy the install link and paste it in to a new browser window
- Follow the steps to invite the bot in to your Discord Server.
- Create a new role in your server called Verified, make sure this is above the roll for the bot.
- Right click your Discord server on the server list on the left of Discord and Copy Server ID, this is your GUILD_ID. Keep this handy, as you will need it in Step 4 of the Server Deploy instructions.
This has been tested in Ubuntu Sever, config may be different on other flavours of Linux
-
Clone the repo. git clone https://github.com/A29-Dev/SimpleD2M cd fabcord
-
Auto setup Run
./setupto set up Python environment (Linux only), or follow the below steps to setup manually. ./setup expects python3 and pip are installed. This is a bug, checks will be made in a future release -
Create and activate virtual environment
python3 -m venv venvsource venv/bin/activate -
Make main.py excecutable
chmod +x main.py -
Install dependencies
pip install -r requirements.txt -
(First time only) Run the bot to generate config.json python3 main.py Enter your bot token and guild ID when prompted
- Create systemd service sudo nano /etc/systemd/system/fabcord.service
[Unit]
Description=FabCord Discord Bot
After=network.target
[Service]
Type=simple
User=ubuntu
WorkingDirectory=/home/ubuntu/fabcord
ExecStart=/home/ubuntu/fabcord/venv/bin/python3 /home/ubuntu/fabcord/main.py
Restart=always
RestartSec=5
[Install]
WantedBy=multi-user.target
-
Enable and start the service
sudo systemctl daemon-reexecsudo systemctl daemon-reloadsudo systemctl enable fabcordsudo systemctl start fabcord -
Monitor logs (optional)
journalctl -u fabcord -f
