Skip to main content

· 2 min read

If you're using IAPHUB webhooks, a new major version (v2) is available.

This new version introduces the new transfer webhook.

The transfer webhook will be triggered when an active subscription (or non-consumable) is transferred to a different user ID.

This can occur when a user restores their purchases or replaces an active subscription using a different user ID, but only if the User transfer option on the IAPHUB dashboard is enabled, which is the default setting.

Our goal is to make things easier compared to the previous system (v1), which relied solely on the user_id_update webhook.

We recommend updating to the new version as soon as possible. Let's recapitulate the differences between the v1 and the v2:

Before (v1)

The user_id_update webhook is triggered in the following scenarios:

  • When a user restores an active subscription (or non-consumable) using a different user ID.
  • When an active subscription is replaced using a different user ID.
  • When an anonymous user (not logged in) with purchases logs in.
  • When the user ID of a user with purchases is updated via the API.

Now (v2)

The user_id_update webhook is triggered when user ID 1 becomes user ID 2.

It can happen in the following scenarios:

  • When an anonymous user (not logged in) with purchases logs in.
  • When the user ID of a user with purchases is updated via the API.

The transfer webhook is triggered when a subscription (or non-consumable) is transferred from user ID 1 to user ID 2.

It can happen in the following scenarios:

  • When a user restores an active subscription (or non-consumable) using a different user ID.
  • When an active subscription is replaced using a different user ID.

How to upgrade?

Once your server can handle the transfer webhook properly, you can update the webhooks version from the Settings page of the IAPHUB dashboard.

Click on the Webhooks section, update the Webhook version input to version 2, and click on the Save button.

If any issue happens, you can still rollback to version 1.

· One min read

A new property (subscriptionCancellationDate) is now available through the API & webhooks. It is the date IAPHUB detects a subscription auto-renewing has been cancelled.

You can find more information on the documentation.

· One min read

Exciting news for Flutter developers! The IAPHUB SDK for Flutter is now available, providing an easy and user-friendly solution for in-app billing implementation for your iOS/Android apps.

Say goodbye to the frustration of understanding the StoreKit framework and the Google Billing Library, and the time and effort required to develop a server for managing subscriptions, processing receipts, and handling edge cases. With the IAPHUB SDK, you can effortlessly implement in-app billing without having to reinvent the wheel.

Implementing IAPHUB in your Flutter app has never been easier. Simply follow our comprehensive guide that will take you step by step through the process.

· 2 min read

IAPHUB is thrilled to announce that we are now available on Adalo!

We understand that one of the biggest challenges facing app developers is figuring out how to monetize their creations. That's why we're dedicated to making in-app purchases as easy and accessible as possible.

With our new components on Adalo, we're confident that thousands of people who may not have coding experience will now be able to develop their own mobile apps and monetize them. Adalo is a powerful platform that allows anyone to create professional, polished mobile apps without needing to write any code. With IAPHUB integrated into Adalo, users can now easily add in-app purchases to their apps, making it simple to generate revenue from their creations.

Adalo users will finally be able to unlock a whole new realm of monetization options by being able to sell subscriptions or consumables within their apps. For example, with IAPHUB integration, Adalo users can now easily create paywalled content that is only available to users with a subscription. This opens up a whole new world of possibilities for app creators looking to generate revenue from their creations, whether it be through recurring subscription fees or one-time consumable purchases. The sky truly is the limit with the added capabilities that IAPHUB brings to Adalo.

We're excited to see what kinds of amazing apps people will create using our components on Adalo. Whether you're a seasoned developer or a complete beginner, we believe that our tools will help you take your app to the next level.

Get started now by taking a look at the comprehensive guide we've prepared for you.

· 2 min read

We're happy to announce the release the version 8.4 of the React Native plugin.

This new release has quite a few enhancements and a new method getBillingStatus that has been added in order to easily detect an error with the billing system.

When the billing system is unavailable, the products for sale will be filtered and an empty array will be returned.
You can use the getBillingStatus method (after fetching the products) to detect when it is the case in order to display the appropriate error message.

On Android, we also recommend displaying an error message when the billing system is unavailable because the Google Play Store app is outdated (it can happen on old devices with an outdated software). Tell the user to open the Play Store app and go to Settings -> About and click on Update Play Store.

If the getBillingStatus method doesn't return any error but your product is missing, it is most likely a misconfiguration issue.

You should check the filteredProductIds property.
If your product ID is in the array, it is an issue with GooglePlay/iTunes (we are relying on them to fetch the products details). Otherwise it is an issue with IAPHUB. Please follow this guide to walk through the different possibilities that could cause this issue.

var status = await Iaphub.getBillingStatus();

if (status.error && status.error.code == "billing_unavailable") {
if (status.error.subcode == "play_store_outdated") {
// Display a message on your paywall saying that the Play Store app on the user's device is out of date, it must be updated
else {
// Display a message on your paywall saying that the in-app billing isn't available on the device

if (status.filteredProductIds.length) {
// Some products have been filtered because they were not returned by GooglePlay/iTunes


· 2 min read

We're happy to announce the release the version 8.3 of the React Native plugin.
This new release is shipping some really helpful features!

What's new?

A new onDeferredPurchase event

Thanks to this event you'll now be able to easily detect when a new purchase occurs outside of the buy method.
For instance this event can be trigerred:

  • After a purchase is made outside the app (by redeeming a promo code on the store by example)
  • After a deferred payment (when the error code 'deferred_payment' is returned by the buy method)
  • After a payment fails because it couldn't be validated by IAPHUB (and succeeds later)
  var listener = Iaphub.addEventListener('onDeferredPurchase', async (transaction) => {


The enhancement of the restore method

The restore method will now return a RestoreResponse object.
This object will contain two properties:

  • newPurchases: The new purchases processed during the restore
  • transferredActiveProducts: The active products transferred (from another user) during the restore
var response = await Iaphub.restore();
// New purchases
console.log('New purchases: ', response.newPurchases);
// Extisting active products transferred to the user
console.log('Transferred active products: ', response.transferredActiveProducts);

New properties for the ActiveProduct object

We've also added a few extra properties for the active products.

  • isPromo
  • promoCode
  • originalPurchase


· One min read

As you know we're on a mission to make in-app purchase as easy as possible.
The react-native-iaphub is already doing that pretty well but we've decided to make things even easier!

Our new React Native component react-native-iaphub-ui will now provide all the UI necessary to sell in-app purchases!
You'll be able to display a beautiful paywall that is highly customizable and includes (so far) the translations in 6 languages (English, Spanish, French, German, Portuguese, Japanese).

Here is a little preview of the component (the image and title isn't part of the component):

The usage of this component is of course totally optional but we're sure it'll help a lot of developers trying to deploy in-app purchases fast. The development of a great paywall takes a lot of time 🙂.

· One min read

IAPHUB will now send the iOS/Android promo code the user used during a purchase!

The new promoCode property will be sent on a purchase webhook or when fetching a purchase from the API.
And the promo code will also be displayed on the IAPHUB dashboard when clicking on a transaction.

Google only returns the promo code for subscriptions vanity codes (not available for one time codes).

Also for iOS the promoCode property will contain the offer reference name you've provided when creating a promo code on iTunes.

· 3 min read

A major update has been pushed! 🥳

The iOS & Android SDKs have been upgraded to v3, and the react-native-iaphub library to v8, we recommend updating the library to the latest version.

The big change is that our Android SDK is now using the Google Play Billing Library version 5!

What's new with the Google Play Billing Library version 5?

You might have noticed Google released some new features in May 2022 (Google documentation).

Basically everything got a little more complex in order to offer new features (but fortunately you have IAPHUB to make things a little easier for you).

In short:

  • A subscription product has now the possibility to have multiple offers.
  • Each offer has the possibility to offer multiple intro phases (up to 2).

What's the changes in the SDK update?

Multiple offers

If you have multiple Android offers, the oldest (first one you've created) will be used by default. We've decided to not support multiple Android offers in order to have a common system with iOS.

To have a different offer simply create a new product, you can do pretty much everything with smart listings.

Multiple intro phases

Since Android now supports multiple intro phases (you can now for example offer a free trial followed by an introductory price), we had to change our API which is why it is a major update, but updating the library should be pretty easy.

So what's the differences with the new API? The following properties have been removed:

  • subscriptionIntroPrice
  • subscriptionIntroLocalizedPrice
  • subscriptionIntroPayment
  • subscriptionIntroDuration
  • subscriptionIntroCycles
  • subscriptionTrialDuration

Instead you'll have a property subscriptionIntroPhases that is an ordered list containing the intro phases the user is eligible to.

So for instance, if you create 2 intro phases: a free trial of 1 month followed by an introductory price of $4.99 for 3 months, the subscriptionIntroPhases property will contain the following:

type: "trial",
price: 0,
currency: "USD",
localizedPrice: "FREE",
cycleDuration: "P1M",
cycleCount: 1,
payment: "upfront"
type: "intro",
price: 4.99,
currency: "USD",
localizedPrice: "$4.99",
cycleDuration: "P1M",
cycleCount: 3,
payment: "as_you_go"

And also if the user isn't eligible to any intro price/trial, the array will be empty (or null if it isn't a subscription). Easy right?

We're here to help

If you have any questions or issues upgrading the library to the latest version, you can of course contact us at [email protected].