flutterpayment-gateway

Adapty Flutter Error - Paywall with variation <####variationId####>, locale en and builder_version 2 does not exist


I've installed Adapty and AdaptyUI in my Flutter app. I tried to show the paywall as following

final paywall = await Adapty().getPaywall(placementId: <placement-id>);
final view = await AdaptyUI().createPaywallView(paywall: paywall, locale: "en");
await view.present();

The first line works and I get value inside paywall variable. But the next line where I call createPaywallView throws the following error:

Request is unsuccessful. https://api.adapty.io/api/v1/sdk/in-apps/public_live_########/paywall-builder/<variationId>/<######>/ Code: 404, Response: {"errors":{"non_field_errors":["Paywall with variation <variationId>, locale en and builder_version 2 does not exist."]},"status_code":404}

Why is this happening and how do I fix this?


Solution

  • The solution is simple, it is clearly mentioned in Adapty to use Legacy Paywall builder for android platforms. so if you are using the new builder and testing your app in android devices, try building the paywall using Legacy builder. hope it helps.