Member-only story

Flutter iap subscription config

Nhan Cao
2 min readDec 13, 2020

* The In-app product id should format: <package_id>_<type>_<number>. Ex: com.app.habitapp_yearly_000 (desc: Annual Subscription, Subscription Display Name: One year subscription, Description: Аll features of the app are available to you)

* The In-app product just works on real device

— — — — — — —

Mobile site

libs

# in app purchase
flutter_inapp_purchase:
git:
url: https://github.com/nhancv/flutter_inapp_purchase.git
in_app_purchase: ^0.3.4+16
shared_preferences: ^0.5.12+4

iOS

  • Setup your in app products for ios in itunesconnect.

+ You need to complete the Agreements, Tax and Bankings.

+ Add In-App Purchases in Features tab. Check that your product’s status is Ready to Submit.

  • Check your xcode setting and make In-App Purchase available.

Android

  • Add billing permission Android manifest
<uses-permission android:name="com.android.vending.BILLING" />

* The importance to debug purchases on android is use release signingConfig in debug build type. Google Play Billing APIs only works with apps signed for production.

buildTypes {
debug {
debuggable true
signingConfig signingConfigs.release
}
release {
signingConfig…

--

--

No responses yet