Skip to main content

Overview

Anti-Raid is a real-time protection system that monitors your server for abnormal join activity. When the join rate crosses the configured threshold within a rolling time window, Anti-Raid automatically triggers your configured mitigation actions — such as locking the server, kicking or banning joiners, deleting invites, or quarantining new members. Unlike Verdict Mode which targets internal threats, Anti-Raid is focused entirely on external attacks: coordinated bot raids, mass-join floods, and invite abuse. It is designed to act instantly and automatically without requiring manual intervention.
Actions like Auto-Ban and Lockdown affect all users who joined during the raid window — including potentially legitimate users. Configure your threshold carefully to avoid false positives.

How It Works

Every member join is tracked within a rolling time window. Once the number of joins reaches or exceeds the threshold within that window, Anti-Raid enters raid mode and executes all enabled actions against the detected joiners. Example: If the threshold is set to 5 with a 10s window, 5 members joining within 10 seconds will trigger raid mode immediately. After a raid is resolved, the server can be unlocked manually or automatically after a configurable delay. Raid tracking data is cleared on every bot restart to prevent stale data from causing false positives.

Access Control

The same access rules as Antinuke apply:
  • Server Owner — Full access to all Anti-Raid features
  • Extra Owner — Extra owners added by server owner
  • Antinuke Admins — Users designated by the server owner
Use antinukeadmin to manage who can configure Anti-Raid.

Commands

Opens the Anti-Raid interactive control panel to toggle actions and view current configuration. Requires the module to be enabled first.
,antiraid
Aliases: raidprotect
Permissions: Server Owner or Antinuke Admin
Enables the Anti-Raid module, unlocking the control panel and all subcommands. Does not automatically enable any mitigation actions — you must toggle them manually after enabling.
,antiraid on
Aliases: antiraid enable
Permissions: Server Owner or Antinuke Admin
Disables the Anti-Raid module entirely. All active protections and actions become inactive immediately.
,antiraid off
Aliases: antiraid disable
Permissions: Server Owner or Antinuke Admin
Set the join rate that triggers raid detection. Both the join count and time window must be provided. Cannot be used unless the module is enabled.
Both joins and seconds must be at least 5.
,antiraid threshold <joins> <seconds>
Permissions: Server Owner or Antinuke Admin
Set the minimum account age in days. Accounts younger than this value will be flagged and subject to configured actions during a raid.
,antiraid accountage <days>
Aliases: antiraid minage
Permissions: Server Owner or Antinuke Admin
Manually unlocks the server after a raid if auto-unlock has not yet triggered or is disabled.
,antiraid unlock
Permissions: Server Owner or Antinuke Admin
View the current Anti-Raid configuration including module status, threshold, account age filter, auto-unlock delay, and all enabled actions.
,antiraid config
Aliases: antiraid settings
Permissions: Server Owner or Antinuke Admin
View the current raid status and recent raid history, including join counts, kicks, bans, and whether lockdown is active.
,antiraid status
Permissions: Server Owner or Antinuke Admin

Mitigation Actions

When raid mode triggers, Anti-Raid executes all enabled actions simultaneously against users who joined during the detection window. Each action can be toggled independently from the control panel.

Delete Invites

Deletes all active server invites immediately when a raid is detected to cut off the attack vector

Lockdown

Revokes send message permissions across all channels, preventing raid members and the broader server from interacting

Auto-Kick

Automatically kicks all users who joined during the raid detection window

Auto-Ban

Permanently bans all users who joined during the raid detection window

Quarantine

Isolates joining users by stripping all roles and restricting permissions without kicking or banning

Threshold Configuration

SettingDescriptionMinimumDefault
JoinsNumber of joins required to trigger raid mode55
WindowTime in seconds joins are tracked within5s10s
Min Account AgeMinimum account age in days for joining members00
Auto-Unlock DelayMinutes before the server automatically unlocks after a raidConfigurable
For large, active servers with frequent legitimate join spikes (giveaways, announcements), raise both the join count and window to prevent accidental lockdowns.

Control Panel Interface

Running ,antiraid opens an interactive control panel built with Discord Components V2. The interface includes:
  • Real-time status display showing module state, configured threshold, and minimum account age
  • Individual toggle buttons for each mitigation action with live enabled/disabled indicators
  • Global controls:
    • Enable Module
    • Disable Module
    • Configure (threshold, account age, auto-unlock delay)
Only the user who ran the command can interact with the control panel. The panel becomes inactive after 2 minutes but remains visible.

Raid Status

The ,antiraid status command provides a live snapshot of raid activity: During an active raid:
  • Duration of the ongoing raid
  • Number of joins detected in the window
  • Running kick and ban counts
  • Whether lockdown is currently active
When no raid is active:
  • Confirmation the server is currently safe
  • Summary of the most recent raid (time elapsed, joins, kicks, bans)

Auto-Unlock

After a lockdown is triggered, the server can be unlocked in two ways:
  • Automatic — After the configured auto-unlock delay elapses, the bot restores channel permissions automatically
  • Manual — Run ,antiraid unlock at any time to immediately restore the server
If no auto-unlock delay is configured, the server will remain locked until you manually run ,antiraid unlock.

Difference from Verdict Mode

FeatureAnti-RaidVerdict Mode
Threat typeExternal (raids, floods)Internal (trusted users going rogue)
TriggerJoin rate thresholdDestructive action threshold
Whitelist bypassN/AYes — no exceptions
Configurable actionsYesAlways ban
Per-action time windowNoYes
Lockdown supportYesNo
Auto-unlockYesNo

Logging Integration

Every Anti-Raid action is automatically recorded in the Antinuke punishment log, including the trigger event, affected users, and actions taken.
All Anti-Raid actions are logged to your configured logging channel if enabled.

Best Practices

  • Enable Anti-Raid alongside Verdict Mode for layered protection — Anti-Raid handles external floods, Verdict Mode handles internal threats.
  • Start with the default threshold (5 joins in 10s) and raise it if your server regularly sees fast legitimate join spikes.
  • Enable Delete Invites as a baseline — it cuts off the raid source even if you don’t want auto-kick or auto-ban.
  • Set a minimum account age of at least 7 days to filter throwaway raid accounts.
  • Configure an auto-unlock delay so your server doesn’t stay locked indefinitely if you miss the notification.
  • Regularly review your config with ,antiraid config.
If you use Auto-Ban, any legitimate users who happened to join during the raid window will be permanently banned. Consider using Quarantine as a safer first action if false positives are a concern.