purchaseProduct

fun purchaseProduct(    activity: Activity,     storeProduct: StoreProduct,     upgradeInfo: UpgradeInfo,     listener: ProductChangeCallback)

Make a purchase upgrading from a previous sku.

Parameters

activity

Current activity

storeProduct

The StoreProduct of the product you wish to purchase

upgradeInfo

The upgradeInfo you wish to upgrade from, containing the oldSku and the optional prorationMode. Amazon Appstore doesn't support changing products so upgradeInfo is ignored for Amazon purchases.

listener

The PurchaseCallback that will be called when purchase completes.


fun purchaseProduct(    activity: Activity,     storeProduct: StoreProduct,     callback: PurchaseCallback)

Make a purchase.

Parameters

activity

Current activity

storeProduct

The StoreProduct of the product you wish to purchase

callback

The PurchaseCallback that will be called when purchase completes.

Sources

Link copied to clipboard
Link copied to clipboard