2026-05-29 23:29:31 +03:30
|
|
|
using FlatRender.IdentitySvc.Models.Requests;
|
|
|
|
|
using FlatRender.IdentitySvc.Models.Responses;
|
|
|
|
|
|
|
|
|
|
namespace FlatRender.IdentitySvc.Application.Services.Interfaces;
|
|
|
|
|
|
|
|
|
|
public interface IPlanService
|
|
|
|
|
{
|
2026-05-30 00:24:53 +03:30
|
|
|
Task<List<PlanResponse>> ListAsync(Guid? tenantId, string? scope);
|
2026-05-29 23:29:31 +03:30
|
|
|
Task<PlanResponse> GetByIdAsync(Guid planId);
|
|
|
|
|
Task<UserPlanResponse?> GetCurrentPlanAsync(Guid userId);
|
|
|
|
|
Task<PurchasePlanResponse> PurchasePlanAsync(Guid userId, Guid tenantId, PurchasePlanRequest request);
|
2026-06-01 16:41:13 +03:30
|
|
|
/// <summary>Cancel the current active plan. The subscription is marked cancelled
|
|
|
|
|
/// and will not auto-renew. Access continues until the expiry date.</summary>
|
|
|
|
|
Task CancelPlanAsync(Guid userId);
|
2026-05-29 23:29:31 +03:30
|
|
|
}
|