Automated crypto futures trading bot for Bybit exchange.
# 1. Setup
chmod +x setup.sh && ./setup.sh
# 2. Configure
nano .env # Add your API keys + Telegram bot token
# 3. Run
pm2 start ecosystem.config.js
# or manually:
source venv/bin/activate && python src/main.py
Bybit API: bybit.com → Account → API Management → Create New Key
Telegram Bot: Message @BotFather → /newbot → copy token
src/
├── main.py # Entry point
├── config.py # All settings from .env
├── exchange/
│ ├── client.py # Bybit API wrapper (orders, positions, market data)
│ ├── order_manager.py # TP/SL placement and management
│ └── symbols.py # Instrument info cache
├── core/
│ ├── position.py # Position tracking
│ ├── risk.py # Risk management (sizing, limits)
│ └── trade_log.py # JSON trade journal
├── strategies/
│ ├── base.py # Strategy interface (ABC)
│ └── (your strategies here)
├── bot/
│ ├── telegram_bot.py # Alerts + commands
│ └── formatters.py # Message templates
└── utils/
├── logger.py # Logging with Vancouver timestamps
└── time_utils.py # Timezone helpers
src/strategies/my_strategy.pyBaseStrategy from src/strategies/base.pyscan(), on_signal(), check_position(), get_config()src/main.py/status — overview + PnL/balance — wallet balance/positions — open positions/pnl [today|week|all] — PnL stats/pause / /resume — toggle tradingSee .env.example for all available settings.