Skip to content

florianGierlichs/discord-bot

Repository files navigation

Lean-Coffee-Discord-Bot

alt text

This is a simple discord bot to send email notifications about creating, updating and deleting lean-coffee events.

Slash Commands

The bot provides the following slash commands:

  • /ping replies with pong, an absolute must have for every serious bot
  • /server replies with server name and member count
  • /user replies with user tag, id and name
  • /lean-coffee replies with the upcoming lean-coffee event

Email Events

The main purpose of the bot is to send an email to a list of recipients about creation, updates or canceling of a lean-coffee event.

The bot will only react to events which happen in a channel called lean-coffee.

Tech Stack

Usage

To use the bot, you need to

  • create a new application on the discord developer portal
  • add a bot inside that application
  • create a MongoDB
  • generate an OAuth URL to link the bot to your discord server
    • make sure to activate applications.commands and bot in the OAuth URL Generator OAuth URL Generator
  • add an .env file somewhere on your machine with the following credentials:
BOT_TOKEN=XXX
CLIENT_ID=XXX
GUILD_ID=XXX
CHANNEL_ID=XXX

MAIL_HOST=XXX
MAIL_USER=XXX
MAIL_PASS=XXX

DB_CONNECTION=XXX
  • the mails get send via nodemailer, so make sure to add the correct mail-host for your provider
  • you have two options to make the bot run:
    • clone the repo and run the app on your local node
    git clone git@github.com:florianGierlichs/discord-bot.git
    cd discord-bot
    npm i
    npm run deploy-commands && npm start
    
    docker run --env-file ./.env floriangierlichs/lean-coffee-discord-bot
    
    make sure to add the correct path to your local .env file!

That`s it!

The bot should run and replie to your slash commands and lean-coffee events.

Feel free to clone the repo and extend the bot to your needs.

If you have any questions, you can open an issue on this repo.

License

MIT

Happy Coding 😘

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages