Skip to content

DarthJahus/MinecraftServerStatus-Discord

Repository files navigation

DiscordBot Donate

Discord

⚠️ This project has been discontinued. The bot has been shut down. Feel free to build upon the actual code.

MinecraftServerStatus-Discord

In a Discord embed, shows the status of a Minecraft server.

Usage

  • mc/link <server> [showUsers]

    Link your Minecraft Server to your Discord Guild. The status will be shown in the same channel where you have sent the command. <server>: The address of your Minecraft Server in the form sub.domain.ext or domain.ext. [showUsers]: Optional. True or False (default). Whether to show the list of connected players. Don't set to True on massive servers.

  • mc/unlink

    Stop receiving updates about the Minecraft Server and delete the status message.

Notes

  1. You need Administrator or Manage Guild permission in order to use this bot in your server.
  2. Only one Minecraft Server can be linked to a Discord Guild. Using mc/link again will overrite whatever settings you have previously applied.
  3. The bot has been made to minimize interactions and messages. By design, it will not message you if something is wrong (can't send message, can't reach the Minecraft Server, if you don't have the required permissions, etc.). If the status message is not updating, please make sure you have correctly used the mc/link command. Try again if you are unsure.
  4. In case something is going wrong, have found a bug or have you a suggestion to make, you might contact me on Discord (Jahus#9238) or Telegram.
  5. If the bot is useful, consider making a donation on Patreon.

Self-hosting

Prepare a channel for people to check your Minecraft Server status. Make it so only the bot can send messages there. Once the first status message is sent, the bot will update it every 5 minutes. Please, don't try to change the update time to less than 60 seconds; the API won't update its cache that fast.

Want to self-host the bot? Create a Discord Bot on the Discord Developer Dashboard. Once done, get your token and set it in the config.json file.

Config example

In a config.json file, store the following settings:

{
  "server_address": "server.address.ext",
  "discord_bot_token": "yoursuperSicretToken",
  "discord_channel_id": 0,
  "show_user_list": false
}
  • server_address: The address (or IP address) of your Minecraft server;
  • discord_bot_token: A token you'll get from Discord;
  • discord_channel_id: The ID of the channel in which the bot will show the server status (make sure the bot has the right to write and use embeds in that channel).
  • show_user_list: If true, shows a list of connected users (you might keep it false if you have many users who connect at the same time).

Running as a service

To run the bot at your server's startup, register the .service file with systemctl and enable it.

Minecraft Server Status

This bot uses the Minecraft Server Status API, that's completely free. If you appreciate their work, consider donating to them on PayPal.

About

In a Discord embed, shows the status of a Minecraft server.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published

Languages