-
Notifications
You must be signed in to change notification settings - Fork 8
Home
You will find here a step by step guide on how to setup the bot and use it.
The bot is made to be used in a linux server but as it is written in Python, you are able to use it on other OS.
If so, install_ubuntu.sh will not work and you'll have to adapt by yourself.
I recommand to install it on a server rather than on tour personnal machine so it can be active 24/7.
You can set a little server, no need for 18 core with 42GB RAM.
Here are some usefull guides for creating linux server :
Creating a virtual machine in GCP
Creating a server on AWS
You can follow this tutorial to create and add a bot to your Discord Server
You also need to give it some autorisation to get the members names and IDs.
Go to https://discord.com/developers/applications/ -> Select your bot -> got to the "Bot" page -> Enable Presence Intent and Server Members Intent
Open a terminal on your linux server and clone the code : git clone https://github.com/Shraknard/pyaxie-bot
The secret.yaml file contain all the configuration needed for the bot to interact with your scholars accounts.
The discord_token
field is for your discord bot token
The url_api
field is for Axie API. You have to find it by yourself as it is forbidden to make it public in Axie ToS.
The personal
part is for your informations. If you don't play the game you don't need to set-up a private key.
The scholars
part will contain a list of your scholar.
You'll have to copy paste the scholar1 block and fill the informations for every scholar of your scholarship.
It contains the following informations :
ronin_address
is the ronin address of the scholar account
private_key
is the private key of the scholar account
discord_id
is the discord id of the scholar (not username like : username#1234)
payout_percentage
is the amount that you give to your scholar. 0.6 is for 60%.
To install, all you need to do is chmod +x install_ubuntu.sh; sudo ./install_ubuntu.sh
If you get an error like "ImportError: No module named YOUR_MODULE_ERROR" try the command : pip3 install YOUR_MODULE_ERROR
(replace module_error by your value)
Once the script finished it's job, the bot should be working and be visible on your server (if you added it).
You can confirm by typing the command : ps -ef | grep pyaxie-bot.py
to see if the process is running.
If you only see the "grep" command then it's not up. You can see the nohup file on your folder containing all the output.
Or you can start the bot with python3 pyaxie-bot.py
to see the errors in real time.
Remember to use : nohup python3 ./pyaxie-bot.py &
when you finished.
nohup is starting the process in background so you can close the shell after that.
To stop the bot simply type : kill $(ps aux | grep 'pyaxie-bot.py' | awk '{print $2}')
And if you want to uninstall, just stop the bot + delete the pyaxie-bot folder.
Note : Commands must be sent in DM to the BOT OR in a Discord channel where the bot is enabled.
- A user that is not in the secret.yaml file, will not be able to use the bot.
- Talk in DM to the bot if you don't want people to see the result of the command.
- Go to the discord and try to find some help : https://discord.gg/gqaSv2PZbF