Warning
This Project is no longer be maintained and has been moved to Eigen-Bot All further updates will only be shared in @Eigen-Bot
A feature-rich, production-ready Discord bot combining economy systems, community engagement, entertainment, and powerful moderation tools.
Eigen Bot is an all-in-one Discord bot designed for thriving communities. Built with modern async Python and discord.py, it offers a complete suite of features from economy management and casino games to starboard highlights, voting systems, and custom tags—all with hybrid command support (both prefix f? and slash / commands).
A comprehensive virtual currency system with multiple ways to earn and spend:
💰 Income Commands:
f?work- Earn coins through work (30min cooldown, 100-300 coins)f?collect- Collect hourly reward (60min cooldown, 50 coins)f?daily- Claim daily bonus (24hr cooldown, 500 coins)f?weekly- Claim weekly bonus (7 days cooldown, 2,500 coins)f?beg- Beg for coins (1min cooldown, 10-100 coins, 70% success)f?search- Search random places (45s cooldown, 5-120 coins, 80% success)
💸 Risk & Reward:
f?crime- Commit crimes for big rewards (5min cooldown, risky!)- 40% success rate for 300-2,000 coins
- 60% chance of 200-600 coin fine
f?rob @user- Rob other users (10min cooldown, very risky!)- 35% success rate to steal 10-30% of their balance (max 5,000)
- 65% chance to lose 200-500 coins
f?gamble <amount>- Quick gamble (30s cooldown)- 45% chance to double your bet
- 55% chance to lose it all
- Min: 50 coins, Max: 10,000 coins
💳 Banking & Transfers:
f?balance [@user]- Check wallet and bank balancef?deposit <amount|all>- Move coins to bank (safe storage)f?withdraw <amount|all>- Take coins from bankf?transfer @user <amount>- Send coins to others (with anti-fraud)f?give @user <amount>- Gift coins (no tax, min 10)
📊 Statistics & Rankings:
f?profile [@user]- Detailed user profile with economy statsf?leaderboard- Top 10 richest usersf?richest- Top 15 with detailed wallet/bank breakdown- Transaction History: Full audit trail of all economic activity
- Anti-Fraud Protection: Built-in detection and prevention systems
Professional casino implementation with responsible gaming features:
- Blackjack: Full implementation with dealer AI, hit/stand, double down, insurance
- Roulette: European wheel with multiple bet types (numbers, dozens, colors, odds/evens)
- Slots: 3-reel slot machine with paytable and progressive jackpot
- Poker: Texas Hold'em framework (expandable)
- Bowling: Mini-game with wagering support
- Responsible Gaming:
- Configurable bet limits (min/max)
- Daily wager limits per user
- Cooldown systems to prevent excessive gambling
- Addiction awareness notices
Highlight the best messages in your community:
- Automatic Highlighting: Messages that reach a star threshold appear in starboard
- Customizable:
- Set custom star emoji (, , etc.)
- Adjustable threshold (1-50 stars)
- Self-starring enabled/disabled
- Beautiful Embeds: Dynamic colors based on star count, author thumbnails, timestamps
- Real-time Updates: Starboard messages update as stars are added/removed
- Smart Handling: Tracks who starred what, prevents duplicates, handles uncached messages
- Admin Tools:
f?starboard_cleanupto remove invalid entries - Commands:
f?starboard setup #channel <threshold> <emoji>f?starboard stats- View server statisticsf?starboard toggle- Enable/disable system
Create and share custom text snippets:
- Create Tags:
f?tags create <name> <content>- Store reusable text - Retrieve Tags:
f?tag <name>- Quickly fetch stored content - Edit Tags:
f?tags edit <name> <new_content>- Update existing tags - Delete Tags:
f?tags delete <name>- Remove unwanted tags - List Tags:
f?tags list- View all server tags - Usage Tracking: Tracks how many times each tag is used
- Per-Server: Tags are unique to each guild
Democratic decision-making for your community:
- Create Elections:
f?election create <title> <candidates> [duration] - Weighted Voting: Vote strength based on user roles/tenure
- Multiple Candidates: Support for 2-10 candidates per election
- Live Results: Real-time vote counting and display
- Interactive Voting: Button-based voting interface
- Vote Changes: Users can change their vote before election ends
- Timed Elections: Auto-close after specified duration (1-1440 minutes)
- Visual Results: Beautiful result displays with percentages and vote counts
Professional invite tracking and analytics:
- Invite Codes:
/invitecodes- View your invite codes and usage statistics - Invited List:
/invitedlist- List members you've invited to the server - Check Inviter:
/inviter- See who invited a specific member - Leaderboard:
/inviteleaderboard- Server-wide invite rankings - Real-time Tracking: Automatic detection of invite usage
- Fake Detection: Flags accounts less than 7 days old
- Leave Tracking: Updates stats when invited members leave
- Detailed Analytics: Total, valid, left, and fake invite statistics
Entertainment and engagement features:
- Programming Jokes:
f?joke- Get a clean programming-related joke - Compliments:
f?compliment [@user]- Give professional programming compliments - Fortune:
f?fortune- Receive a programming-themed fortune - Trivia:
f?trivia- Programming trivia questions with categories - 8-Ball:
f?8ball <question>- Magic 8-ball responses - Coin Flip:
f?coinflip- Heads or tails - Dice Roll:
f?roll [size] [count]- Roll dice (supports custom sizes and counts)
Professional gambling system with multiple games:
- Blackjack:
/blackjack <bet>- Play 21 with interactive buttons (hit, stand, double down)- Full blackjack rules with 3:2 payouts for natural blackjack
- Dealer plays to standard rules (hit until 17)
- Interactive UI with Discord buttons
- Roulette:
/roulette <type> [value] <bet>- European roulette with all bet types- Number bets (0-36): 36x payout
- Color bets (red/black): 2x payout
- Odd/even bets: 2x payout
- Range bets (low/high): 2x payout
- Slot Machine:
/slots <bet>- Three-reel slots with symbol matching- 8 unique symbols with weighted probabilities
- 3-of-a-kind jackpots up to 50x
- 2-of-a-kind small wins
- Coinflip:
/coinflip <heads/tails> <bet>- Simple 50/50 double-or-nothing- Animated coin flip
- 2x payout on win
- Dice:
/dice <prediction> <bet>- Roll two dice and predict the outcome- Over/under bets: 2x payout
- Lucky seven: 4x payout
- Exact number: 10x payout
- Crash:
/crash <bet> <target>- Cash out before the multiplier crashes- Set target multiplier (1.1x to 100x)
- Animated multiplier climb
- High risk, high reward
- Russian Roulette:
/russianroulette <bet>- 1 in 6 chance to lose- 5x payout if you survive
- Dramatic reveal animation
- Ultimate high-stakes game
Casino Features:
- Minimum/maximum bet limits
- Anti-fraud protection
- Cooldown management
- Professional embeds with results
- Balance tracking and payouts
- Responsible gambling notices
Build an active, engaged community:
- Random Quotes:
f?quote- Inspirational programming quotes - Random Questions:
f?question- Programming discussion starters - Memes:
f?meme- Programming humor (placeholder API integration) - Suggestions: Submit and discuss community ideas
- QOTD (Question of the Day): Automated daily discussion prompts
Helpful tools for server management and user convenience:
- Emote List:
f?emotes [search]- Browse server emojis with optional search - Member Count:
f?membercount- View current server member count - Random Color:
f?randomcolor- Generate random hex colors with preview - Reminders:
f?remindme <time> <message>- Set personal reminders (10m, 2h, 1d format) - User Info:
f?whois [@user]- Detailed user information and stats - Invite Info: View detailed information about server invites
Powerful tools for server administrators:
- Economy Management:
f?add_money @user <amount>- Give coins to usersf?reset_economy CONFIRM- Reset all economy data (with confirmations)
- Permission-Based: All admin commands restricted to bot owner
- Audit Logs: All admin actions are logged
- Safe Guards: Multiple confirmation steps for destructive actions
- Async/Await: Full async implementation for optimal performance
- Hybrid Commands: Every command works with both
f?prefix and/slash commands - Cog-Based Structure: Modular design for easy maintenance and extensibility
- Type Hints: Comprehensive type annotations throughout codebase
- Error Handling: Graceful error handling with user-friendly messages
- Unknown Command Silence: Unknown commands produce no output (clean UX)
- SQLAlchemy ORM: Modern async database operations
- SQLite (Dev): Fast development with file-based database
- PostgreSQL (Production): Scalable production deployment
- Multiple Databases: Separate SQLite DBs for tags, starboard, invites
- Data Integrity: Proper constraints, indexes, and transaction handling
- Migration Ready: Easy schema updates and data migrations
- Connection Pooling: Efficient database connection management
- Caching: Smart caching for starboard and invite systems
- Rate Limiting: Built-in cooldown management
- Graceful Degradation: Continues working even if some features fail
- Comprehensive Logging: Detailed logs for debugging and monitoring
- Raw Event Handling: Starboard processes uncached messages efficiently
- Environment Variables: Secure token and config storage
- Permission Checks: Role-based command access control
- Input Validation: Sanitization of user inputs
- SQL Injection Prevention: Parameterized queries throughout
- Anti-Fraud: Detection systems for economy abuse
- Responsible Gaming: Daily limits and cooldowns for gambling
- Python 3.11 or higher
- Discord Bot Token (Get one here)
- Git (for cloning)
-
Clone the Repository
git clone https://github.com/TheCodeVerseHub/Eigen-Bot.git cd Eigen-Bot -
Create Virtual Environment
python -m venv .venv # Linux/macOS source .venv/bin/activate # Windows .venv\Scripts\activate
-
Install Dependencies
pip install -r requirements.txt
-
Configure Environment
cp .env.example .env # Edit .env with your bot token and settings -
Run the Bot
python bot.py
Create a .env file with the following:
# Required
DISCORD_TOKEN=your_bot_token_here
# Database (optional, defaults to SQLite)
DATABASE_URL=sqlite+aiosqlite:///eigen.db
# For production: postgresql+asyncpg://user:pass@host:port/dbname
# Bot Configuration
OWNER_ID=your_discord_user_id
LOG_LEVEL=INFO
# Development (optional)
GUILD_ID=your_test_server_id # For faster slash command sync
# Economy Settings
MIN_BET=10
MAX_BET=10000
WORK_REWARD=100
DAILY_REWARD=500
WEEKLY_REWARD=2500
DAILY_WAGER_LIMIT=100000- Prefix Commands:
f?command(e.g.,f?balance) - Slash Commands:
/command(e.g.,/balance) - Hybrid: Most commands support both formats!
f?balance [@user] - Check wallet and bank balance
f?work - Earn coins (30min cooldown)
f?collect - Hourly reward (1h cooldown)
f?daily - Claim daily reward (24h cooldown)
f?weekly - Claim weekly reward (7d cooldown)
f?transfer @user amt - Send coins to another user
f?leaderboard - Top 10 richest users
f?profile [@user] - View detailed profile
f?blackjack <bet> - Play blackjack
f?roulette <type> <value> <bet> - Play roulette
Types: number, dozen, color, even/odd
f?slots <bet> - Play slot machine
f?starboard setup #channel <threshold> <emoji> - Setup starboard
f?starboard channel #channel - Change channel
f?starboard threshold <number> - Change star requirement
f?starboard emoji <emoji> - Change star emoji
f?starboard stats - View statistics
f?starboard toggle - Enable/disable
f?starboard_cleanup confirm - Clean invalid entries
f?tag <name> - Retrieve a tag
f?tags create <name> <content> - Create new tag
f?tags edit <name> <content> - Edit existing tag
f?tags delete <name> - Delete a tag
f?tags list - List all tags
f?election create <title> <candidates> [duration] - Start election
f?election results - View results
f?election end - Force end election
f?invitecodes - View your invite codes and usage
f?invitedlist - List members you've invited
f?inviter [@member] - Check who invited a member
f?inviteleaderboard - Server invite rankings
f?syncinvites - Sync invite cache (Admin)
f?invitedocs - View documentation
f?joke - Programming joke
f?compliment [@user] - Give compliment
f?fortune - Programming fortune
f?trivia - Programming trivia question
f?8ball <question> - Magic 8-ball
f?coinflip - Flip a coin
f?roll [size] [count] - Roll dice
f?quote - Random programming quote
f?question - Random programming question
f?meme - Programming meme
f?emotes [search] - List server emojis
f?membercount - Server member count
f?randomcolor - Random color generator
f?remindme <time> <message> - Set reminder (10m, 2h, 1d)
f?whois [@user] - User information
f?add_money @user <amount> - Give coins to user
f?reset_economy CONFIRM - Reset all economy data
# Build image
docker build -t eigen-bot .
# Run container
docker run -d --env-file .env eigen-botdocker-compose up -dversion: '3.8'
services:
eigen-bot:
build: .
env_file: .env
volumes:
- ./data:/app/data
restart: unless-stopped- Connect GitHub repository
- Add environment variables
- Deploy automatically on push
- Create new Web Service
- Connect repository
- Set environment variables
- Deploy
- Create new app
- Set environment variables (Config Vars)
- Deploy via Git or GitHub integration
- Launch Ubuntu instance
- Install Python 3.11+
- Clone repo and setup
- Use systemd or PM2 for process management
- Setup Ubuntu 22.04 server
- Install dependencies
- Setup systemd service
- Configure nginx reverse proxy (optional)
- Set
DATABASE_URLto PostgreSQL - Configure proper
LOG_LEVEL - Set up automated backups
- Monitor bot health and logs
- Keep dependencies updated
- Rotate bot token periodically
- Set up error alerting
DATABASE_URL=sqlite+aiosqlite:///eigen.db- Perfect for testing and development
- File-based, easy to backup
- No external dependencies
DATABASE_URL=postgresql+asyncpg://user:password@host:port/database- Scalable for large servers
- Better concurrent access
- Advanced features and indexing
data/
├── eigen.db # Main economy database (SQLAlchemy)
├── tags.db # Tag system (aiosqlite)
├── starboard.db # Starboard system (aiosqlite)
└── invites.db # Invite tracker system (aiosqlite)
# Install dev dependencies
pip install pytest pytest-asyncio
# Run test suite
pytest
# Run with coverage
pytest --cov=. --cov-report=htmltests/
├── conftest.py # Shared fixtures
├── test_economy.py # Economy tests
└── __init__.py
We welcome contributions! Here's how:
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
- Add tests for new features
- Follow existing code style
- Update documentation
- Ensure all tests pass
- Use type hints
- Write clear commit messages
This project is licensed under the MIT License - see the LICENSE file for details.
- Documentation: Check
/docsfolder - Bug Reports: Open an issue
- Feature Requests: Open an issue
- Discord: Join our support server (link in bio)
Important Notice: This bot is designed for entertainment purposes only.
- Virtual currency has no real-world value
- Gambling can be addictive
- Please play responsibly
- Take breaks if needed
- If you have concerns about gambling addiction, seek professional help
Resources:
- Web dashboard for server configuration
- Advanced moderation tools
- Custom game modes and tournaments
- Achievement system
- Social features (friends, gifts)
- Seasonal events and limited-time content
- Multi-language support
- API for third-party integrations
Built with:
- discord.py - Discord API wrapper
- SQLAlchemy - ORM and database toolkit
- aiosqlite - Async SQLite
- python-dotenv - Environment management
Special thanks to:
- The discord.py community
- All contributors and testers
- You, for using Eigen Bot!