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

# Whitelist System

> Manage trusted users and roles to prevent false antinuke triggers

## Overview

The Whitelist system allows you to designate trusted users and roles who are exempt from antinuke protections. This prevents false positives when legitimate administrators or bots perform actions that might otherwise trigger antinuke punishments.

<Info>
  Whitelisted users and roles can perform protected actions without being punished by the antinuke system.
</Info>

***

## Access Control

Only the following can manage the whitelist:

* **Server Owner** — Full access to all whitelist features
* **Extra Owners** — Users added by the server owner
* **Antinuke Admins** — Users designated by the server owner

***

## Commands

<AccordionGroup>
  <Accordion title="whitelist add" icon="plus">
    Add a user or role to the antinuke whitelist to exempt them from protections.

    <CodeGroup>
      ```bash Syntax theme={null}
      ~whitelist add <user/role>
      ```

      ```bash Example theme={null}
      ~whitelist add @moderator
      ~whitelist add @Admin Role
      ~wl add @trusteduser
      ```
    </CodeGroup>

    **Aliases:** `wl add`\
    **Permissions:** Server Owner or Antinuke Admin

    <Tip>
      Always whitelist your trusted staff members and essential bots to avoid accidental punishments.
    </Tip>
  </Accordion>

  <Accordion title="whitelist remove" icon="minus">
    Remove a user or role from the antinuke whitelist.

    <CodeGroup>
      ```bash Syntax theme={null}
      ~whitelist remove <user/role>
      ```

      ```bash Example theme={null}
      ~whitelist remove @exstaff
      ~whitelist remove @Former Admin Role
      ~wl remove @user
      ```
    </CodeGroup>

    **Aliases:** `wl remove`\
    **Permissions:** Server Owner or Antinuke Admin
  </Accordion>

  <Accordion title="whitelist list" icon="list">
    View all whitelisted users and roles for your server.

    <CodeGroup>
      ```bash Syntax theme={null}
      ~whitelist list
      ```

      ```bash Example theme={null}
      ~whitelist list
      ~wl list
      ```
    </CodeGroup>

    **Aliases:** `wl list`
    **Permissions:** Server Owner or Antinuke Admin

    <Note>
      The list displays both individual users and roles that have been whitelisted.
    </Note>
  </Accordion>

  <Accordion title="whitelist check" icon="magnifying-glass">
    Check if a specific user or role is whitelisted.

    <CodeGroup>
      ```bash Syntax theme={null}
      ~whitelist check <user/role>
      ```

      ```bash Example theme={null}
      ~whitelist check @user
      ~whitelist check @Moderator Role
      ~wl check @member
      ```
    </CodeGroup>

    **Aliases:** `wl check`\
    **Permissions:** Server Owner or Antinuke Admin

    <Info>
      When checking a user, the command will also show if they're whitelisted through any roles they have.
    </Info>
  </Accordion>

  <Accordion title="whitelist clear" icon="trash">
    Clear the entire antinuke whitelist (both users and roles).

    <Warning>
      This will remove ALL whitelisted users and roles. Use with caution!
    </Warning>

    <CodeGroup>
      ```bash Syntax theme={null}
      ~whitelist clear
      ```

      ```bash Example theme={null}
      ~whitelist clear
      ~wl clear
      ```
    </CodeGroup>

    **Aliases:** `wl clear`
    **Permissions:** Server Owner or Antinuke Admin
  </Accordion>
</AccordionGroup>

***

## How Whitelisting Works

The whitelist system operates on two levels:

<Tabs>
  <Tab title="User Whitelist">
    Individual users can be added to the whitelist by their user ID. When a user is whitelisted:

    * They can perform any antinuke-protected actions
    * They bypass all antinuke checks
    * Their whitelist status is independent of their roles
  </Tab>

  <Tab title="Role Whitelist">
    Entire roles can be whitelisted. When a role is whitelisted:

    * Anyone with that role is automatically whitelisted
    * Multiple roles can be whitelisted
    * Users inherit whitelist status from all their whitelisted roles
  </Tab>
</Tabs>

***

## Whitelist Hierarchy

The whitelist system checks permissions in the following order:

1. **Server Owner** — Always bypasses antinuke (cannot be removed)
2. **Whitelisted Users** — Individually added users
3. **Whitelisted Roles** — Users with whitelisted roles
4. **Non-whitelisted** — Subject to all antinuke protections

<Note>
  The server owner is inherently trusted and doesn't need to be added to the whitelist.
</Note>

***

## Aliases

The whitelist command has several convenient aliases for faster usage:

<CardGroup cols={3}>
  <Card title="wl" icon="w">
    Main alias
  </Card>

  <Card title="wl add" icon="plus">
    Quick add
  </Card>

  <Card title="wl remove" icon="minus">
    Quick remove
  </Card>

  <Card title="wl list" icon="list">
    Quick list
  </Card>

  <Card title="wl check" icon="magnifying-glass">
    Quick check
  </Card>

  <Card title="wl clear" icon="trash">
    Quick clear
  </Card>
</CardGroup>

***

## Best Practices

<Steps>
  <Step title="Whitelist Essential Staff">
    Add all trusted administrators and moderators to prevent false triggers during legitimate moderation actions.

    ```bash theme={null}
    ~whitelist add @Administrator Role
    ~whitelist add @Moderator Role
    ```
  </Step>

  <Step title="Whitelist Essential Bots">
    Add legitimate bots that need elevated permissions (like music bots or utility bots).

    ```bash theme={null}
    ~whitelist add @Music Bot
    ~whitelist add @Utility Bot
    ```
  </Step>

  <Step title="Regular Audits">
    Periodically review your whitelist to ensure only trusted users and roles remain.

    ```bash theme={null}
    ~whitelist list
    ```
  </Step>

  <Step title="Remove When Necessary">
    Remove users or roles when they're no longer trusted or leave the staff team.

    ```bash theme={null}
    ~whitelist remove @former-staff
    ```
  </Step>
</Steps>

***

## Common Use Cases

<AccordionGroup>
  <Accordion title="Whitelisting Administrative Roles" icon="user-shield">
    ```bash theme={null}
    ~whitelist add @Administrator
    ~whitelist add @Server Manager
    ~whitelist add @Head Moderator
    ```

    This ensures your administrative team can perform server management tasks without triggering antinuke protections.
  </Accordion>

  <Accordion title="Whitelisting Essential Bots" icon="robot">
    ```bash theme={null}
    ~whitelist add @Mimu
    ~whitelist add @Dyno
    ~whitelist add @Custom Bot
    ```

    Legitimate bots that manage roles, channels, or server settings should be whitelisted.
  </Accordion>

  <Accordion title="Checking Whitelist Status" icon="clipboard-check">
    ```bash theme={null}
    ~whitelist check @staff-member
    ~whitelist check @Admin Role
    ```

    Verify if a user or role is protected before they perform sensitive actions.
  </Accordion>

  <Accordion title="Cleaning Up the Whitelist" icon="broom">
    ```bash theme={null}
    ~whitelist list
    ~whitelist remove @inactive-user
    ~whitelist remove @deprecated-role
    ```

    Regular maintenance keeps your whitelist secure and up-to-date.
  </Accordion>
</AccordionGroup>

***

## Important Notes

<Warning>
  **Security Considerations**

  * Only whitelist users you completely trust
  * Whitelisted users can bypass ALL antinuke protections
  * Compromised whitelisted accounts can cause significant damage
  * Review your whitelist regularly, especially after staff changes
</Warning>

<Info>
  **Role-Based Whitelisting**

  When you whitelist a role, all members with that role are automatically trusted. This is more efficient than adding users individually but requires careful role management.
</Info>

<Tip>
  **Quick Access**

  Use short aliases like `wl add`, `wl remove`, and `wl check` for faster whitelist management during active moderation sessions.
</Tip>

***

## Troubleshooting

<AccordionGroup>
  <Accordion title="User still getting punished despite being whitelisted" icon="circle-exclamation">
    **Possible causes:**

    * User was added after the action was detected
    * Wrong user was whitelisted
    * Cache needs to refresh (wait a moment and try again)

    **Solution:** Verify the user is correctly whitelisted with `~whitelist check @user`
  </Accordion>

  <Accordion title="Can't add user or role to whitelist" icon="ban">
    **Possible causes:**

    * You don't have permission (need Server Owner or Antinuke Admin)
    * User/role doesn't exist or was deleted
    * Invalid mention or ID

    **Solution:** Ensure you're using proper mentions and have the required permissions
  </Accordion>

  <Accordion title="Whitelist appears empty but users are whitelisted" icon="ghost">
    **Possible causes:**

    * Database error
    * Whitelist was recently cleared

    **Solution:** Re-add trusted users and roles, then verify with `~whitelist list`
  </Accordion>
</AccordionGroup>
