2.0.0-alpha.1
Pre-release2.0.0-Alpha.1
Breaking Changes
SuperwallPaywallActivity
andPaywallView
have been moved intocom.superwall.sdk.paywall.view
package fromcom.superwall.sdk.paywall.vc
package.- Removes
PaywallComposable
and Jetpack Compose support from the main SDK artifact in favor ofSuperwall-Compose
module for Jetpack Compose support:- You can find it at
com.superwall.sdk:superwall-compose:2.0.0-alpha
- Usage remains the same as before, but now you need to include the
superwall-compose
module in your project.
- You can find it at
- Removed methods previously marked as Deprecated
- Removes
SubscriptionStatus
, together with belonging update methods andsubscriptionStatusDidChange
callback. - These are replaced with
EntitlementStatus
andentitlementStatusDidChange
callback. You can find more details on this migration in our docs.
Enhancements
-
Adds
purchase
method toSuperwall
you can use to purchase products without having to resort on paywalls. To purchase a product you can pass it in one of the following objects:- Google Play's
ProductDetails
- Superwall's
StoreProduct
object - Or a string containing the product identifier, i.e.
Superwall.instance.purchase("product_id:base_plan:offer")
- Google Play's
-
Adds
restorePurchases
method toSuperwall
you can use to handle restoring purchases -
Adds
getProducts
method toSuperwall
you can use to retrieve a list ofProductDetails
given the product ID, i.e. i.e.Superwall.instance.purchase("product_id:base_plan:offer")
. This is intented to make retrieving and purchasing products easier, since there is no need to handleBillingClient
's connections and errors as Superwall does it for you. -
Adds support for observing purchases done outside of Superwall paywalls. You can now observe purchases done outside of Superwall paywalls by setting the
shouldObservePurchases
option to true and either:- Manually by calling
Superwall.instance.observe(PurchasingObserverState)
or utility methodsSuperwall.instance.observePurchaseStart/observePurchaseError/observePurchaseResult
- Automatically by replacing
launchBillingFlow
withlaunchBillingFlowWithSuperwall
. This will automatically observe purchases done outside of Superwall paywalls.
- Manually by calling
-
Adds consumer proguard rules to enable consumer minification
-
Reduces minSDK to 22
-
Adds
purchaseToken
to purchase events -
Superwall.instance
now provides blocking or callback based version of multiple calls, suffixed with*Sync
-
Improves preloading performance and reduces impact on the main thread