An advanced multi-timeframe cryptocurrency trading bot with Fibonacci targets, ATR-based trailing stops, and intelligent position management.
MADE FOR US TRADERS - FULLY COMPLIANT WITH US REGULATIONS
This bot is specifically designed to meet US regulatory requirements:
- ✅ SPOT TRADING ONLY (no futures, no derivatives)
- ✅ LONG POSITIONS ONLY (no shorting)
- ✅ NO LEVERAGE (100% compliant with US regulations)
- ✅ US EXCHANGES ONLY (Binance US)
- ✅ Regulatory Compliant for US retail traders
Hard to find USA-compliant multi-timeframe bots? This is one of the few automated bots built specifically for US traders.
API keys are optional. Paper/read-only mode uses the public REST API — no account or key required. Keys are only needed for live order execution.
GG Moonshot is a sophisticated trading system that simultaneously monitors 8 different timeframes (1m, 5m, 15m, 30m, 1h, 2h, 4h, 1d) to identify optimal entry and exit points across multiple cryptocurrency pairs on Binance.US.
- Multi-Timeframe Analysis: Scans 8 timeframes with optimized cadence
- Dual Exit Strategies:
- 1h: Fibonacci extension targets with ATR trailing
- Other TFs: R-multiple exits with ATR-based stops
- Smart Position Management: Max 2 concurrent positions with rotation
- Rich Console UI: Live wallet and position tracking
- Persistent State: Saves positions, trades, stats across restarts
- Paper & Live Modes: Safe testing before real trading
- Risk Management: Configurable risk fraction per trade
1-Hour Timeframe (Moonshot):
- Breakout detection: Close > swing high by configurable %
- Volume spike confirmation
- Fibonacci-based position sizing
Other Timeframes (1m/5m/15m/30m/2h/4h/1d):
- Timeframe-specific entry rules
- Momentum and volatility filters
- Adaptive to market conditions
1-Hour Timeframe:
- TP1: 1.0 Fibonacci extension
- TP2: -0.382 Fibonacci retracement
- TP3: -0.618 Fibonacci retracement
- ATR trailing stop after TP1
Other Timeframes:
- TP1: 1.0R (1x ATR from entry)
- TP2: 1.8R
- TP3: 2.6R
- ATR trailing stop after TP1
- Maximum Positions: 2 concurrent (bot-managed)
- Rotation: Exits losing positions when stronger signals appear
- Portfolio View: Separate wallet table (all holdings) and bot table (managed positions)
Windows:
pip install ccxt pandas numpy rich python-dotenvLinux/macOS:
pip3 install ccxt pandas numpy rich python-dotenv- ccxt: Exchange connectivity
- pandas: Data analysis
- numpy: Numerical operations
- rich: Beautiful console UI
- python-dotenv: Environment configuration
Set these in your environment or .env file:
GG_PAPER=0 # 1 for paper trading, 0 for live (default: live)
GG_SCAN_CAP=0 # Max pairs to scan (0=all)
GG_CHUNK=10 # API request chunk size
GG_BREAKOUT_PCT=2.0 # Breakout threshold percentage
GG_VOL_SPIKE=2.0 # Volume spike multiplier
GG_ATR_MULT=2.0 # ATR trailing stop multiplier
GG_RISK_FRAC=0.18 # Risk fraction per trade (18%)
GG_CYCLE_SLEEP=30 # Seconds between scan cycles
GG_DUST=1.0 # Minimum position size in USD-
API Keys: On first run, the bot will prompt for:
- Binance.US API Key
- Binance.US API Secret
- Keys are encrypted and saved to
.gg_keys.json
-
Paper Mode Testing (Recommended):
export GG_PAPER=1
python gg_moonshot_mtf.py- Live Trading (After Testing):
export GG_PAPER=0
python gg_moonshot_mtf.pyRun_Moonshot_MTF.batWindows:
python gg_moonshot_mtf.pyLinux/macOS:
python3 gg_moonshot_mtf.pyThe bot displays:
Header:
- Session P&L
- Total P&L
- Current time
Wallet Table:
- All spot holdings
- Current values
- Total portfolio value
Bot Table:
- Active positions (max 2)
- Entry prices
- Current P&L
- Exit targets
- Trailing stops
The bot optimizes API usage by scanning timeframes at different cadences:
| Timeframe | Scan Frequency |
|---|---|
| 1m | Every cycle |
| 5m | Every cycle |
| 15m | Every cycle |
| 30m | Every 2 cycles |
| 1h | Every cycle |
| 2h | Every 2 cycles |
| 4h | Every 4 cycles |
| 1d | Every 8 cycles |
goldengoose-moonshot/
├── gg_moonshot_mtf.py # Main bot script
├── Run_Moonshot_MTF.bat # Windows launcher
├── .gg_keys.json # Encrypted API keys (created on first run)
├── positions.json # Active positions state
├── trades.csv # Trade history log
├── stats.json # Total P&L stats
└── session.json # Session P&L tracking
- Position Limits: Max 2 concurrent positions
- Risk Per Trade: Configurable (default 18% of capital)
- ATR-Based Stops: Dynamic stop losses based on volatility
- Trailing Stops: Lock in profits as price moves favorably
- Rotation Logic: Cuts losing positions for better opportunities
Conservative:
GG_RISK_FRAC=0.10 # 10% per trade
GG_ATR_MULT=2.5 # Wider stops
GG_BREAKOUT_PCT=3.0 # Higher breakout thresholdBalanced (Default):
GG_RISK_FRAC=0.18 # 18% per trade
GG_ATR_MULT=2.0 # Standard stops
GG_BREAKOUT_PCT=2.0 # Standard breakoutAggressive:
GG_RISK_FRAC=0.25 # 25% per trade
GG_ATR_MULT=1.5 # Tighter stops
GG_BREAKOUT_PCT=1.5 # Lower breakout thresholdAll trades are logged to trades.csv with:
- Timestamp
- Symbol
- Side (BUY/SELL)
- Amount
- Price
- P&L
- Exit reason
- Tracked in
session.json - Resets each time bot starts
- Shows current session P&L
- Tracked in
stats.json - Persists across restarts
- Shows lifetime P&L
The bot automatically retries on time synchronization issues. If persistent:
- Sync your system clock
- Check network latency to Binance
- Verify pairs are trading on Binance.US
- Check
GG_BREAKOUT_PCT- may be too high - Review
GG_VOL_SPIKEthreshold
- Increase
GG_CYCLE_SLEEP - Reduce
GG_SCAN_CAPto scan fewer pairs - Increase
GG_CHUNKsize
If both position slots are filled and a new strong signal appears while one position is losing, the bot will:
- Exit the losing position
- Enter the new opportunity
- Maintain max 2 positions
Based on swing high/low:
- 1.0 extension
- -0.382 retracement
- -0.618 retracement (Golden Ratio)
Risk-reward based targets:
- 1R = Break even after fees
- 1.8R = Profitable exit
- 2.6R = Extended profit target
- Live Trading Risk: Default mode is LIVE. Set
GG_PAPER=1for safe testing - Capital Requirements: Ensure sufficient capital for position sizing
- API Limits: Respect Binance.US rate limits
- Monitoring: Check bot regularly, don't leave unattended long-term
- Testing: Always paper trade first with new settings
This is version 1d with MTF (Multi-Timeframe) support. Key improvements:
- Multi-timeframe scanning
- Optimized API cadence
- Enhanced exit logic
- Better position rotation
- Improved UI
Provided as-is for personal use and learning.
GG Moonshot - Because good trading is golden 🌙✨