diff --git a/.env.example b/.env.example index 06e1e5f..538c712 100644 --- a/.env.example +++ b/.env.example @@ -1,13 +1,13 @@ -# Defaults to https://api.revolt.chat/0.8 +# Defaults to https://api.stoat.chat/0.8 API_URL= -# Defaults to wss://app.revolt.chat/events +# Defaults to wss://events.stoat.chat WEBSOCKET_URL= # The bot's authentication token BOT_TOKEN="" -# The channel you wish for the bot to filter for only emoji messages +# The ID of the channel you wish for the bot to filter CHANNEL_ID="" # The bot's account ID diff --git a/README.md b/README.md index 9c02bed..8211148 100644 --- a/README.md +++ b/README.md @@ -8,13 +8,13 @@ [![Issues](https://img.shields.io/github/issues/DeclanChidlow/emoji-enforcer?style=flat-square&logoColor=white)](https://github.com/DeclanChidlow/emoji-enforcer/issues) [![Contributors](https://img.shields.io/github/contributors/DeclanChidlow/emoji-enforcer?style=flat-square&logoColor=white)](https://github.com/DeclanChidlow/emoji-enforcer/graphs/contributors) -A bot for Revolt that only allows users to send emojis. +A bot for Stoat that only allows users to send emojis.
This is a dead simple little bot written in JavaScript. It will only allow users to send messages containing emojis in a given channel. It also permits some white space and new lines for flexibility. -You can see it in action on the [Emoji Only Revolt server](https://rvlt.gg/Dm4F4ctA). +You can see it in action on the [Emoji Only Stoat server](https://stt.gg/Dm4F4ctA). ## Usage diff --git a/index.js b/index.js index 5a01e11..79cfcd1 100644 --- a/index.js +++ b/index.js @@ -5,8 +5,8 @@ const BOT_TOKEN = process.env.BOT_TOKEN; const CHANNEL_ID = process.env.CHANNEL_ID; const BOT_ID = process.env.BOT_ID; -const API_URL = process.env.API_URL || "https://api.revolt.chat/0.8"; -const WEBSOCKET_URL = process.env.WEBSOCKET_URL || "wss://app.revolt.chat/events"; +const API_URL = process.env.API_URL || "https://api.stoat.chat/0.8"; +const WEBSOCKET_URL = process.env.WEBSOCKET_URL || "wss://events.stoat.chat"; const patterns = { customEmoji: /:[\w-]+:/g, @@ -58,7 +58,7 @@ function createWebSocketConnection() { const ws = new WebSocket(WEBSOCKET_URL); ws.on("open", () => { - console.log("Connected to Revolt WebSocket"); + console.log("Connected to Stoat WebSocket"); ws.send( JSON.stringify({ type: "Authenticate",