This is a Discord Bot that displays online users in your Minecraft Realm
The bot displays total online users in its bio, which updates every 60s.
The bot also lists online users and their usernames with the command
$online
in a chat visible to the bot.
This bot works in tandem with Minecraft Realms API Server running on the same machine
Follow the directions here and create your own discord app Save the Discord Token generated by your app.
This app uses default bot permissions and does not require administrator.
Invite the bot to your server.
Visit the other repository: Minecraft Realms API Server and setup and the server via the instructions
Run the following comamnds (Unix)
python3 -m venv .venv
to create a virtual environmentsource ./.venv/bin/activate
to enter the virtual environmentpip install -r requirements.txt
to install the necessary dependencies
- Create a new file called
.env
- Input your Discord Token, and the default port for Minecraft Realms API Server in the file as shown below:
DISCORD_TOKEN="your_discord_token_here"
API_LOCATION="http://127.0.0.1:5000"
Run python3 bot.py
to start the bot