setFallback method

Future<void> setFallback(
  1. String assetId
)

To set fallback paywalls, use this method. You should pass exactly the same payload you’re getting from Adapty backend. You can copy it from Adapty Dashboard.

Adapty allows you to provide fallback paywalls that will be used when a user opens the app for the first time and there’s no internet connection or in the rare case when Adapty backend is down and there’s no cache on the device. Read more on the Adapty Documentation

Parameters:

  • assetId: a path to the asset file with fallback paywalls.

Implementation

Future<void> setFallback(String assetId) {
  return _invokeMethod<void>(
    Method.setFallback,
    (data) => null,
    {
      Argument.assetId: assetId,
    },
  );
}