A Discord bot for use of GSS (Gildia Skrybów Staszka) written in Discord.js framework
-
Create a file called
.env -
Go to Discord Developer Portal
-
Create a bot by clicking
New Application -
In
General Informationtab copyAPPLICATION IDand fill in.envwithCLIENT_ID=<APPLICATION ID> -
In
Bottab copy theTOKENand fill in.envwithTOKEN=<TOKEN> -
In
OAuth2 -> URL Generatorcheck required accesses (probably just check all) and generate an url to invite the bot to your testing server -
Create a testing server in Discord and setup it to simulate GSS server (proper channels, roles, etc.)
-
Invite the bot using the link generated in step 6 and grant it an admin role
-
Get the ID of the server and fill in
.envwithGUILD_ID=<SERVER ID>. To get ID of the server:
To get the server ID for the first parameter, open Discord, go to Settings → Advanced and enable developer mode.
Then, right-click on the server title and select "Copy ID" to get the guild ID
- Run
node deploy-commands.jsif commands have changed - Run
npm startto start the bot
Deployment of the bot is currently being done manually by the owner with no plans to automate in near future - reach out to him if you want to work on automating it
- https://discordjs.guide/ - Very well written Discord.js documentation