using GB5Shared.DTO.Framework.Login; namespace SwBLL.Integration; // Mirror of EntitlementDAL.DTOs.ClientEntitlementSnapshotDTO — no project reference exists (or // should exist) between SwBLL and EntitlementDAL/EntitlementBLL, same "no cross-business-module // BLL reference, call over HTTP instead" rule tracker §31/§38 already established for the // reverse direction (EntitlementBLL.Onboarding.ISqlWorkbenchClient's own local Sw*DTO mirrors). public class EntitlementSnapshotDTO { public int ClientId { get; set; } public byte SubscriptionStatus { get; set; } public DateTime SupportValidTill { get; set; } public int GracePeriodDays { get; set; } public byte DeploymentType { get; set; } public List EnabledFeatureCodes { get; set; } = new(); } /// Entitlement-aware provisioning/rollout gating (tracker §40). Calls Entitlement's /// GetClientEntitlementSnapshot endpoint to answer Gate A (subscription/support/deployment /// eligibility) and Gate B (feature/module licensing) questions for one client. public interface IEntitlementSubscriptionClient { /// Null if Entitlement has no snapshot for this client at all (e.g. a client /// database registered in SqlWorkbench with no corresponding MENTITLEMENTSUBSCRIPTION/ /// MCLIENT row yet) — callers must treat this as "cannot determine eligibility," not as /// "eligible by default." Task GetSnapshotAsync(int clientId, LoginDTO swLogin, CancellationToken ct); }