SDK docs 0.1.0 preview
ContentsOverview
0.1.0 preview. You install 0.1.0 from Maven Central and NGA's public repositories. Every 0.x version is a preview under the NGA SDK License, and the API can change until 1.0. Questions: hi@nga.network.

Guide

NGA SDK 0.1.0

View as Markdown

Promote your own games inside your games, for free, and show NGA's full-screen ad when your mediation has nothing to show. One SDK for Unity, Android and iOS.

What 0.1.0 does #

  • Cross-promotion of your own games. Every game of yours with Shows cross-promo on shows your other games whose Promoted switch is on, for free.
  • Install and retention reporting. NGA reports the impressions, clicks and installs each promotion brings, and the day-1 and day-7 retention of those installs. If you use AppsFlyer or Adjust, NGA can report to them too.
  • The game's own signals. Sessions are recorded with no extra code, and so are Google Play Billing and StoreKit 1 purchases and the ad revenue of AppLovin MAX and Unity LevelPlay. StoreKit 2 and Unity IAP 5 purchases need one call each, and Google AdMob one call per paid event. See Revenue and purchases.

Two cross-promo formats #

Native banner. On a screen with nothing else at the bottom (for example, game over), the SDK slides up a banner with the promoted game's icon, name and one line of text. The banner uses your game's colors, and a tap opens the store. Call close() before you show anything else at the bottom; your own banner ad steps aside by itself once you register the banner yield. You do not place, size or track the banner yourself. See Native cross-promo.

Full-screen backfill. When your mediation (AppLovin MAX, Unity LevelPlay or Google AdMob) fails to load an interstitial or rewarded ad, load NGA's. When it is time to show the ad, show NGA's only if the mediation still has nothing. Your code decides, and the SDK never loads ahead of a mediation failure, so NGA never takes an ad your mediation could fill. See Full-screen backfill.

NGA's server decides which of your games fills each placement. Your code only loads a placement and shows what comes back.

Two libraries #

The SDK is two libraries, released together at one version.

Library Add it when What it adds
nga-sdk, the core library always NGASDK.initialize, consent and age, sessions, purchases, ad revenue from your mediation, and the types of the ad surface
nga-sdk-render, the render library your game shows NGA ads the ads themselves: the native banner, interstitial and rewarded

Without the render library, ad calls return RENDER_NOT_AVAILABLE; everything else works. You can add it later, at the same version, without changing initialize. Your code always talks to one class, NGASDK. Package names for each engine: Install.

Every game needs the SDK #

Add the SDK to every game you promote, not only to the game that shows the ad. A game that shows no NGA ads needs only the core library. A tap opens the store directly, and NGA counts the install when the promoted game first starts. To send these installs to your MMP too, give NGA its click and impression URLs. See Attribution.

Requirements #

Minimum
Android API 23 (Android 6.0)
Kotlin (Kotlin apps only) compiler 1.8 or later; the libraries bring kotlin-stdlib 1.9 or later. Java apps are unaffected
iOS iOS 15.0; Xcode 26 or later
Unity Unity 2022.3 LTS or later, building for Android, iOS or both

Your mediation SDK may need more:

  • AppLovin MAX 13 and Google Mobile Ads 25: Android API 24.
  • Google Mobile Ads 25.5: a Kotlin 2.2 or later compiler in a Kotlin app.
  • Google Mobile Ads for iOS 13.4 and later: Xcode 26.2.

Not in 0.1.0 #

  • Standard banner ads (320 × 50 and the like), app-open ads, playable ads, and ads for anything other than your own games.
  • Mediation adapters: NGA is not a network inside MAX, LevelPlay or AdMob. Backfill is your own code; see The rule.
  • Promoting a game that does not carry the SDK.
  • Server-side reward verification. The reward is decided on the device; see Rewarded.
  • A "more games" hub, and rewards for installing the promoted game.
  • Engines other than Unity: no Cocos, Godot, Flutter or Unreal wrapper.
  • iOS apps in the App Store's Kids Category.
  • Banner text in languages other than English; see Players who should not see it.
  • An API to log your own custom events.

The preview #

0.1.0 is the release, not a release candidate. Under the NGA SDK License it is a preview version, as every 0.x version is. For now:

  • These pages install 0.1.0. See Install.
  • NGA approves your studio's sign-up in the portal by hand. Everything else in the portal is yours to do. See Set up in the portal.
  • The API can change until 1.0. The changelog carries the migration notes and the support terms.

Questions at any step: hi@nga.network.

Start here #

The portal first, then the code. A new studio starts at portal.nga.io/sign-up. Choose your engine on any page; the choice holds everywhere. These sections are the path; the rest of each page is there when you need it.

  1. Portal: Sign up, Register a game, Placements. Copy the app key and placement ids.
  2. Code: Install; on Initialize, Where to call it, The app key and The answer; then Consent, and Age and audience for a Mixed game. Or hand it to a coding agent.
  3. The format:
  4. Test and release: Test mode, Register a test device, The log, Checklist; then the release checklist and the store privacy forms.

Unity adds Unity build checks when a build fails; iOS adds App Tracking Transparency; Android adds nothing.

Read when you need them: Calls before initialize, Calling initialize again, Log level, Threads, Show lifecycle, One ad per placement, Attribution, Revenue and purchases, Troubleshooting.