using MediatR;

namespace AdsManagerService.API.Application.Queries;

/// <summary>
/// EN: Query to get ad set by ID.
/// VI: Query lấy ad set theo ID.
/// </summary>
public record GetAdSetByIdQuery : IRequest<AdSetDto?>
{
    public Guid AdSetId { get; init; }
}

/// <summary>
/// EN: AdSet DTO for API responses.
/// VI: AdSet DTO cho API responses.
/// </summary>
public record AdSetDto
{
    public Guid Id { get; init; }
    public Guid CampaignId { get; init; }
    public string Name { get; init; } = null!;
    public string Status { get; init; } = null!;
    public decimal DailyBudget { get; init; }
    public string BidType { get; init; } = null!;
    public decimal? BidAmount { get; init; }
    public DateTime? StartDate { get; init; }
    public DateTime? EndDate { get; init; }
    public TargetingDto? Targeting { get; init; }
    public DateTime CreatedAt { get; init; }
    public DateTime? UpdatedAt { get; init; }
}

/// <summary>
/// EN: Targeting DTO.
/// VI: Targeting DTO.
/// </summary>
public record TargetingDto
{
    public int? MinAge { get; init; }
    public int? MaxAge { get; init; }
    public List<string>? Genders { get; init; }
    public List<string>? Locations { get; init; }
    public List<string>? Interests { get; init; }
}
