A Discord bot that automatically posts daily progress updates at 9 PM IST and mentions the @Moderator role. The bot also sends a startup message when it comes online.
- π Startup Message: Sends a test message mentioning @Moderator role when the bot starts
- β° Daily Updates: Automatically posts progress updates at 9:00 PM IST every day
- π IST Timezone: All times are in Indian Standard Time (IST)
- π’ Role Mentions: Mentions the configured role (default: @Moderator) in all messages
- π οΈ Admin Commands: Includes commands to check status and test updates
- π Node.js: Built with Discord.js for reliable performance
- Node.js 16.9.0 or higher
- npm (comes with Node.js)
- A Discord account
- A Discord server where you have permission to add bots
- Go to Discord Developer Portal
- Click "New Application" and give it a name
- Go to the "Bot" section in the left sidebar
- Click "Add Bot" and confirm
- Under the "Token" section, click "Copy" to copy your bot token
- Under "Privileged Gateway Intents", enable:
- β MESSAGE CONTENT INTENT
- β SERVER MEMBERS INTENT
- β PRESENCE INTENT
- In the Developer Portal, go to "OAuth2" β "URL Generator"
- Select the following scopes:
- β
bot
- β
- Select the following bot permissions:
- β Send Messages
- β Read Messages/View Channels
- β Mention Everyone (to mention roles)
- Copy the generated URL and open it in your browser
- Select your server and authorize the bot
- Enable Developer Mode in Discord:
- Settings β Advanced β Developer Mode (turn ON)
- Right-click on the channel where you want the bot to post
- Click "Copy ID" to get the channel ID
Open PowerShell in the bot directory and run:
npm installThis will install:
discord.js- Discord API librarydotenv- Environment variable managementnode-cron- Task scheduler for daily updates
Edit the .env file and add your configuration:
BOT_TOKEN=YOUR_DISCORD_BOT_TOKEN_HERE
CHANNEL_ID=YOUR_CHANNEL_ID_HERE
GEMINI_CHANNEL_ID=YOUR_AI_CHAT_CHANNEL_ID_HERE
ROLE_NAME=Basher
OPENAI_API_KEY=YOUR_OPENROUTER_API_KEY_HERE- BOT_TOKEN: Your Discord bot token from the Developer Portal
- CHANNEL_ID: The ID of the channel where daily updates should be posted
- GEMINI_CHANNEL_ID: The ID of the channel for AI chat interactions
- ROLE_NAME: The name of the role to mention (default: "Basher")
- OPENAI_API_KEY: Your OpenRouter API key (get from https://openrouter.ai/keys)
Note: Never share or commit your actual bot token to GitHub!
npm startOr for development with auto-restart:
npm run devThe bot will:
- Connect to Discord
- Send a startup message in the configured channel
- Schedule daily updates at 9 PM IST
- !status - Check bot status and time until next update
- !testupdate - Manually trigger an update message (Admin only)
@Moderator π€ Bot has started successfully!
Status: Online and ready
Time: 2025-11-12 09:30:45 PM IST
Daily Updates: Scheduled at 9:00 PM IST
@Moderator π Daily Progress Update
Date: November 12, 2025
Time: 2025-11-12 09:00:00 PM IST
Status: All systems operational
Next Update: Tomorrow at 9:00 PM IST
- Make sure the role name in
config.jsonexactly matches the role name in Discord (case-sensitive) - Ensure the bot has permission to mention roles
- Check that the bot has "Send Messages" permission in the channel
- Verify the channel ID is correct
- Make sure you've installed all dependencies:
npm install - Check that your bot token is correct in
.env - Ensure you have Node.js 16.9.0 or higher installed:
node --version
- The bot uses IST (Indian Standard Time)
- Make sure the bot stays running continuously
- Check console output for any errors
- Make sure all changes are committed to GitHub
- Push to your repository: https://github.com/Lethinkj/BeeLert
- Go to https://render.com/
- Click "New +" β "Web Service"
- Connect your GitHub account and select your repository
- Configure the service:
- Name: BeeLert (or your choice)
- Region: Choose closest to you
- Branch: main
- Runtime: Node
- Build Command:
npm install - Start Command:
npm start - Instance Type: Free
In Render dashboard, go to "Environment" tab and add:
BOT_TOKEN=your_discord_bot_token_here
CHANNEL_ID=your_main_channel_id_here
GEMINI_CHANNEL_ID=your_ai_chat_channel_id_here
ROLE_NAME=Basher
OPENAI_API_KEY=your_openrouter_api_key_here
PORT=3000
Important: Use your actual values from .env file, not these placeholders!
- Click "Create Web Service"
- Wait for deployment to complete
- Check logs for "Bot is ready at" message
Your bot's health check will be at: https://your-app-name.onrender.com/health
- Send messages in the AI chat channel (ID: 1438921892101886022)
- Bot responds using GPT-4o-mini via OpenRouter
- Messages auto-delete after 24 hours
!study <minutes>- Start a study session!studystatus- Check current session!endstudy- End session early
!status- Check bot status!help- Show available commands!testupdate- Test daily update (admin only)
- The bot must stay running to send daily updates
- All times are in IST (Indian Standard Time)
- Health check API runs on port 3000 (required for Render)
- Startup message is disabled to reduce spam
If you encounter any issues:
- Check Render logs for error messages
- Verify all environment variables are set correctly
- Make sure the bot has proper permissions in your Discord server
- Check OpenRouter credits at https://openrouter.ai/credits
This bot is provided as-is for educational and personal use.