launch

fun launch(offering: Offering? = null, fontProvider: ParcelizableFontProvider? = null, shouldDisplayDismissButton: Boolean = DEFAULT_DISPLAY_DISMISS_BUTTON, edgeToEdge: Boolean = defaultEdgeToEdge, customVariables: Map<String, CustomVariableValue> = emptyMap())

Launch the paywall activity.

Parameters

offering

The offering to be shown in the paywall. If null, the current offering will be shown.

fontProvider

The ParcelizableFontProvider to be used in the paywall. If null, the default fonts will be used. Only available for original template paywalls. Ignored for v2 Paywalls.

shouldDisplayDismissButton

Whether to display the dismiss button in the paywall. Only available for original template paywalls. Ignored for v2 Paywalls.

edgeToEdge

Whether to display the paywall in edge-to-edge mode. On versions below Android 15, edge-to-edge is enabled only if this is set to true. On Android 15 (API 35), edge-to-edge is enabled by default, so this parameter has no effect unless the app has opted out via the manifest. On Android 16+ (API 36), edge-to-edge is enforced by the system and cannot be disabled.

customVariables

Custom variables to be used in paywall text. These values will replace {{ custom.key }} or {{ $custom.key }} placeholders in the paywall configuration.