https://github.com/eternalclan/clannotifyer
A Discord bot for Livestream and upload notifycations.
https://github.com/eternalclan/clannotifyer
bot discord discordjs eternalclan javascript nodejs notifications sqlite3
Last synced: 4 months ago
JSON representation
A Discord bot for Livestream and upload notifycations.
- Host: GitHub
- URL: https://github.com/eternalclan/clannotifyer
- Owner: EternalClan
- License: mit
- Created: 2024-09-10T20:44:52.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-27T12:50:41.000Z (almost 2 years ago)
- Last Synced: 2025-03-11T07:15:57.637Z (over 1 year ago)
- Topics: bot, discord, discordjs, eternalclan, javascript, nodejs, notifications, sqlite3
- Language: JavaScript
- Homepage:
- Size: 271 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ClanNotifyer
[](https://discord.gg/cFyC9pmanj)
[](https://github.com/feross/standard)
[](LICENSE)
[](releases)
[](https://github.com/EternalClan/ClanNotifyer/actions)
[](https://github.com/EternalClan/ClanNotifyer/graphs/commit-activity)
🤖 **A simple, customizable Discord bot that announces Twitch streams (plus a bunch of silly extras).**
## Features
- 📢 Monitor and announce Twitch channels going live with customizable `@mentions`.
- 🔴 Live stream card that is automatically updated with the stream status, current game and viewership statistics.
## Installation and setup
### Prerequisites
This bot is built on Node.js. If you do not yet have Node installed, download and install the latest LTS version from the official website for your platform:
[Nodejs.org/downloads/](https://nodejs.org/en/download/)
> [!IMPORTANT]
> **Node.js, version 18 or higher is required.**
### Installation
To set up ClanNotifyer, download the latest [Release](https://github.com/EternalClan/ClanNotifyer/releases) or clone it using `git`:
git clone git@github.com:TamaniWolf/ClanNotifyer.git
Once downloaded, extract it from the zip file if needed and enter the directory to install the dependencies:
cd ClanNotifyer
npm install -global pnpm pm2
pnpm update
### Configuration
To configure ClanNotifyer, rename the included `#.env` to `.env`. It should look like this in there:
```.env
// For Settings in .env use (process.env.)
TOKEN =
PREFIX = cn.
SHARDED = false
BOTLANG = en_US
// Twitch
TWITCH_CLIENT_ID =
TWITCH_CLIENT_SECRET =
```
### Getting required tokens
#### Discord bot application
Your Discord bot needs to be registered as an application, and you will need a bot token (`TOKEN` in ClanNotifyer's .env).
Follow [this guide](https://github.com/reactiflux/discord-irc/wiki/Creating-a-discord-bot-&-getting-a-token) to create your own Bot User/Application.
#### Twitch Token
With the bot doing the Token creation itself we only need to provide it with Twitch's Client ID and Client Secret.
To get both we need to register our own application.
1. Open [Twitch's Developers Console](https://dev.twitch.tv/console/apps) and click on `Register Your Application`.
2. Enter the name of your application.
3. Under `OAuth Redirect URLs` enter `https://localhost`.
4. Select a Category and Client type, i recommend `Confidential`.
5. Fillout the captcha and click create.
Now click on Manage and copy the Client ID in to the bots .env file.
To get the Client Secret click on New Secret and also copy this to the .env file.
### Starting ClanNotifyer
Once the application has been configured, start it using `node` from the installation directory:
node .
Or with the proccess Manager `pm2`.
For the first time:
pm2 start main.js --name "Name" --max-memory-restart 250M
After adding to pm2 you can start it with the process number or the name:
pm2 start 1
pm2 start Name
### Inviting ClanNotifyer
Send the following link to the admin of a Discord server to let them invite the Bot:
`https://discordapp.com/oauth2/authorize?client_id=BOT_CLIENT_ID&scope=bot&permissions=962341628992`
Swap `BOT_CLIENT_ID` in the URL above for your Discord app's client id, which you can find in the app details.