Requirements
Minecraft Server:
- Spigot or Paper 1.8 to 1.21
- Vault (
Download)
- Permissions plugin that works with Vault (LuckPerms)
Discord Server:
- A discord bot with appropriate permissions
- Bot Token
Setup
Discord Bot:
1. Create a bot at [
Discord Developer Portal]
2. Enable Server Members Intent (Bot → Privileged Gateway Intents)
3. Invite the bot with OAuth2 scopes `bot` and `applications.commands`, plus permissions: `Manage Roles`, `Send Messages`
4. Place the bot's role above the roles you want it to assign
5. Create the Discord roles you need (e.g. Admin, Moderator, VIP, Member)
6. Get each role's ID: Enable Developer Mode (Settings → App Settings → Advanced → Developer Mode), then right-click a role in Server Settings → Roles and click "Copy ID"
7. Edit `discord-bot/config.json`:
- Set `discordToken` to your bot token
- Set `roleMapping` to map Minecraft groups to Discord **role IDs** (not names)
Minecraft Plugin:
1. Download and copy to your server's plugins folder.
2. Install Vault and your permissions plugin (if not already installed)
3. Edit `plugins/MinecraftSync/config.yml`:
- Set `api-url` to where your Discord bot is running
(e.g. `
http://your-server-ip:3000`)
- If the bot runs on the same machine as Minecraft: `
http://localhost:3000`
Usage
1. Player runs /sync in Minecraft
2. Plugin fetches their primary group via Vault (from LuckPerms, etc.)
3. Player receives a 6-digit code in game.
4. Player runs /sync code in Discord.
5. Bot assigns the corresponding Discord role.
Role Mapping
The role mapping in the discord bot `config.json` maps the Minecraft group names (lowercase) to Discord Role IDs.