Skip to content

6.2.0

Latest

Choose a tag to compare

@kherembourg kherembourg released this 08 Oct 14:37

6.2.0

Added

  • Custom events. Send a business event from your app with Purchasely.emit(name, properties). A custom event declared in the Console can trigger a campaign and can measure a campaign, a flow or an A/B test. A screen can also send a custom event with the new "Track event" action. The name must match the Console declaration exactly. Supported property types: Int, Long, Float, Double, Boolean, String, Date and a list of String.
  • New built-in attributes ply_active_subscriptions and ply_expired_subscriptions. Each one is a list of the user's subscriptions, so you can target an audience on the details of a subscription.
  • PLYPlan.dump() returns a full text report of a plan and of its Google Play product. Use it to debug a price, a period or an offer, and attach it to a support request.

Changed

  • Source compatibility: PLYEvent has a new subclass. If your code uses when (event) on PLYEvent without an else branch, add an else branch.
  • Source compatibility: StoreType.WEB_CHECKOUT_STRIPE is now StoreType.STRIPE.
  • Source compatibility: PLYPurchaseResponse.expiredSubscriptions is now nullable. null means that the answer says nothing about expired subscriptions.
  • A paywall fetch without an API key now fails with PLYError.Configuration instead of PLYError.Network. The SDK sends no request.
  • When the configuration request fails at start, the error keeps the real HTTP status code.
  • A Google Play network error during a purchase now ends the purchase without an alert. Your onError callback receives the network error.
  • The SDK starts faster when the user has a long subscription history.
  • Media3 update to 1.11.1 in the player module.

Fixed

  • The SDK no longer reports "In-app purchase failed" events when no purchase is in progress.
  • The callbacks of purchase(), restoreAllProducts() and silentRestoreAllProducts() now answer only the call that started them.
  • A paywall no longer freezes after two purchase attempts that end with the same result.
  • The SDK keeps a subscription whose plan is not in the app catalog (for example a web subscription).
  • A login now transfers the subscriptions that the user bought or redeemed while anonymous, and tries a failed transfer again at the next login.
  • The subscription built-in attributes now reset when the user has no active or no expired subscription.
  • An inline paywall (buildView) no longer sends a Close action when its host screen goes away. PLYInterceptorInfo.presentation is now set for the Close action.
  • On Android TV, the paywall now works with the remote control (D-pad).
  • Purchasely.closeAllScreens() now closes all stacked screens.
  • onOpenPresentation and onOpenPlacement now run once per action.
  • presentation.metadata is no longer lost on a full-screen paywall.
  • Each public callback API now calls one callback only, also when your success callback throws an exception.
  • Purchasely.setAttributes() accepts an empty map.
  • getBuiltInAttribute() no longer returns an internal backend key.
  • A deeplink with an upper-case PLY host now opens.
  • A countdown label that shows only months now refreshes.
  • In dark mode, an image with an empty dark URL now uses its light URL.
  • retrieveLogs() now keeps the last 200 lines.
  • A property with a NaN or infinite number inside a list or a map no longer causes the loss of the full request.
  • The SDK reports one result when the last receipt validation request fails.
  • A paywall purchase button no longer stays blocked after an error that shows no alert.
  • A paywall shows its prices sooner after a configuration refresh.
  • A flow sheet or modal no longer crashes or closes when a late dismiss or navigation request arrives.

Full changelog: 6.1.1...6.2.0