[go: up one dir, main page]

Automatically kick unverified members

Configuration

  • Verification role
  • Max time allowed without verifying
  • Feature flag

Behavior

Run a cron job every 1 hour to check every guild's member cache that has this feature enabled.

Store a list of member per guild that meet the following criteria:

  • Not a bot
  • Not a staff member
  • Not subject to another sanction that allows them to remain on the server (mute, detention, exile)
  • Doesn't have the verification role
  • Has been a member for longer than the max time

Loop over each guilds list of candidates to kick, and perform the following:

  • Send them a DM telling they were kicked and why
  • Kick the member
  • Wait 2 seconds between loop iterations for notifications to be sent

It would be nice to send a rollup notification of how many members have been kicked every day, but that would likely require storing the action in the database, since querying the audit log for large guilds would probably be expensive.

Errors should be reported to the dev guild with each guild loop iteration though. Include a tally of how many failed to be sent a DM, or if any kicks failed.

Edited by erin