Concepts

Debugging

Turn on SDK logging and diagnose a blank ad slot.

The SDK is deliberately quiet: if something is misconfigured, an ad slot just stays empty — it never throws into your app. When an ad isn't showing, the first step is always to turn on logging.

Enable logging

Logging is off by default on every platform. Switch it on during development, and leave it off in release builds.

Koah(context) {
    publisherId = "YOUR_PUBLISHER_ID"
    logLevel = KoahLogLevel.DEBUG
}
// Logs to Logcat — filter by the "Koah" tag.

With logging on you'll see the SDK initialize and report failed requests with their HTTP status. Exactly what each level emits varies by platform — see your SDK's debugging or reference page.

Debug inspector (iOS)

On iOS you can attach an in-app inspector — a floating overlay with Network, Config, and Logs tabs — by adding the .koahDebugInspector() modifier to a root view. The floating inspector shows whenever the modifier is present, so wrap it in #if DEBUG to keep it out of release builds.

YourRootView()
    #if DEBUG
    .koahDebugInspector()
    #endif

Testing with a demo key

Real-inventory fill rate is never 100%, so a production publisher key can legitimately return no-fill. In a debug build, the SDK detects this and logs a boxed warning pointing at demo keys. For reliable local testing where every request fills, use a demo key.

Why isn't my ad showing?

Work down this list with logging enabled:

  1. Initialization. Make sure you initialize Koah once (with the correct publisher ID) before the first ad renders. The logs should show /k/init succeeding.
  2. No-fill on a production key is normal — switch to a demo key to confirm the integration end-to-end.
  3. Slot too tight. A slot whose bounds exclude every ad format renders nothing. Loosen or unbound an axis — see formats.
  4. React Native only: confirm KoahBrowserModal is mounted and the required peer dependencies (including react-native-webview) are installed — a missing peer degrades silently.
  5. Custom base URL. A typo'd or unreachable baseUrl fails every request. Leave it unset to use production.
Was this helpful?