> ## Documentation Index
> Fetch the complete documentation index at: https://docs.zeonbot.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Betrayal Guard

> Protect your server against rogue admins and compromised whitelisted users.

The **Betrayal Guard** is an advanced, high-speed defense mechanism designed to protect your server from **rogue administrators** and **compromised whitelisted accounts**. While the standard Antinuke ignores whitelisted users, Betrayal Guard places strict limits on them.

<Warning>
  **Premium Feature:** Betrayal Guard is exclusively available for servers with an active ZEON Premium subscription.
</Warning>

<Note>
  **Required Permission:** `is_server_owner` — Only the Server Owner or Extra Owners can manage Betrayal Guard settings, ensuring maximum security.
</Note>

***

## How It Works

Even if a user is explicitly whitelisted in the Antinuke system, Betrayal Guard tracks their actions silently using lightning-fast cache limits. If a whitelisted user exceeds a defined action limit (e.g., banning 8 people in a minute), Betrayal Guard will instantly:

1. **Ban the user** from the server.
2. **Remove them from the whitelist**, permanently revoking their trusted status.
3. **Send a detailed webhook log** to the designated Antinuke logging channel.

***

## Setting Limits

Betrayal Guard works by tracking two timeframes for every protected action:

* **Minute Limit:** Maximum actions allowed within 60 seconds (default: 8).
* **Hour Limit:** Maximum actions allowed within 3600 seconds (default: 40).

You can easily configure custom limits for any Antinuke event (like `ban`, `kick`, `role_delete`, `channel_delete`, etc.) using the interactive configuration command.

| Command                           | Description                                                                            |
| :-------------------------------- | :------------------------------------------------------------------------------------- |
| `.antinuke betrayalguard enable`  | Turns the Betrayal Guard system on.                                                    |
| `.antinuke betrayalguard disable` | Turns the Betrayal Guard system off.                                                   |
| `.antinuke limit`                 | Opens an interactive menu to set Minute and Hour limits for specific security filters. |

<Tip>
  Betrayal Guard operates independently for every action type. A user can create 4 channels and delete 4 roles without triggering an 8-action limit. It strictly watches velocity per action type.
</Tip>
