namespace KArtSell.Modules.ModelOperations.SellDecision;

public class CreateSellDecisionRequest
{
    public Guid ModelId { get; set; }
    public DateTime WindowStart { get; set; }
    public DateTime WindowEnd { get; set; }
    public decimal ThresholdPbo { get; set; } = 0.65m;
    public decimal ThresholdDsr { get; set; } = 0.015m;
    public required string Justification { get; set; }
}

public class CreateSellDecisionResponse
{
    public Guid DecisionId { get; set; }
    public Guid ModelId { get; set; }
    public required string Status { get; set; }
    public Guid CorrelationId { get; set; }
    public DateTime CreatedAt { get; set; }
}

public class SellDecisionDto
{
    public Guid DecisionId { get; set; }
    public Guid ModelId { get; set; }
    public required string Status { get; set; }
    public decimal? PboScore { get; set; }
    public decimal? DsrMetric { get; set; }
    public int? SellPriority { get; set; }
    public int? TargetQuantity { get; set; }
    public decimal? TargetPrice { get; set; }
    public Guid? ApprovalId { get; set; }
    public Guid? ExecutionId { get; set; }
    public DateTime CreatedAt { get; set; }
    public Guid CorrelationId { get; set; }
}

public class ListSellDecisionsResponse
{
    public required List<SellDecisionDto> Decisions { get; set; }
    public int Total { get; set; }
    public int Limit { get; set; }
    public int Offset { get; set; }
}

public class ExecuteSellDecisionRequest
{
    public Guid ApprovalId { get; set; }
    public decimal ExecutionPrice { get; set; }
    public int Quantity { get; set; }
    public required string Justification { get; set; }
}

public class ExecuteSellDecisionResponse
{
    public Guid DecisionId { get; set; }
    public Guid ExecutionId { get; set; }
    public required string Status { get; set; }
    public required string KisOrderId { get; set; }
    public DateTime SubmittedAt { get; set; }
    public Guid CorrelationId { get; set; }
}
