A comprehensive Discord bot designed to enhance community engagement with automated features, gamification, and educational content delivery.
- Daily Programming Questions - Browse 129 programming questions with difficulty levels and explanations
- Daily Terminology - Automated daily tech term posting to keep members learning
- Question Browsing - Paginated navigation through questions with
/dailyquestionscommand
- Points System - Members earn points through interactions and achievements
- Leaderboard - Real-time leaderboard showing top 10 performers with pagination
- Personal Statistics - Check your personal points and last activity with
/mypoints
- Member Synchronization - Automatic member data sync with Discord roles and metadata
- Welcome Messages - Personalized welcome messages for new members
- Birthday Announcements - Automated birthday announcements for community members
- Progress Updates - Track member progress and milestones
- Scheduled Reminders - Customizable reminders for important events
- Daily Posts - Automated posting of terminologies and questions at scheduled times
- Auto Synchronization - Periodic member data synchronization
- Channel Setup - Quick setup commands for bot channels and permissions
- Database Management - Integrated SQLite database for data persistence
- Slash Commands - Modern Discord slash commands for all functionality
- Permission Control - Role-based access control for commands
- Daily Terminology Poster - Posts a new terminology term every day at 8:00 PM
- Daily Question Updates - Tracks and cycles through programming questions
- Scheduled Reminders - Automatically sends reminders at configured times
- Member Sync - Automatically syncs member data when they join/leave
- Points Tracking - Tracks and updates member points automatically
- Leaderboard Updates - Real-time leaderboard calculations
- Message Handlers - Processes all member interactions
- Activity Logging - Logs all member activities for analytics
- State Management - Maintains synchronization state between Discord and database
| Command | Description | Usage |
|---|---|---|
/help |
Show all available commands | /help |
/leaderboard |
Display top 10 users with pagination | /leaderboard |
/mypoints |
Show your personal points and statistics | /mypoints |
/terminology |
Show today's tech terminology | /terminology |
/next |
Preview the next terminology | /next |
/prev |
Preview the previous terminology | /prev |
/dailyquestions |
Browse 129 programming questions | /dailyquestions |
BeliX/
├── index.js # Main bot entry point
├── package.json # Dependencies and metadata
├── README.md # This file
│
├── database/
│ ├── db.js # Database operations (SQLite)
│ ├── insertMembers.js # Member data insertion
│ └── schema.sql # Database schema
│
├── json/
│ ├── dailyQuestion.json # Daily coding questions
│ └── terminologies.json # Daily tech terminologies
│
├── features/
│ ├── birthdayAnnouncement.js # Birthday announcements
│ ├── channelSetup.js # Channel configuration
│ ├── dailyGatheringScheduler.js # Daily gathering coordination & tracking
│ ├── dailyQuestionPoster.js # Question posting automation
│ ├── dailyTerminology.js # Terminology management
│ ├── leaderboard.js # Leaderboard display logic
│ ├── memberSync.js # Member synchronization
│ ├── progressupdate.js # Progress updates
│ ├── scheduledReminders.js # Reminder scheduling
│ ├── slashCommands.js # Slash command handlers
│ └── welcome.js # Welcome messages
│
├── json/
│ ├── dailyQuestion.json # 129 programming questions (Days 1-129)
│ └── terminologies.json # Tech terminology database
│
├── prompts/
│ └── botInstructions.txt # Bot behavior guidelines
│
└── text/
└── [Various text assets] # Text resources
- Node.js (v16 or higher)
- Discord Bot Token
- SQLite3
-
Clone the repository
git clone <repository-url> cd BeliX
-
Install dependencies
npm install
-
Configure environment variables Create a
.envfile in the root directory:TOKEN=your_discord_bot_token GUILD_ID=your_guild_id DATABASE_URL=./database.db
-
Initialize the database
sqlite3 database.db < database/schema.sql -
Start the bot
node index.js
The bot uses SQLite for persistent data storage with the following main tables:
- User ID, Username, Join Date
- Role Information
- Member Metadata
- User ID, Points Balance
- Transaction History
- Last Update Timestamp
- Member sync status
- Last synchronization time
- Sync error tracking
Contains 129 programming questions organized by day (Day 1-129), including:
- Question title
- Input example
- Expected output
- Detailed explanation
- Formula (where applicable)
Tech terminology database with:
- Term name
- Definition
- Category
- Current index pointer
- Commands use Discord's permission system
- Role-based access control for admin features
- Secure database operations with prepared statements
- Token security via environment variables
- Rate limiting on API calls
Members accumulate points through:
- Message interactions
- Command usage
- Event participation
- Achievement milestones
- Updated in real-time
- Top 10 players displayed
- Pagination support for browsing
- Personal rank visibility
- Automatic sync on member join/leave
- Periodic bulk synchronization
- State tracking to prevent duplicates
- Metadata preservation
- Scheduled posting at 8:00 PM
- Automatic rotation through terminologies
- Category-based organization
- Preview functionality
The bot tracks:
- Total member points
- Leaderboard rankings
- Daily active members
- Command usage statistics
- Sync success/failure rates
- Comprehensive error logging
- Graceful fallbacks for API failures
- Database transaction rollback on errors
- User-friendly error messages
- Retry mechanisms for failed operations
- Daily terminology rotation
- Question of the day selection
- Member points synchronization
- Leaderboard recalculation
- Database optimization
- Old data archival
- Sync state cleanup
- Cache management
Edit prompts/botInstructions.txt to customize bot behavior
Add new questions to json/dailyQuestion.json following the format:
{
"Day": 1,
"Question": "Question title",
"Input": "Sample input",
"Output": "Expected output",
"Explain": "Explanation",
"Formula": "Optional formula"
}Add new terms to json/terminologies.json
Configure reminders through the bot's reminder system with time and message
- Review the main entry point: index.js
- Check slash command handlers: features/slashCommands.js
- Explore database operations: database/db.js
- Study automation features: features/
For issues, feature requests, or contributions:
- Check existing documentation
- Review code comments
- Follow Discord.js best practices
- Test thoroughly before submitting
- Discord.js - Discord API wrapper
- SQLite3 - Database management
- Node.js - Runtime environment
- JSON - Data storage format
- Current Version: 1.0.0
- Last Updated: February 2026
- Status: Active & Maintained
The bot includes a comprehensive 129-day programming question bank covering:
- Basic Programming Concepts
- Arithmetic & Logic Operations
- String & Number Manipulation
- Geometric Calculations
- Pattern Recognition
- Data Structures
- Object-Oriented Programming
- Advanced Algorithms
Perfect for daily learning and coding practice!
- Real-time Leaderboard - See who's leading
- Personal Statistics - Track your progress
- Daily Learning - 129 programming questions
- Tech Insights - Daily terminology posts
- Community Events - Meeting tracking & announcements
Made with ❤️ for the Community