Skip to content
NuxieNuxie
Esc
↑↓navigate↵open⌘Jpreview
Open Nuxie
On this page

Connect with Unity

Connect a Unity mobile game and verify a published Experience in an iOS or Android player.

The Unity SDK displays Nuxie Experiences above your game and provides a C# client for events, purchases, and feature access. Publish or update an onboarding flow or paywall without rebuilding the game. Use Unity 6000.3.24f1 with iOS and Android Build Support, iOS 15+, or Android API 25+ with IL2CPP arm64.

Installation

Installation

From the Unity SDK checkout, prepare the package:

python3 scripts/prepare-native.py
python3 scripts/pack.py

In Window → Package Manager → Install package from tarball, select com.nuxie.unity-0.2.0.tgz. You can also open the repository’s ExampleProject.

The package includes Android artifacts and adds the Swift package on iOS export. Install the prepared tarball, not the repository root.

Initialize

Initialize

Copy your app’s public keys from Connect your app. Use pk_test_ keys in development builds and pk_live_ keys in release builds. Keep the default service environment for both; the key selects preview or live content.

Configure once from startup code on Unity’s main thread:

using Nuxie.Unity;

await Nuxie.Client.ConfigureAsync(new NuxieOptions {
    IosApiKey = "YOUR_IOS_PUBLIC_KEY",
    AndroidApiKey = "YOUR_ANDROID_PUBLIC_KEY"
});

Await setup before calling the client. Inspector-based projects can use a Nuxie Settings asset and Nuxie Bootstrap. The session continues across scene changes.

Run your app on a device or simulator. Connect your app shows Connected after Nuxie receives a request from the SDK.

Trigger an Experience

Trigger an Experience

Publish an Experience for this app with the event trigger integration_test. Set its re-entry rule to Every time if you want to show it repeatedly while integrating. Add this call to a button handler after setup:

await Nuxie.Client.TriggerAsync("integration_test");

Tapping the button sends the event. Nuxie displays the Experience when the customer matches its audience and delivery rules. For an existing Experience, replace integration_test with its published event name.

Connect your app changes to Shown after the SDK reports that the Experience appeared. For games, run this in an iOS or Android player or export. Your game controls pause, audio, and input while the Experience is visible.

Update an Experience

Update an Experience

Edit the Experience and publish your changes. Bring the app back to the foreground to fetch the update, then send the event again with a customer who can re-enter. New Journeys use the updated version; a Journey already in progress keeps the version it started with. The app code stays the same.

See the SDK reference for identity, feature access, and App Actions. Delivery explains trigger and audience configuration.

Last updated on

Was this page helpful?