All Projects → Michael-J-Scofield → discord-anti-spam

Michael-J-Scofield / discord-anti-spam

Licence: MIT license
A simple discord anti spam node.js module to prevent spam on your discord server

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to discord-anti-spam

DraconianJSBot
With its robust performance, intuitive design, and vast array of functionalities, the Draconian Bot is the ultimate solution for all your needs.
Stars: ✭ 113 (-25.17%)
Mutual labels:  moderation, discord-js
mango
A @discord bot that has lots of features 🥭
Stars: ✭ 22 (-85.43%)
Mutual labels:  moderation, discord-js
zuly
🤖 | Hi, I'm zuly, a brazilian bot! Focused on animes!
Stars: ✭ 45 (-70.2%)
Mutual labels:  moderation, discord-js
hellsnakebot
🤖About A fully customizable bot built with discord.js
Stars: ✭ 14 (-90.73%)
Mutual labels:  moderation, discord-js
AntiScam-Bot
Discord bot written on discord.js, deletes messages with scam links.
Stars: ✭ 16 (-89.4%)
Mutual labels:  moderation, discord-js
Welcome-Bot
A cool multi-purpose discord bot that solves all your problems. I have features such as Moderation, ModLog, Welcome & Goodbye logs, Fun, Music
Stars: ✭ 73 (-51.66%)
Mutual labels:  moderation, discord-js
discord-js-bot
A cool multipurpose discord bot built using discord.js v13 with moderation, music, ticketing, translation, and much more
Stars: ✭ 135 (-10.6%)
Mutual labels:  moderation, discord-js
warnable
Simple Discord bot to moderate Discord servers, specifically to warn members.
Stars: ✭ 34 (-77.48%)
Mutual labels:  moderation, discord-js
v13-Discord-Bot
This is my V13 Discord Bot, it has around 95 commands, 17 events, and stores all kinds of data in an SQL database for ease of access. Not to mention a unique style and friendly help menu interface. Used by over 25 people in popular company based servers, this will bring you a professional look that tops your competition.
Stars: ✭ 38 (-74.83%)
Mutual labels:  moderation, discord-js
Hurricano
An amazing open-source Discord bot using MongoDB with many features such as a customizable prefix, a reaction menu, music, role requirement giveaways and much more!
Stars: ✭ 97 (-35.76%)
Mutual labels:  discord-js
CodeClaimer
A neat and faster Discord Gift Claimer.
Stars: ✭ 21 (-86.09%)
Mutual labels:  discord-js
multiple-purpose-discord-bot-like-carlbot
A MultiPurpose Discord bot Named Dumb Bot which does Almost Everything You will need in one bot and with 230+ Commands and does almost everything which is in carl-bot or dyno
Stars: ✭ 70 (-53.64%)
Mutual labels:  discord-js
discord-altyapi-bot
Discord Bot Altyapısı - Discord.js v14 Altyapı
Stars: ✭ 172 (+13.91%)
Mutual labels:  discord-js
Lagertha
A UI/UX redesign of the popular Twitch-bot PhantomBot
Stars: ✭ 10 (-93.38%)
Mutual labels:  moderation
Discord-Channel-Moderator
❤️ Discord Moderation Bot that helps you filter commands, (allow) links or filter words in channels where they were not allowed. Script is Node.js based using discord.js built by @Refloow
Stars: ✭ 76 (-49.67%)
Mutual labels:  discord-js
djs-games
A package for discord.js mini games which can be used in your bots
Stars: ✭ 41 (-72.85%)
Mutual labels:  discord-js
Discord-Trivia-Bot
TriviaBot: Play trivia in Discord! Powered by discord.js and OpenTDB, with 24 categories and three modes of play.
Stars: ✭ 83 (-45.03%)
Mutual labels:  discord-js
php-antispam
A PHP API for antispam service cleantalk.org. Invisible protection from spam, no captches, no puzzles, no animals and no math.
Stars: ✭ 50 (-66.89%)
Mutual labels:  spam-protection
Discord.JS-Music-Bot
A simple Discord.JS music bot using the DisTube npm Package!
Stars: ✭ 23 (-84.77%)
Mutual labels:  discord-js
SeoaBot
The Discord bot was name Seoa
Stars: ✭ 28 (-81.46%)
Mutual labels:  discord-js

discord-anti-spam.js

A simple module with quick setup and different options to implement anti-spam features in your bot.

Installation

To install this module type the following command in your console:

npm i discord-anti-spam

Documentation

You can see the package documentation here.

Example

Example of a basic bot handling spam messages using this module.

const { Client, GatewayIntentBits, Partial } = require("discord.js");
const client = new Client({
  intents: [GatewayIntentBits.Guilds, GatewayIntentBits.GuildMessages],
  partials: [Partials.Channel],
});
const AntiSpam = require("discord-anti-spam");
const antiSpam = new AntiSpam({
  warnThreshold: 3, // Amount of messages sent in a row that will cause a warning.
  muteTreshold: 6, // Amount of messages sent in a row that will cause a mute.
  kickTreshold: 9, // Amount of messages sent in a row that will cause a kick.
  banTreshold: 12, // Amount of messages sent in a row that will cause a ban.
  warnMessage: "Stop spamming!", // Message sent in the channel when a user is warned.
  muteMessage: "You have been muted for spamming!", // Message sent in the channel when a user is muted.
  kickMessage: "You have been kicked for spamming!", // Message sent in the channel when a user is kicked.
  banMessage: "You have been banned for spamming!", // Message sent in the channel when a user is banned.
  unMuteTime: 60, // Time in minutes before the user will be able to send messages again.
  verbose: true, // Whether or not to log every action in the console.
  removeMessages: true, // Whether or not to remove all messages sent by the user.
  ignoredPermissions: [PermissionFlagsBits.Administrator], // If the user has the following permissions, ignore him.
  // For more options, see the documentation:
});

client.on("ready", () => console.log(`Logged in as ${client.user.tag}.`));

client.on("messageCreate", (message) => antiSpam.message(message));

client.login("YOUR_SUPER_SECRET_TOKEN");

Support Server

Join our Support Server where we help you with issues regarding the module.

Bug Reports

If you have any bugs or trouble setting the module up, feel free to open an issue on Github

📝 License

Copyright © 2019 Michael-J-Scofield
This project is MIT licensed.


Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].