Nojoom 1.0.7

dotnet add package Nojoom --version 1.0.7
                    
NuGet\Install-Package Nojoom -Version 1.0.7
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Nojoom" Version="1.0.7" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Nojoom" Version="1.0.7" />
                    
Directory.Packages.props
<PackageReference Include="Nojoom" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Nojoom --version 1.0.7
                    
#r "nuget: Nojoom, 1.0.7"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Nojoom@1.0.7
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Nojoom&version=1.0.7
                    
Install as a Cake Addin
#tool nuget:?package=Nojoom&version=1.0.7
                    
Install as a Cake Tool

Nojoom Lifestyle SDK for .NET MAUI

Official .NET MAUI bindings for the Nojoom Lifestyle SDK. A single package embeds the Nojoom offers / coupons experience into a MAUI app on both Android and iOS.

You give the SDK a session token; it renders its entire UI itself — home, offer categories, merchant listings, offer details with maps, coupons, favourites, redemption (QR / code), and contacts. Your app builds none of those screens.

Target Included
net10.0-android Managed binding + all runtime AARs (Jetpack Compose, Coil, Google Maps, Huawei Map Kit, Retrofit/OkHttp, Nimbus JWT)
net9.0-ios Managed binding + native NojoomLifestyles.xcframework (device + simulator slices)

One PackageReference covers both platforms.

Install

dotnet add package Nojoom --version 1.0.7
<PackageReference Include="Nojoom" Version="1.0.7" />

Requirements

  • .NET 9 with the MAUI / android and ios workloads.
  • Android minimum API level 24; iOS minimum 13.0.

Host-app configuration

These cannot be carried by the package and must be supplied by the consuming app.

Android — required NuGet pins (build/runtime conflict fix)

com.google.gson and a few AndroidX versions conflict with what Microsoft.Maui.Core pins. Add these to your app project or you'll hit NU1107 at build or a crash at runtime:

<ItemGroup Condition="$(TargetFramework.Contains('-android'))">
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.LiveData" Version="2.11.0.1" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.LiveData.Core" Version="2.11.0.1" />
  <PackageReference Include="Xamarin.AndroidX.SavedState.SavedState.Ktx" Version="1.5.0.1" />
</ItemGroup>

The NU1608 "version outside constraint" warnings these produce are expected and benign. (Non-MAUI Xamarin.Android hosts must also add the GoogleGson NuGet ≥ 2.10.1 — a MAUI app already provides it transitively.)

The SDK's networking stack also needs com.squareup.okio (Okio) present at runtime. Apps using Firebase Analytics/Messaging already get it transitively via Xamarin.AndroidX.DataStore.*; if yours doesn't, add Square.OkIO.JVM (≥ 3.17.0.1) yourself.

As of 1.0.7, Xamarin.AndroidX.NavigationEvent (supplies androidx.navigationevent.* for the SDK's NavHost) ships as a direct package dependency — no host action needed. If you're on 1.0.5 or earlier and see java.lang.NoClassDefFoundError: Failed resolution of: Landroidx/navigationevent/NavigationEventDispatcherOwner; at launch, upgrade, or add Xamarin.AndroidX.NavigationEvent (1.0.2.1) yourself.

Crash on launch — IllegalStateException: Module with the Main dispatcher is missing: this means your app resolved a different version of Xamarin.KotlinX.Coroutines.Android than Xamarin.KotlinX.Coroutines.Core.Jvm (usually because another dependency — Firebase, Room, WorkManager, anything that touches Kotlin coroutines — pulled one of the two to a different version than the other). It's a host-side dependency conflict, not something inside this package. Pin both explicitly to the same version in your app, and make sure the pins above are current — stale/lower pin values can force the exact kind of conflict that leads here if worked around by hand instead of raised.

Android — Google Maps API key (required)

The SDK shows a Google Map on offer-detail screens. Add your key to the host AndroidManifest.xml (play-services-maps reads it from the host, never the SDK). Without it the app hard-crashes with IllegalStateException: API key not found when a map opens.

<application ...>
  <meta-data android:name="com.google.android.geo.API_KEY" android:value="YOUR_MAPS_KEY" />
</application>

Huawei devices additionally need an AppGallery Connect project (agconnect-services.json + Map Kit key) in the host app.

iOS

No extra references or pins — the native NojoomLifestyles.xcframework ships inside the package and links automatically.

Initialize & launch

The one runtime input is a session token from your own login flow. No API key or encryption keys are needed — those are embedded in the SDK. Initialization is async — only show the SDK UI after onSuccess.

Which backend does the SDK talk to?

If you do nothing, the SDK talks to the UAT environment (https://uat.aideasolution.com/api/). You only need to think about this once you're given a different URL (e.g. production) — at that point, pass it as one extra argument exactly where shown in the two code blocks below (CreateIntent on Android, Initialize on iOS). There's nothing else to configure, no separate file or setting — it's that one line, right where you already call the SDK.

⚠️ One rule: wherever you get the session token from (your login API, or a test endpoint) must be the same backend you pass here. A token from one backend is always rejected on a different one — the SDK reports that as onSessionExpired / onError, which can look like a bug elsewhere but really just means the two don't match.

Android — launch NojoomActivity

using Com.Nojoom.Lifestyles.Public;
using Microsoft.Maui.ApplicationModel;

var activity = Platform.CurrentActivity;

// 2 arguments (token only) = talks to UAT automatically. To use a different backend,
// add the URL as a 3rd argument, e.g.:
//   NojoomActivity.CreateIntent(activity, token, "https://your-prod-host/api/")
var intent = NojoomActivity.CreateIntent(activity, token);

activity.StartActivity(intent);   // NojoomActivity self-initializes and renders its own UI

iOS — initialize, present on success

using NojoomLifestyles;
using Microsoft.Maui.ApplicationModel;
using UIKit;

NojoomSDK.Initialize(
    token,
    baseUrl: null,   // null = UAT automatically. Replace with e.g. "https://your-prod-host/api/"
                      // to use a different backend — that's the only change needed.
    onSuccess: () => MainThread.BeginInvokeOnMainThread(() =>
    {
        // Grab the app's top-most view controller to present from.
        var root = UIApplication.SharedApplication.KeyWindow?.RootViewController;
        while (root?.PresentedViewController is not null)
            root = root.PresentedViewController;

        var vc = NojoomSDK.MakeContentViewController();
        vc.ModalPresentationStyle = UIModalPresentationStyle.FullScreen;
        root?.PresentViewController(vc, animated: true, completionHandler: null);
    }),
    onError: message => { /* show error, prompt re-login */ },
    onSessionExpired: null,
    onRefreshToken: null,
    onOfferRedeemed: null);

Session callbacks (optional, both platforms)

Three optional callbacks: session-expired, token-refresh, offer-redeemed.

Register them before launching NojoomActivity:

NojoomActivity.SetOnOfferRedeemed(new RedeemListener(token => { /* forward token to backend */ }));
NojoomActivity.SetOnRefreshToken(new RefreshTokenListener(async () => await GetFreshTokenAsync()));

RedeemListener and RefreshTokenListener are small adapter classes you add to your app — each wraps a C# delegate in the SDK's Java interface and must extend Java.Lang.Object to cross the JNI boundary. Paste these two classes as-is:

using Com.Nojoom.Lifestyles.Public;

// Adapts an Action<string> to INojoomRedeemListener.
sealed class RedeemListener : Java.Lang.Object, INojoomRedeemListener
{
    readonly Action<string> _onOfferRedeemed;
    public RedeemListener(Action<string> onOfferRedeemed) => _onOfferRedeemed = onOfferRedeemed;
    public void OnOfferRedeemed(string token) => _onOfferRedeemed(token);
}

// Adapts an async Func<Task<string?>> to INojoomRefreshTokenListener.
// The SDK calls OnRefreshToken on the main thread and blocks a background thread (up to 30s)
// waiting for the reply, so run the refresh OFF the main thread and deliver via
// result.OnToken(...) from whatever thread it finishes on (pass null if the refresh failed).
sealed class RefreshTokenListener : Java.Lang.Object, INojoomRefreshTokenListener
{
    readonly Func<Task<string?>> _onRefreshToken;
    public RefreshTokenListener(Func<Task<string?>> onRefreshToken) => _onRefreshToken = onRefreshToken;

    public void OnRefreshToken(INojoomTokenCallback result) => _ = Task.Run(async () =>
    {
        string? newToken;
        try { newToken = await _onRefreshToken(); } catch { newToken = null; }
        result.OnToken(newToken);
    });
}

iOS — filling in the session callbacks

The iOS example above already uses the full Initialize overload (with baseUrl) but passed null for the three optional callbacks. Fill them in like this:

NojoomSDK.Initialize(
    token,
    baseUrl: null,   // or "https://your-prod-host/api/" — same as the example above
    onSuccess: () => { /* present MakeContentViewController() */ },
    onError: message => { /* show error */ },
    onSessionExpired: () => { /* prompt re-login */ },
    onRefreshToken: completion => Task.Run(async () =>
    {
        string? fresh;
        try { fresh = await GetFreshTokenAsync(); } catch { fresh = null; }
        completion.Provide(fresh);   // any thread; null = refresh failed
    }),
    onOfferRedeemed: redeemToken => { /* forward opaque token to your backend */ });

Pass null for any callback you don't need.

Behaviour notes

  • The SDK owns the whole screen; your app gets no navigation callbacks until the user backs out.
  • Security is on by default: screenshots/recording of SDK screens are blocked, plus device integrity checks. Relaxed automatically on debug builds so emulator/QA is unaffected.
  • Token carries a ~1-hour backend expiry + configurable idle timeout (default 30 min).

API surface

Android (Com.Nojoom.Lifestyles.Public) — NojoomActivity.CreateIntent(context, token[, baseUrl]), SetOnOfferRedeemed, SetOnRefreshToken; NojoomSDK.Initialize/IsInitialized/Reset; INojoomRedeemListener, INojoomRefreshTokenListener, INojoomTokenCallback. (NojoomSDKView is intentionally not bound — use NojoomActivity.)

iOS (NojoomLifestyles) — NojoomSDK.Initialize(token, onSuccess, onError), NojoomSDK.Initialize(token, baseUrl, onSuccess, onError, onSessionExpired, onRefreshToken, onOfferRedeemed), MakeContentViewController(), IsInitialized, Reset(), NojoomTokenCompletion.Provide(token).

License

Proprietary. All rights reserved. See LICENSE.txt.

Product Compatible and additional computed target framework versions.
.NET net9.0-ios18.0 is compatible.  net10.0-android36.0 is compatible.  net10.0-ios was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.7 46 8/20/2026
1.0.6 46 8/20/2026
1.0.5 44 8/20/2026
1.0.4 55 8/19/2026
1.0.3 100 8/13/2026
1.0.2 101 8/12/2026
1.0.1 100 8/11/2026
1.0.0 93 8/10/2026