A simple ready to use Discord Bot Template using slash commands and buttons!
View Demo
·
Report Bug
·
Request Feature
A simple Discord Bot Template build with the Color-Chan.Discord library. This template includes basic commands including a help command with multiple pages using buttons. Plus a simple MongoDB connection.
- Basic commands
- Persistent command request logging
- Command usage metrics
- MongoDB connection
To get a local copy up and running follow these simple steps.
See the Create reposotiry from a template guide for a more detailed explanation.
- Navigate to the main page of the repository.
- Above the file list, click
Use this template
. - Enter the name for your new repository and choose a visibility option.
- Click the
Create repositoiry from template
button.
- Clone the repo
git clone https://github.com/BrammyS/Discord-Bot-Template.git
- Go to the git folder
cd Discord-Bot-Template
- Run the local dev build
dotnet build
To run the Bot you will need to set 2 environment variables first.
BOT_TOKEN
: Add your bot token as the value. The bot token van be found here.MONGO_CON_STRING
: Add your MongoDB connection string as the value. You can get a free MongoDB host on MongoDB Atlas.
After this you need to set the PublicKey
and the BotId
for your bot. These can be set in the Constants.cs class in Bot.Discord.
Set the interaction end point for your bot. You will need to add this URL to you application.
The interaction endpoint is located at https://YOUR_DOMAIN.COM:5001/api/v1/discord/interaction
. Please do keep in mind that you will need to be able to access this endpoint from outside of your network.
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.