Integrate Helium into your Flutter App
flutter pub add helium_flutter
or manually add the helium_flutter package to your pubspec.yaml:
ios/Podfile
with:
HeliumCallbacks
interface. This class is responsible for handling the purchase logic for your paywalls.
HeliumTransactionStatus
enum defines the possible states of a paywall transaction:
HeliumCallbacks
interface:
main.dart
or your root widget), add the following to download paywall configurations:
initialize
method or by explicitly calling overrideUserId
:
"notDownloadedYet"
: The download has not been initiated or is still in progress."downloadSuccess"
: The download was successful."downloadFailure"
: The download failed.presentUpsell
method:
trigger
parameter is a unique identifier for the paywall trigger point in your app. Helium uses this to track and optimize the paywall for each trigger point.
HeliumFlutter.getUpsellWidget
method to embed a paywall directly in your widget tree:
presentUpsell
method:
HeliumCallbacks
implementation: