Skip to content

Latest commit

 

History

History
30 lines (25 loc) · 1015 Bytes

File metadata and controls

30 lines (25 loc) · 1015 Bytes

ActivityBot

A Discord bot made for a friend that automatically manages 'Active' and 'Inactive' roles based on user message activity.

Features

  • Assigns 'Active' role to users who have sent a message in the last 7 days.
  • Assigns 'Inactive' role to users who have not sent a message in over 7 days.
  • Automatically switches roles when users become active/inactive.
  • Uses SQLite for persistent tracking of user activity.

Setup

  1. Create 'Active' and 'Inactive' roles in your Discord server.
  2. Invite the bot with permissions to manage roles and read messages.
  3. Copy your bot token from the Discord Developer Portal.
  4. Replace YOUR_BOT_TOKEN_HERE in index.js with your actual bot token.
  5. Run the bot:
    npm init -y
    npm install discord.js sqlite3
    node index.js

Requirements

  • Node.js
  • discord.js
  • sqlite3

Notes

  • The bot must have permission to manage roles and read messages in your server.
  • The check for inactive users runs every 12 hours by default.