Closed Dizmus closed 8 months ago
Subscription Trial Length: 3 days
Previously we used the following approach:
Unfortunatelly Google got rid of it :( you have to parse it yourself: https://stackoverflow.com/questions/72632982/how-to-get-freetrialperiod-of-subscribtion-from-productdetails
The problem is that in AndroidExtras there is only one OfferDetails with one Pricing Plan, which is the length of subscription.
Do you mean I need to use native API to retrieve product details?
On Tue, Oct 3, 2023 at 9:13 PM James Montemagno @.***> wrote:
Unfortunatelly Google got rid of it :( you have to parse it yourself: https://stackoverflow.com/questions/72632982/how-to-get-freetrialperiod-of-subscribtion-from-productdetails
— Reply to this email directly, view it on GitHub https://github.com/jamesmontemagno/InAppBillingPlugin/issues/558#issuecomment-1745484192, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABMAEK27MISNNXWX4ZAJVODX5RIVRAVCNFSM6AAAAAA5PWKGQCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONBVGQ4DIMJZGI . You are receiving this because you authored the thread.Message ID: @.***>
-- Best Regards Ilya Grishkevich
@jamesmontemagno , thanks, now I got it. Google doesn't send information about trial offer if user is not eligible for it. So, basically, there is no way to get trial length is user has already purchased a subscription
Bug Information
Version Number of Plugin: 7.0.5 Device Tested On: Google Pixel 7 Pro Simulator Tested On: Version of VS: VS for Mac Version of Xamarin: Xamarin.Android - Version: 13.2.1.2 Versions of other things you are using:
Steps to reproduce the Behavior
Install Plugin.InAppBilling to Android application (Xamarin or MAUI) Try to retrieve FreeTrialPeriod Length
Expected Behavior
InAppBillingProductAndroidExtras contains information about Trial Length
Actual Behavior
subscriptionOfferDetail.BasePlanId and PricingPhase.BillingPeriod contains about the subscription itselft
Code snippet
InAppBillingProductAndroidExtras inAppBillingProductAndroidExtras = inAppBillingProduct.AndroidExtras; var subscriptionOfferDetail = inAppBillingProductAndroidExtras.SubscriptionOfferDetails.SingleOrDefault();
Screenshotst