Releases: idehub/react-native-billing
Upgraded to new APIs for RN, Gradle and the wrapped IAB lib
What’s Changed
Lots of thanks to the contributors!
- Upgrade to google play developer api v3 (#166) @superandrew213
- Use react-native.config.js (#163) @superandrew213
- fix typo in README.md (#141) @schumannd
- upgrade for gradle build (#1) @pengcao1
- Update RN min. version on Readme (#139) @Guitarrist
Minor release to allow override of SDK versions
Fix for RN 0.56+ and newer SDKs + Gradle versions.
Available overrides:
compileSdkVersion
buildToolsVersion
minSdkVersion
targetSdkVersion
reactNativeVersion
anjlabIABVersion
The final one (anjlabIABVersion
) is if you want to attempt to use other versions than the default version for https://github.com/anjlab/android-inapp-billing-v3 (which is the lib we wrap).
Add autoRenewing flag on transaction details
This release adds an autoRenewing
flag that should help you check cancelled subscriptions.
Call InAppBilling.getSubscriptionTransactionDetails(productId)
and check the details.autoRenewing
flag. It will be set to false
once subscription gets cancelled. Also notice, that you will need to call periodically InAppBilling.loadOwnedPurchasesFromGoogle()
method in order to update purchase/subscription information from the Google-servers.
Major release for RN 0.30+
Since we're implementing ActivityEventListener
we need to override onNewIntent
for RN 0.30+.
This is not backwards-compatible, and hence a major release.
Minor release for RN 29.2 and lower
Thanks to @c-h- for his contributions on this release!
Developer payload for purchase and subscribe
Now the purchase
and subscribe
functions allow an optional developerPayload
string parameter. This value will roundtrip from in the process, and be returned as part of the transactionDetails
.
Thanks to @grabbou for his PR providing this feature!
More transaction details
Added two new methods pertaining to retrieving transaction details after purchase/subscriptions;
- getPurchaseTransactionDetails(productId)
- getSubscriptionTransactionDetails(productId)
Both of these will return the same transaction details as when you did a purchase or subscription. This will allow you to re-check details at a later point.
Thanks to @thstarshine for his cleaned up PR of my pseudo-code!
isPurchased + more
Added three new methods:
- isPurchased(productId)
- returns
boolean
- returns
- listOwnedProducts()
- returns list of productIds
- listOwnedSubscriptions()
- returns list of productIds
Rewrite of module, more features
Very heavily rewrite of module which will introduce open and close methods, which can be used to open/close the Google Play service channel. This will hopefully fix the app crashes.
Also implemented more features from the anjlab library, including onActivityResult (the RN way through ActivityEventListener, and subscription-methods.