Configuring your bot - Olevenbaum/Discord-Bot-Template GitHub Wiki
configuration.json
This template is designed to work by just making changes to the configuration.json file.
This file is not included in the repository, because all the critical data as the bot token are stored there as well, which you do not want to publish. It has to be added manually. When creating this file, make sure to include all of the required properties down below:
Note:
All properties are explained in the next two paragraphs only. If you want to see some examples of the properties or even a complete configuration.json file, head to this page.
Required properties
applications
| Optional | no |
| Type | object or array |
| Default | - |
In the applications property you want to provide at least one or even multiple sets of bot data. If there is only one bot you want to add, you can set this property to an object including the three properties listed down below. If you have multiple bots you want to manage with this template, use an array including one object with the properties listed down below for each of them.
Required properties of every bot object:
applicationId: your bots application IDpublic key: your bots public keytoken: your bots token
All of the properties can be obtained from the Discord Developers website
Important: We cannot be held responsible for your data! Keep your token secure, as anyone with access to it will have full control over your bot. If you suspect that your token has been compromised, change it immediately on the Discord Developers Website.
Optional properties
To further configure this template to make it fit your bot (or bots) best, you can add the following optional properties to the configuration.json file:
enableApplicationIteration
| Optional | yes |
| Type | boolean |
| Default | false |
This property states whether you want to log in on any cost when starting the application. When enabled, the application will try to log in the next bot when one login process fails. Read the page on providing multiple bots for more detailed information.
enableBlockedUsers
| Optional | yes |
| Type | boolean |
| Default | false |
If there are users who you do not want to interact with your bot (anymore), this property allows you to use the blockedUsers.json file in the resources directory.
Read the page on blocked users for more detailed information.
enableBotInteraction
| Optional | yes |
| Type | boolean |
| Default | false |
This option allows you to decide whether other bots can use features of your bot application.
notifications
| Optional | yes |
| Type | object or boolean |
| Default | false |
The template allows users to get notifications about specific events of your bot. Notifications are sent to the bots owner or the whole team if it is owned by a team on Discord. For more detailed information read the page on notifications