Billing
Configure your in-app products and subscriptions.
info
We recommend completing this setup once you have finished adding your features and testing. Or if you don't want to use in-app purchases or subscriptions you can skip this section completely.
Setup Play Console
- Go to Play Store and create a developer account.
- Go to the Google Play Console and create a new app.
- Release the app to the internal test track. (Follow the release steps but select the internal test track instead of production)
Connect RevenueCat with Play Console
- Go to the RevenueCat Dashboard and create a new project.
- Add a new Android app to the project
- Follow the steps to connect RevenueCat with the Play Console.
- Follow RevenueCat steps to create your in-app products and subscriptions.
- Copy the Android's
Public API Keyfrom RevenueCat. - Go to the Firebase Console / Build / Remote Config and add the following keys:
REVCAT_API_KEY_ANDROIDwith the value of the AndroidPublic API Keyfrom the previous step.
Map your RevenueCat products in the app
-
Open the
shared/src/commonMain/kotlin/com/zenithapps/mobilestack/model/Product.ktfile. -
Rename
STARTERandALL_INto your products including theirpackageId(from RevenueCat/Offerings/Packages/Identifier) andentitlement(from RevenueCat/Entitlements/Identifier).enum class Product(val packageId: String, val entitlement: String) {
YOUR_PRODUCT_NAME("YOUR_PRODUCT_PACKAGE_ID", "YOUR_PRODUCT_ENTITLEMENT"),
...
OTHER("other", "other")
} -
Create a paywall in Revenue Cat with the same entitlement as the product.