using Baya.Application.Models.Common;
using Baya.Application.Models.Refunds;
using Mediator;

namespace Baya.Application.Features.Refunds.Commands.CancelBookingAndRefund;

/// <summary>
/// The customer-initiated cancel: cancels the booking (freezing the resolved cancellation policy snapshot)
/// and opens the resulting refund in one call, returning the refund status. The customer *requests*; an
/// admin/ticket step still governs the money (the refund auto-opens a <c>refund</c> ticket). MVP cancels all
/// un-started sessions (the whole remaining engagement); <see cref="SessionIds"/> is accepted for
/// forward-compatibility. The booking id comes from the route.
/// </summary>
public record CancelBookingAndRefundCommand(
    string ReasonCategory,
    string ReasonNotes = null,
    IReadOnlyList<long> SessionIds = null,
    long BookingId = 0) : IRequest<OperationResult<RefundStatusDto>>;
