Add Anti-Spam Discord bot
Introduce a new Anti-Spam Discord bot project. Adds project metadata and scripts (package.json, .env.example, .gitignore, README, deploy-commands.js) and the full src implementation: command registration and handling, per-guild settings persistence, configuration parsing, spam detection logic (phishing URLs, suspicious TLDs, mass/role mentions, image+URL combos, new account heuristics), and the bot entrypoint (index.js) that enforces permissions, logs actions, and optionally bans offenders. README explains setup, required intents, and usage; per-server settings are stored under data/guild-settings.json. (package-lock.json added for dependency resolution.)
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
DISCORD_TOKEN=your_bot_token_here
|
||||
|
||||
# Application ID from Developer Portal → General Information (needed for deploy-commands)
|
||||
APPLICATION_ID=your_application_id_here
|
||||
|
||||
# Optional: deploy commands instantly to one server instead of waiting for global propagation
|
||||
DEPLOY_GUILD_ID=
|
||||
|
||||
# Global defaults applied to every server (use /antispam in each server for per-server settings)
|
||||
# Ban users when spam is detected (true/false)
|
||||
BAN_ON_SPAM=true
|
||||
|
||||
# Delete message before banning
|
||||
DELETE_MESSAGE=true
|
||||
|
||||
# Flag role mentions when the role has at least this many members
|
||||
MAX_ROLE_MENTION_SIZE=50
|
||||
|
||||
# Extra strict on accounts younger than this many days (0 = disabled)
|
||||
MIN_ACCOUNT_AGE_DAYS=0
|
||||
|
||||
# Comma-separated user IDs that bypass checks on all servers (e.g. bot owner)
|
||||
TRUSTED_USER_IDS=
|
||||
Reference in New Issue
Block a user