-
Notifications
You must be signed in to change notification settings - Fork 26.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[in_app_purchase][android]: Add Google Play Offers support #110909
Comments
cc @GaryQian |
Hey @AlaaEddineCharbib It's nice that If your app supports the in-app purchase workflow(described in Making In-app Billing requests), your app automatically supports in-app redemption of promo codes. You'll only need to implement it for IOS, not need for Android |
Automatically you mean? It doesn't work for me, only takes one of the plans created: https://stackoverflow.com/questions/74599781/flutter-get-different-plans-from-subscription |
@danagbemava-nc do we know when will this be supported? Or a roadmap to know exactly how long I can delay my new subscriptions for? I can also create other subscriptions in my google play console in the meantime and later on, when this is supported create them as plans/offers but I will encounter 2 issues here:
I understand we are talking about different departments here (google play console, Flutter, etc.) but this will affect our earnings and TBH all these departments belong to the same company (I'm saying this because I had these problems already in the past with this and other libraries). This issue was created 3 months ago, there are people interested but again, we have an issue without responses from the team. So some extra info will be appreciated please |
@erperejildo, unfortunately, I cannot provide that information |
It has been almost 6 months trying to get the App Store fetches all the
But, the Play Store only retrieves Are there any updates on this issue? |
who should I get in contact with? Becase I was trying to create my new subscriptions but instead of creating 3 I'll have to create 6 with extra logic to detect plans within same subscriptions (because all of them will be separate and different subscriptions at the end). I could wait to see if this is going to be supported but not much since I'm going to lose money. So any way to get more information about this support? |
This comment was marked as off-topic.
This comment was marked as off-topic.
In my case, I needed this feature asap, so I just replaced the
But, I wondered how I could handle the new class(ProductDetails in BillingClient v5) with the previous class(ProductDetails in in_app_purchase_platform_interface). Since the Play Store announced the new model(multiple base plans inside the one-subscription, 1:N (Subscription: Base plans)), it was hard to wrap up the previous class(ProductDetails in in_app_purchase_platform_interface) with the new class(ProductDetailsWrapper). Here is the sample code below. /// Generate a [GooglePlayProductDetails] object based on an Android
/// [ProductDetailsWrapper] object.
factory GooglePlayProductDetails.fromProductDetails(
ProductDetailsWrapper productDetails,
) {
return GooglePlayProductDetails(
id: productDetails.productId,
title: productDetails.title,
description: productDetails.description,
price: productDetails.price ?? 'unknown',
rawPrice:
(productDetails.oneTimePurchaseOfferDetails?.priceAmountMicros ??
productDetails.subscriptionOfferDetails?.first.pricingPhases
.first.priceAmountMicros ??
0) /
1000000.0,
currencyCode:
productDetails.oneTimePurchaseOfferDetails?.priceCurrencyCode ??
productDetails.subscriptionOfferDetails?.first.pricingPhases.first
.priceCurrencyCode ??
'USD',
currencySymbol:
productDetails.oneTimePurchaseOfferDetails?.formattedPrice[0] ??
productDetails.subscriptionOfferDetails?.first.pricingPhases.first
.formattedPrice[0] ??
r'$',
productDetails: productDetails,
);
} And the getter String? get price =>
oneTimePurchaseOfferDetails?.formattedPrice ??
subscriptionOfferDetails?.first.pricingPhases.first.formattedPrice; The reason why I set the Are there any ideas for this migration? Here is my repository link which I'm working on. |
It's been six months, no support plan?😥 |
When should be expect this to be added? |
never wait for something like this guys. Specially if it affects your earnings |
Sunsets BillingClient v4 calls in favor of the new v5 calls. Changes mostly follow the [Migration guide](https://developer.android.com/google/play/billing/migrate-gpblv5). Besides solving several issues, this change is also required as [billing client v4 will be obsolete by August 2nd, 2023](https://developer.android.com/google/play/billing/deprecation-faq). `getProductDetails()` will now return both base plans and their offers for subscriptions. Before, it would only return subscriptions that were backwards compatible with billing client v4. Price changes for subscriptions seem to be handled by the Play Store now instead. Therefore, `launchPriceChangeConfirmationFlow()` has been removed, making this PR a breaking change. Context: * [Billing Client API](https://developer.android.com/reference/com/android/billingclient/api/BillingClient#launchPriceChangeConfirmationFlow(android.app.Activity,%20com.android.billingclient.api.PriceChangeFlowParams,%20com.android.billingclient.api.PriceChangeConfirmationListener)) * [Billing Client docs](https://developer.android.com/google/play/billing/subscriptions#price-change) This PR fixes the following issues: * Fixes [#110909](flutter/flutter#110909) * Fixes [#107370](flutter/flutter#107370) * Fixes [#114265](flutter/flutter#114265)
In the upgrade to billing client v5 in #3752, some method signature strings on the Java side were updated. Unfortunately, as the Dart side was not updated. This mismatch broke the interaction between the Dart and native Android code through the method channels. This PR updates the strings on the Dart side so the method invocation work correctly again. This is a follow-up to - flutter/flutter#110909 - flutter/flutter#107370 - flutter/flutter#114265
…4065) Bumps `in_app_purchase_android` to 3.0.0. This PR is the final step for closing flutter/flutter#110909.
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of |
Google Play introduced offers to subscriptions. but apparently there is still no support to this feature in the in_app_purchase plugin, or at least this is what I could conclude after going through the GooglePlayProductDetails and SkuDetailsWrapper codes.
For iOS it is possible to get the list of a product discounts using the AppStoreProductDetails' skProduct object.
is it possible to have such a thing for Android too?
The text was updated successfully, but these errors were encountered: