using System;
using System.Collections.Generic;
using FinlyticCore.Models.Analyzer;
namespace FinlyticCore.Models.Trades;
///
/// Trade proposal generated by FinlyticAnalyzer and dispatched via MQTT QoS 2.
///
public class TradeProposalDto
{
public string TradeId { get; set; } = string.Empty;
public string? UserId { get; set; }
public bool IsGlobalProposal { get; set; } = true;
public string Status { get; set; } = "Proposed";
public string AnalysisId { get; set; } = string.Empty;
public string EventId { get; set; } = string.Empty;
public string Sector { get; set; } = string.Empty;
public string Symbol { get; set; } = string.Empty;
public string Isin { get; set; } = string.Empty;
public string CompanyName { get; set; } = string.Empty;
public decimal EntryPrice { get; set; }
public decimal StopLoss { get; set; }
public decimal TakeProfit { get; set; }
public string SignalType { get; set; } = "BUY"; // "BUY", "SELL"
public string RiskTolerance { get; set; } = "Moderate"; // "Conservative", "Moderate", "Aggressive"
public string Timeframe { get; set; } = "1D"; // "1H", "4H", "1D", "1W"
public string InstrumentType { get; set; } = "Stock"; // "Stock", "Option", "CFD", "Crypto"
public double WinRate { get; set; }
public VixMarketRegime VixRegime { get; set; }
public decimal VixValue { get; set; }
public int TtlMinutes { get; set; } = 60;
public string Reasoning { get; set; } = string.Empty;
// --- New Fields for Detailed Execution & Rationale ---
public decimal? EntryZoneMin { get; set; }
public decimal? EntryZoneMax { get; set; }
public List? TakeProfitTargets { get; set; }
public decimal? RiskRewardRatio { get; set; }
public decimal? MaxLeverage { get; set; }
public string TechnicalRationale { get; set; } = string.Empty;
public string FundamentalRationale { get; set; } = string.Empty;
public string RiskWarning { get; set; } = string.Empty;
// --- Real Trade Execution Data ---
public decimal? ActualEntryPrice { get; set; }
public decimal? PositionSize { get; set; }
public decimal? LeverageUsed { get; set; }
public decimal? EntryFee { get; set; }
public decimal? ExitFee { get; set; }
public DateTime? ExecutionTimestamp { get; set; }
public decimal? Quantity { get; set; }
public decimal? KnockoutThreshold { get; set; }
public bool IsRecurring { get; set; } = false;
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
}