Miniwall Docs
Mobile SDK

Errors

Every error the SDK and its delivery API can produce, what causes it and how to fix it.

Where errors show up

CallLoad failuresOther errors
presentIt throws (iOS and Android), or the promise rejects with code miniwall_error (React Native and Flutter). Use try/catch.onError
Embedded screenonError; the view stays emptyonError
Auto placementsonErroronError
preloadSilent: a placement that fails is skippednone

API error codes

The delivery API answers errors as { error: { code, message } }. The SDK throws Miniwall: followed by the message.

StatuscodeMessageCause and fix
401invalid_keyMissing or invalid public keyThe key is missing, mistyped, revoked, or not a pk_ key. Copy it from API keys.
404not_foundPlacement not foundThe key matches no placement. Check spelling and the project.
404not_foundPaywall not foundThe placement has no screen chosen.
404not_foundPublished paywall not foundThe screen was never published (or was deleted). Publish it.
400bad_requestBody must be JSON, or a field messageAn events request was malformed. Not caused by normal use.
429rate_limitedToo many events, slow downMore than 1200 events a minute on one key. Events are dropped.
500internalSomething went wrong on our side. Try again.Server fault. A saved copy is used if there is one.

A 5xx answer, a network failure or a timeout uses the saved copy when one exists. A 4xx answer is never replaced by a copy. Apps send no origin, so the web's origin_not_allowed error does not apply.

Messages thrown by the SDK

MessageCause and fix
Miniwall: call Miniwall.configure(apiKey:) before loading a placement (iOS), ... configure(context, apiKey) ... (Android)Call configure first.
Miniwall: the screen took too long to loadNo answer within the timeout and no saved copy.
Miniwall: could not load the screen (STATUS)A non-OK answer with no message.
Miniwall: not a screen JSON (expected components_config.base.stack)A JSON source does not hold a screen.
Miniwall: screen ID is not a screen JSONA linked screen's JSON is not a screen.
Miniwall: screens[ID] is not a screen JSONA JSON you passed in screens is not a screen.
Miniwall: screen ID could not be loadedA linked screen failed to load. It is retried on the next tap. Sent to onError.
Miniwall: pass onPurchase in PresentOptions to handle purchase buttonsA purchase button was tapped with no onPurchase. Sent to onError.
Miniwall: not opening "...": only http(s), mailto and tel links openA link with another scheme was refused. Sent to onError.
Miniwall: present needs a source (placement, paywallId or json)React Native or Flutter was called without a source.
Miniwall: present needs an ActivityAndroid: pass a live Activity to present.
Miniwall: no StoreKit product for package IDiOS: storeKitPurchase has no product for the tapped package.
Miniwall: the App Store could not verify the purchaseiOS: the StoreKit transaction was not verified.

On this page