Test. This is a Discord bot that tracks invitations for your server. You can view the leaderboard to see which members have invited the most people, reset a member's invitation count, and more.
- Node.js +16.x.x
- MySQL Server
- Discord bot token
- Clone the repository:
$ git clone https://github.com/enes-th/discord-invite-tracker.git
- Install the dependencies:
$ cd discord-invite-tracker
$ npm install
- Configure the
'.env'
file with these informations:
# Discord Bot Info
TOKEN=
# MySQL Server Info
HOST=
PORT= # default 3306
USER=
PASSWORD=
DATABASE=
- Configure the
'config.ts'
file with these informations:
export default {
message: {
footer: "Powered by Enes"
},
activity: {
name: "Sene Bot",
type: 3 // 0 = Playing, 1 = Streaming, 2 = Listening, 3 = Watching, 4 = Custom, 5 = Competing
},
handleError: false // If there an error, display it in the message
}
- Start the bot:
$ tsc
$ cd dist
$ node index
Make sure to manually import the .env file into the dist folder
Run the /setup
command on discord
- Track invites of each server member
- View the invite leaderboard
- Add or remove invites from members
- Reset a member's invites to 0
- Detection of fake invitations
/invites [@member]
- View invitations/add-invites <@member> <amount>
- Add invitations/remove-invites <@member> <amount>
- Remove invitations/leaderboard
- View the invite leaderboard/reset-invites <@member>
- Reset a member's invites to 0/setup <#welcome-channel> <#leave-channel> <#log-channel>
- Setup the invitation system/create-link
- Create an invitation link that never expires/who-used-code <code>
- See which users have used this code
Contributions are always welcome! If you have any suggestions or find any bugs, feel free to open an issue or create a pull request.
Please make sure that your changes pass the ESLint and Prettier checks.
This project is licensed under the MIT License - see the LICENSE.md file for details.