Hi folks,
Iām building an Android app and trying to have 2 paywalls presented (that I have configured in Revneuecat) - one for when user is in trial period and one when trial is over.
I'm trying to launch PaywallActivity with a specific offering in RevenueCat SDK 9.0.0, but it always shows the "current" offering from the dashboard instead of the offering I specify.
*** Here is our code:
```java
// BillingManager.java - Method to launch paywall with specific offering
public void launchPaywall(String offeringIdentifier, BillingCallback callback) {
// First get the offering object
Purchases.getSharedInstance().getOfferings(new ReceiveOfferingsCallback() {
@Override
public void onReceived(Offerings offerings) {
Offering targetOffering = offerings.get(offeringIdentifier);
if (targetOffering != null) {
// Launch PaywallActivity with specific offering
Intent intent = new Intent(currentActivity, PaywallActivity.class);
intent.putExtra("offering_identifier", targetOffering.getIdentifier());
currentActivity.startActivity(intent);
}
}
@Override
public void onError(PurchasesError error) {
// Handle error
}
});
}
``*** What I'm seeing in our app logs
```
D š Fetching offering: trial-offer
D ā
Offerings received successfully
D š Available offerings: [trial-offer, full-offer]
D šÆ Found offering 'trial-offer': YES
D š¦ Offering details:
D - Identifier: trial-offer
D - Packages: 3
D - Server description: Trial Purchases
D ā
PaywallActivity launched with offering: trial-offer
```
*** Problem
Even though the logs show I'm correctly finding and passing the `trial-offer` offering, the PaywallActivity that opens always shows my `full-offer` paywall (which is set as "current" in the RevenueCat dashboard).
*** Questions
1. **Is PaywallActivity supposed to respect intent extras for offering selection in SDK 9.0.0?**
2. **What's the correct way to launch paywalls with specific offerings in SDK 9.0.0?**
3. **Should I be using PaywallDialog or PaywallActivityLauncher instead?**
*** Setup
- RevenueCat SDK: 9.0.0
- RevenueCat UI: 9.0.0
- Platform: Android (Java)
- Two offerings configured: `trial-offer` and `full-offer`
Any guidance on the proper approach would be appreciated!
Thanks,
Prem