Skip to the content.

🧹 Automated Purge System

The Purge System is a powerful maintenance tool designed to keep your Discord server’s roles and nicknames in perfect sync with the game. It periodically audits all registered users and ensures they only have the permissions they currently deserve.

⚙️ How it Works

The bot runs a background cycle (every few hours, as configured by the bot owner) that performs the following steps for every registered user:

  1. API Audit: The bot queries the Albion Online API to check the user’s current Guild and Alliance.
  2. Whitelist Comparison: It compares this data against your server’s /albion_guild and /albion_alliance whitelists.
  3. Action Determination:
    • Level 1: Update: If the user moved from one whitelisted guild to another, the bot updates their roles and nickname tags immediately.
    • Level 2: Purge: If the user is no longer in any whitelisted entity, the bot triggers a purge based on your configured Purge Mode.

[!TIP] Role Priority: During updates, the bot respects your Role Conflict Mode setting. If a user is in both a whitelisted guild and alliance, the bot will filter roles based on your priority (Additive, Guild Only, or Alliance Only).


🌓 Purge Modes

You can choose how aggressive the cleanup should be using /albion_setup config.

1. Full Purge (Mode: 1)

This is the “Zero Tolerance” mode. If a user is not in a whitelisted guild/alliance, the bot assumes they should no longer have access to your private areas.

2. Soft Purge (Mode: 2)

This mode is designed for large community servers or alliances that allow “Guest” or “Public” members to stay, but only want to give special roles to active members.


📝 Logging & Reporting

If you configure a purge_log_channel, the bot provides full transparency into its automated actions.

Action Logs

As the bot processes users, it sends real-time updates:

Cycle Report

At the end of every audit cycle, the bot sends a summary embed:


💡 Examples & Use Cases

Scenario A: The Competitive Guild

Goal: Only current members should see the guild channels.

Scenario B: The Community Hub

Goal: Everyone can chat in #general, but only members get access to #war-room.


[!CAUTION] Permissions: For the purge system to work, the Bot’s role must be higher in the Discord settings than all the roles it is trying to manage. It also needs the Manage Nicknames permission.