using MediatR;

namespace StorageService.API.Application.Commands.FileShare;

/// <summary>
/// EN: Command to revoke a file share.
/// VI: Command để thu hồi file share.
/// </summary>
public record RevokeFileShareCommand(
    Guid ShareId,
    string UserId
) : IRequest<RevokeFileShareResult>;

/// <summary>
/// EN: Result of revoke file share operation.
/// VI: Kết quả của thao tác thu hồi file share.
/// </summary>
public record RevokeFileShareResult(bool Success, string? Error)
{
    public static RevokeFileShareResult Ok() => new(true, null);
    public static RevokeFileShareResult Fail(string error) => new(false, error);
}
