2

#in_app_purchase I'm using in_app_purchase in my flutter app. https://pub.dev/packages/in_app_purchase Firstly I was using RevenueCat services for my IAP services but due to the unavailability of purchase tokens from Revenue Cat. I decided to use flutter official's in_app_purchase. Apparently in this approach when I query for all my products from Google Play. The program is stuck at

InAppPurchase.instance.queryProductDetails();

method and isn't giving any response. Not even an error. I have also initiated the InAppPurchase instance but still, it's getting me the issue. Can anybody please help figure this out?

1 Answers1

3

I was battling against the same problem and finally found the solution.

This part needs to be removed from the app-level build.gradle file in order for in_app_purchase to work properly. Once I removed these two lines, everything worked flawlessly.

def billing_version = "4.0.0"
implementation "com.android.billingclient:billing:$billing_version"

This it terribly misleading, since the in_app_purchase package links to the "Getting started" guide for Google Play, which explicitly says to add these two lines.

Ronald Blüthl
  • 136
  • 1
  • 5