A Discord bot using Discord.NET.
- Discord Bot Token
- Visit the Discord Developers Portal
- Log in with your Discord Username and Password
- Create a new Application, Name it your desired bot name.
- Once created, click Bot in the left navigation menu.
- Click add bot, and confirm with 'Yes, do it!'
- Once the bot has been created, click 'Click to Reveal Token'
- Save this token. >> DO NOT SHARE IT <<
- Rename
sampleappsettings.configtoappsettings.config. - Edit
appsettings.configand add your Discord bot token to it before running. - If you are running from the source code, this should be all you need to do besides running the solution in your IDE of choice.
Note: if you're running the project via Visual Studio, do the following to ensure your appsettings.config is output to the correct directory on runtime:
- Right click
appsettings.configand click Properties - In the properties section, set
Copy to Output DirectorytoCopy Always
If you are using the a release package, do the following:
- Unzip
linux-x64.zip - Run
chmod +x ./FischBotin thelinux-x64directory - Run
./FischBotto start the bot
Contributions are welcome! Please create a new branch for the item you are working on, and submit a pull request when it is ready.
The project is divided into a few main sections:
- APIs
- Services
- Modules
Modules are very similar to controllers if you've used an MVC framework before, and have methods for each of the bot's supported commands. Services methods are called by modules, and house the bot's application logic. APIs are called by services, and handle low-level logic like HTTP requests.
Some APIs the bot integrates with have their own Nuget packages to help integrate with the API. In these cases, instead of making a class in the Api folder, we use the classes from the API's Nuget package directly in the Services classes.