A cryptocurrency-styled bot that you can change to your liking for Minecraft servers (or any game/usage).
- Clone this repository (
git clone https://github.com/CantisW/discord-economy-bot
) - Open Visual Studio Code or similar and open a terminal
- Download PostgreSQL and set it up. Optionally, download a DB management service such as DBeaver.
- Put your username and password into
ormconfig.json.default
then rename it toormconfig.json
. Everything else is already set up. - Type in
npm i
and wait for dependencies to install - Type in
npm start
Enjoy! Make sure it is set up and you have node.js (v16.14.0
or higher).
Go to the Discord Developer Portal and make a bot.
Please make sure that when inviting the bot to your server, you tick bot
AND application.commands
else the bot will not work.
- Fairly simple to set up system
- Slash commands
- Simple economy commands
- Leaderboards and blockchain-like transaction logging
- Localization
- API support
All bot settings are located in src/data
.
bot.json
handles all bot-specific settings. Here is where you'll input your token and guild id.
'settings.json' handles the settings for your currency. Put in a name, max supply, etc.
To use the API, run the bot using npm run api
.
The default port is 3000
, but that can be changed in app.ts
.
Access the API using localhost:port
. localhost
can also be your own URL.
Don't forget to port forward!