namespace TradingBot.Models; /// /// Configuration for a trading indicator /// public class IndicatorConfig { public string Id { get; set; } = string.Empty; public string Name { get; set; } = string.Empty; public string Description { get; set; } = string.Empty; public IndicatorType Type { get; set; } public bool IsEnabled { get; set; } = true; // Thresholds for signals public decimal? OverboughtThreshold { get; set; } public decimal? OversoldThreshold { get; set; } public decimal? BuyThreshold { get; set; } public decimal? SellThreshold { get; set; } // Indicator-specific parameters public int Period { get; set; } = 14; public int FastPeriod { get; set; } = 12; public int SlowPeriod { get; set; } = 26; public int SignalPeriod { get; set; } = 9; } /// /// Real-time indicator signal /// public class IndicatorSignal { public string IndicatorId { get; set; } = string.Empty; public string IndicatorName { get; set; } = string.Empty; public string Symbol { get; set; } = string.Empty; public DateTime Timestamp { get; set; } = DateTime.UtcNow; public SignalStrength Strength { get; set; } public SignalType Type { get; set; } public string Message { get; set; } = string.Empty; public decimal? Value { get; set; } } /// /// Indicator status for a specific asset /// public class IndicatorStatus { public string IndicatorId { get; set; } = string.Empty; public string Symbol { get; set; } = string.Empty; public decimal CurrentValue { get; set; } public decimal? PreviousValue { get; set; } public MarketCondition Condition { get; set; } public string Recommendation { get; set; } = string.Empty; public DateTime LastUpdate { get; set; } = DateTime.UtcNow; } /// /// Types of trading indicators /// public enum IndicatorType { RSI, // Relative Strength Index MACD, // Moving Average Convergence Divergence SMA, // Simple Moving Average EMA, // Exponential Moving Average BollingerBands, // Bollinger Bands Stochastic, // Stochastic Oscillator Volume, // Volume indicators ATR // Average True Range (volatility) } /// /// Signal strength levels /// public enum SignalStrength { Weak, Moderate, Strong, VeryStrong } /// /// Market condition based on indicators /// public enum MarketCondition { Neutral, Overbought, Oversold, Bullish, Bearish, Ranging, Trending }