Skip to content
This repository has been archived by the owner on Dec 1, 2021. It is now read-only.

Setting Up

Andrew Lalis edited this page Nov 13, 2021 · 2 revisions

To get set up so that you can contribute to the development of JavaBot2, please follow these instructions.

  1. Obtain a Discord bot token from the Discord Developer Portal. Make sure your bot has administrator privileges, and message reading intents. Invite the bot to your own testing server.

  2. Start the bot once. It will generate a javabot_config directory with a systems.json inside it. Edit this, and place your bot token into the appropriate location. Your config file should look something like this:

{
  "discordBotToken": "abc123",
  "mongoDatabaseUrl": "mongodb://root:example@localhost:27171",
  "asyncPoolSize": 4,
  "hikariConfig": {
    "jdbcUrl": "jdbc:h2:tcp://localhost:9123/./javabot",
    "maximumPoolSize": 5
  }
}
  1. Restart the bot, and it will start up and connect to the Discord API, and initialize a configuration file in javabot_config for each guild it's in. Edit the file that was generated for your guild, and fill in whatever values are required. Please consult the net.javadiscord.javabot2.config.guild package for more information about what the different options mean. After setting the appropriate configuration settings, it's recommended that you restart the bot once more to have the changes take effect.
Clone this wiki locally