siddvish21 / aternos-discord-bot

5 stars 1 forks source link

Aternos (Minecraft servers) Discord Bot

You can use this bot to start your minecraft server, get the server status, get the number of players online, and more. More Details : https://aternos.org/:en/

Getting Started

  1. Clone this repository to your local machine.
  2. Install the required libraries using pip install -r requirements.txt.
  3. Create a Discord bot and get the bot token from the Discord Developer Portal.
  4. Enable messages in privileged intents for your bot.
  5. Copy the .env.sample file and paste as .env to do modification.\
  6. Fill in your Aternos credentials in the env file in the ATERNOS_USERNAME and ATERNOS_PASSWORD fields
  7. Start the bot using python discord_bot.py.

First Start by creating an aternos account or login to an existing one

Then create a minecraft server for you

Next login to discord developer portal and then go to this link https://discord.com/developers/applications

Create a new application like this:

After that go and get the bot token as follows and paste it in the env file in the TOKEN variable

To invite the bot to your discord server you need to generate a url as follows in the gif

Paste the url in the webbrowser and select the discord server you want it to join and authorise it

After Authorisation it will look like this

After completing this setup u can use the discord bot by running the python file

This is the Demonstration of the bot starting the server

Usage

Commands

Notes

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

Acknowledgments

This project was inspired by the Python Aternos API Wrapper by Marceau Cuvelier.