Skip to content

Nexx4/discord-subscription-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Discord Subscription Bot

Go Latest Release

Table of Contents

About

This is an example Discord bot which can watch your server, check for certain ROLE updates and notify a user/channel if that role changes.

For example: Someone subscribed, gained a new role, and you want them to be notified.

Environment variables

Environment Description
APPLICATION_ID (OPTIONAL - NOT IN USE) Bot application Id
PUBLIC_KEY (OPTIONAL - NOT IN USE) Channel public key
BOT_TOKEN Insert your bot secret token here
SUBSCRIBED_ROLE_IDS List of ids(numbers) for the role you want to watch
NOTIFICATION_TYPE The target for the notification: either user or channel
NOTIFICATION_ID The target Id for the notification (user or channel)
GO_ENV "development/production"
GO_LOG_LEVEL "debug/info/warn/panic"

Quickstart

Using local environment

Setup: Downloads the linter and other go tools

task install-requirements

Run & build the application

task run

or

go run cmd/bot/bot.go