using InboxIntel.Domain.Enums;
namespace InboxIntel.Application.DTOs;
/// Request to run a bulk cleanup action over a set of emails or a query.
public record CleanupRequestDto(
CleanupActionType Action,
IReadOnlyList? EmailIds,
string? Query,
string? LabelId,
bool Confirmed);
///
/// Preview of what a cleanup action would affect. Per the safety rules, no
/// destructive action runs until the user confirms this preview.
///
public record CleanupPreviewDto(
CleanupActionType Action,
int AffectedCount,
long AffectedSizeBytes,
IReadOnlyList Sample);
public record CleanupResultDto(
CleanupActionType Action,
int SucceededCount,
int FailedCount,
IReadOnlyList Errors);
public record UnsubscribeItemDto(
Guid Id,
string SenderAddress,
string Domain,
UnsubscribeMethod Method,
UnsubscribeStatus Status,
int EmailCount,
string? UnsubscribeTarget);
public record UnsubscribeRequestDto(IReadOnlyList ItemIds, bool Confirmed);