Web Paywall Redeemer
class WebPaywallRedeemer(context: Context, ioScope: IOScope, deepLinkReferrer: CheckForReferral, network: Network, storage: Storage, customerInfoManager: CustomerInfoManager, factory: WebPaywallRedeemer.Factory)(source)
Constructors
Link copied to clipboard
constructor(context: Context, ioScope: IOScope, deepLinkReferrer: CheckForReferral, network: Network, storage: Storage, customerInfoManager: CustomerInfoManager, factory: WebPaywallRedeemer.Factory)
Functions
Link copied to clipboard
Link copied to clipboard
suspend fun checkForWebEntitlements(userId: UserId?, deviceId: DeviceVendorId): Either<Set<Entitlement>, Throwable>
Link copied to clipboard
Link copied to clipboard
Fetches the customer's web entitlements once, as each poll does, and applies them: the merged customer info and subscription status are updated when they've changed. For when something outside the app, such as a web management page, may have changed them and the next poll is too far off. Makes a network request, so call it off the main thread.