Overview
The terminal uses a local SQLite database (apeindex_bot.db). All 14 tables are created automatically on first launch with forward-compatible ALTER TABLE migrations for new columns.
Single-node SQLite. For multi-user horizontal scaling, migration to PostgreSQL is on the roadmap.
Core Tables
users
positions
signal_history
trades
Wallet Tracking Tables
followed_wallets (Follow Wallets — notify only)
copy_wallets (Copy Trade — auto-mirror)
copy_trades
Referral Tables
referrals
referral_earnings
Additional Tables
watchlist
paper_positions / paper_trades
Identical schema to positions and trades but isolated for paper trading mode. Use the same SL/TP logic, copy trade execution, and P&L tracking against the virtual $10,000 balance.