PurchasesDelegate
interface PurchasesDelegate
A listener interface responsible for handling promotional product purchases (App Store only) and changes to customer information.
Inheritors
Functions
Link copied to clipboard
Called whenever Purchases receives updated customer info. This may happen periodically throughout the life of the app if new information becomes available.
Link copied to clipboard
abstract fun onPurchasePromoProduct(product: <Error class: unknown class>, startPurchase: (onError: (<Error class: unknown class>, userCancelled: Boolean) -> Unit, onSuccess: (<Error class: unknown class>, <Error class: unknown class>) -> Unit) -> Unit)
App Store only. Called when a user initiates a promotional in-app purchase from the App Store. If your app is able to handle a purchase at the current time, run the deferment block in this method. If the app is not in a state to make a purchase: cache the startPurchase block, then call the startPurchase block when the app is ready to make the promotional purchase.