Complete Discord Economy System
A feature-rich multi-server economy bot with banking, lottery, shops, currency exchange, and activity rewards. Built with TypeScript and featuring Discord's modern Components V2 UI for a sleek, interactive experience.
Economy Systems
Multi-Currency
Each server has its own currency with custom name & emoji
Banking
View all accounts across servers, track earnings & spending
Exchange Panel
Live exchange rates panel with currency dropdowns
Lottery Panel
Daily, weekly & monthly lotteries with ticket system
Server Shop
Buy roles, items, and perks with server currency
Leaderboards
6 different ranking types with top 5 display
Tax System NEW
Weekly automated taxes with a communal tax pot
Loans NEW
Request loans with auto-repayment and bankruptcy options
Investments NEW
Invest in other servers and earn dividends
Voting NEW
Propose and vote on tax pot spending
Warnings & Fines NEW
Admin warnings with optional currency fines
Server Hierarchy NEW
Cross-server tax collection between linked servers
Modern UI with Components V2 NEW
All bot messages now use Discord's Components V2 format for a cleaner, more interactive experience with colored accent bars, rich text formatting, and visual separators.
🎨 Accent Colors
Each section has a colored accent bar for visual organization - gold for headers, blue for info, green for success.
📝 Rich Text
Support for headings (#, ##), bold text, and markdown formatting within component containers.
➖ Separators
Visual divider lines between sections for cleaner organization and easier reading.
🔘 Interactive Buttons
Refresh buttons, pagination, and action buttons integrated seamlessly into the new UI.
Example: Leaderboard Display
└ 🪙 15,230
🥈 PlayerTwo
└ 🪙 12,450
🥉 PlayerThree
└ 🪙 9,800
4. PlayerFour
└ 🪙 7,320
5. PlayerFive
└ 🪙 5,100
Rank #12 with 2,450
Leaderboard Categories
Six different leaderboard types to track various achievements. Each displays the top 5 entries with pagination.
Server Balance
Richest in current server
Global Net Worth
Total wealth across all servers
Most Transfers
Most transactions made
Currencies Owned
Most different server currencies
Lottery Wins
Most lottery victories
Most Active
Highest activity score
Slash Commands
| Command | Description | Access |
|---|---|---|
| /balance | Check your or another user's balance in the current server. | Everyone |
| /bank | View your bank overview with all accounts across servers. | Everyone |
| /transfer | Send currency to another user in the same server. | Everyone |
| /exchange | Exchange currency between different servers or to BotCoin. | Everyone |
| /leaderboard | View various leaderboards (balance, global, transfers, etc). | Everyone |
| /lottery | View lottery information and your tickets. | Everyone |
| /shop browse | Browse available items in the server shop. | Everyone |
| /shop inventory | View your purchased items. | Everyone |
| /admin currency | Set server currency name and emoji. | Admin |
| /admin rates | Configure earning rates for messages/voice/reactions. | Admin |
| /admin exchange panel | Create an exchange rate panel in a channel. | Admin |
| /admin lottery panel | Create a lottery panel in a channel. | Admin |
| /admin shop add | Add a new item to the shop. | Admin |
| /guide | Interactive guide with dropdown topic selection for all bot features. | Everyone |
| /loan request | Request a loan based on your management tier limit. | Everyone |
| /loan repay | Manually repay your active loans. | Everyone |
| /loan status | View your current loans and repayment progress. | Everyone |
| /loan bankruptcy | Declare bankruptcy to clear all debts (max 2 times). | Everyone |
| /invest buy | Buy ownership shares in a server using BotCoin. | Everyone |
| /invest sell | Sell your ownership shares back for BotCoin. | Everyone |
| /invest portfolio | View all your investments and earnings. | Everyone |
| /invest info | Get detailed information about a server's investment stats. | Everyone |
| /vote propose | Propose spending from the tax pot. | Management |
| /vote cast | Vote FOR or AGAINST an active proposal. | Voters |
| /vote list | View all active and recent proposals. | Everyone |
| /warn | Issue a warning to a user with optional fine. | Admin/Fine Manager |
| /finemanager | Set or remove the Fine Manager role. | Admin |
| /tax config | Configure tax rate and settings. | Admin |
| /tax pot | View the current tax pot balance and history. | Admin |
| /management add | Add a management role with specific tier and permissions. | Admin |
| /taxhierarchy | Configure cross-server tax relationships. | Admin |
| /investpanel | Create an investment panel in a channel. | Admin |
| /activity chart | Generate activity or exchange rate charts (7d/30d/90d). | Admin |
| /activity stats | View detailed activity statistics for a timeframe. | Admin |
Prefix Commands
Quick text-based commands using the default prefix !
| Command | Aliases | Description |
|---|---|---|
| !balance | !bal, !b | Quick balance check |
| !transfer | !pay, !send | Send currency to another user |
| !leaderboard | !lb, !top, !rank | View server leaderboard |
| !help | - | Show all available commands |
Activity Rewards & Lottery Tickets
Users earn currency and lottery tickets through server activity:
💬 Messages
Earn coins per message (with cooldown). Also earns lottery tickets based on message count.
😀 Reactions
Earn coins for adding reactions. Every 5 reactions earns a lottery ticket.
🎤 Voice Activity
Earn coins per minute in voice channels (must be unmuted with others). Also earns lottery tickets.
🎫 Lottery Tickets
Tickets are automatically entered into Daily, Weekly, and Monthly lottery drawings.
Lottery System
Three lottery types with automatic drawings and tiered prizes:
🌅 Daily Lottery
Drawn at midnight UTC daily. 1st, 2nd, and 3rd place prizes in BotCoin.
📅 Weekly Lottery
Drawn Sunday midnight UTC. Larger prizes for weekly participation.
🗓️ Monthly Lottery
Drawn 1st of each month. Biggest jackpots for dedicated participants.
📊 Lottery Panel
Admin-created panel showing all lotteries, ticket counts, recent winners, and how to earn tickets.
Tax System NEW
Automated weekly tax collection with a communal pot for server projects:
📅 Weekly Collection
Taxes are automatically collected every Sunday at midnight UTC. Configurable tax rate (default 10%).
💵 Tax Pot
All collected taxes go into a communal pot. View balance with /tax pot.
⚙️ Admin Control
Enable/disable taxes, set rates, and distribute funds using admin commands.
📊 Transparency
Tax summaries posted to economy alert channel showing total collected and users taxed.
Loan System NEW
Borrow currency with automatic repayments and bankruptcy protection:
📝 Request Loans
Use /loan request to borrow currency. Loan limits based on management tier (1,000 - 50,000).
💸 Auto-Repayment
Loans are automatically repaid when your balance reaches the loan amount. Processed every 10 minutes.
📉 Interest Rates
Server-configurable interest rates. Admins can start polls to change rates via voting.
🏦 Bankruptcy
Use /loan bankruptcy to clear all debts. After 2 bankruptcies, you're permanently banned from loans.
Loan Limits by Management Tier
Tier 2: Up to 5,000 currency
Tier 3: Up to 10,000 currency
Tier 4: Up to 25,000 currency
Tier 5: Up to 50,000 currency
Investment System NEW
Invest in other servers and earn daily dividends based on their activity:
🌐 Cross-Server Investing
Use BotCoin to buy ownership shares in other servers. Prices fluctuate based on server activity.
💵 Daily Dividends
Automatically receive dividends at 6 AM UTC based on your ownership percentage and server revenue.
📊 Investment Panel
Admin-created panel showing available servers, prices, and your current holdings.
💼 Portfolio View
Use /invest portfolio to see all your investments, earnings, and performance.
Voting System NEW
Democratic spending of the tax pot through community voting:
📋 Propose Spending
Management roles can propose using tax pot funds for grants, projects, or events.
✅ Cast Votes
Members with voting privileges can vote FOR or AGAINST proposals.
📊 Majority Rules
Simple majority (50%+) passes. Proposals that would deplete the pot require 2/3 majority.
⏰ Auto-Processing
Expired votes are automatically tallied hourly. Passed proposals execute immediately.
Warning & Fine System NEW
Moderation tools with optional economic penalties:
📝 Issue Warnings
Admins and Fine Managers can warn users with /warn user reason.
💸 Optional Fines
Attach currency fines to warnings. Fines are automatically deducted from the user's balance.
👮 Fine Manager Role
Delegate fine-issuing power to a specific role without giving full admin access.
📜 Warning History
View complete warning history for any user including reasons and fine amounts.
Server Hierarchy NEW
Link servers together for cross-server tax collection:
🔗 Link Servers
Set up main/secondary server relationships. Bot must be in both servers.
💰 Daily Tax Flow
Secondary servers pay a percentage (default 5%) of their tax pot to the main server daily.
⚙️ Configurable Rates
Customize the cross-server tax rate for each linked server pair.
🔒 Auto-Deactivate
If the bot leaves a secondary server, the hierarchy is automatically deactivated.
Activity Charts NEW
Visual analytics for server activity and exchange rates:
📈 Activity Charts
Generate line charts showing messages, voice minutes, and reactions over time.
💱 Exchange Rate Charts
Track how your server's exchange rate has changed based on activity levels.
📅 Multiple Timeframes
View data for 7 days, 30 days, or 90 days. Perfect for short and long-term analysis.
📊 Statistics
Get detailed stats including totals, daily averages, peak activity days and hours.
Interactive Guide NEW
In-bot help system with dropdown topic selection:
📖 /guide Command
Access the interactive guide with detailed explanations of all bot features.
🔽 Topic Dropdown
Select from topics: Earning, Exchange, Lottery, Tax, Loans, Investments, Voting, Warnings, and Hierarchy.
🔄 Refresh Button
Reset the guide to the topic selection menu at any time.
📱 User-Friendly
No need to remember commands - browse topics interactively and learn at your own pace.
Setup Guide
Create Discord Bot
Go to the Discord Developer Portal, create a new application, and add a bot.
Configure Environment
Create a .env file with your credentials:
CLIENT_ID=your_client_id
DATABASE_URL="file:./dev.db"
Install & Setup Database
Install dependencies and initialize the database:
npx prisma db push
Run the Bot
Start the bot:
# Or for development with auto-reload:
npm run dev
Admin Panel Setup
Create interactive panels in your server for members to use:
🔄 Exchange Panel
Use /admin exchange panel #channel to create a live exchange rate panel with currency dropdowns. Updates every 5 minutes.
🎰 Lottery Panel
Use /admin lottery panel #channel to create a lottery info panel showing all drawings, tickets, and recent winners.
📈 Investment Panel NEW
Use /investpanel create #channel to create an investment panel showing available servers and prices.
🔄 Trading Panel
Use /admin trading panel #channel to create a trading panel for buying/selling currencies.
💰 Currency Setup
Use /admin currency name emoji to set your server's custom currency name and emoji.
📊 Rate Config
Use /admin rates to configure how much users earn from messages, voice, and reactions.
Required Permissions
OAuth2 Scopes
✅ bot
✅ applications.commands
Bot Permissions
✅ Send Messages
✅ Embed Links
✅ Use Slash Commands
✅ Manage Roles (for shop)
Gateway Intents
✅ Guilds
✅ GuildMessages
✅ GuildVoiceStates
✅ GuildMessageReactions
✅ MessageContent (privileged)