namespace RealCV.Application.Models;

/// <summary>
/// Result of verifying a professional qualification (FCA)
/// </summary>
public sealed record ProfessionalVerificationResult
{
    public required string ClaimedName { get; init; }
    public required string ProfessionalBody { get; init; }
    public required bool IsVerified { get; init; }

    // Matched professional details
    public string? MatchedName { get; init; }
    public string? RegistrationNumber { get; init; }
    public string? Status { get; init; }
    public string? CurrentEmployer { get; init; }
    public DateOnly? RegistrationDate { get; init; }

    // For FCA
    public List<string>? ApprovedFunctions { get; init; }
    public List<string>? ControlledFunctions { get; init; }

    public string? VerificationNotes { get; init; }
    public List<ProfessionalVerificationFlag> Flags { get; init; } = [];
}

public sealed record ProfessionalVerificationFlag
{
    public required string Type { get; init; }
    public required string Severity { get; init; }
    public required string Message { get; init; }
    public int ScoreImpact { get; init; }
}
