Skip to main content
The iOS SDK can render in-app notifications natively (banner, alert, HTML) and unwrap Spotzee click-tracking URLs so taps in emails open the right screen in your app. Both surfaces flow through delegates you implement.

In-app notifications

In-app notifications are content campaigns or journey steps that target the user’s open app session, not the OS push tray. The SDK fetches them, asks your delegate what to do, and renders the chosen ones in a modal.

Wire up the delegate

Implement InAppDelegate and pass an instance into Spotzee.initialize:
Default implementations cover everything except handle. You only need to implement the ones whose default doesn’t suit you.

What each delegate hook does

Manual control

Set autoShow to false and call showLatestNotification() from your own UI moment (after sign-in, after the home screen renders) to defer in-app delivery to a calmer surface than launch.
To enumerate or render a specific notification yourself:
To mark a notification read without showing it:
To dismiss a currently shown notification programmatically:

The three content types

For alert and html, the embedded HTML can call window.trigger({ … }) from JavaScript to invoke your delegate’s handle(action: .custom, context:, notification:) with the passed payload. Use this for “Buy now” buttons, “Open settings” actions, or anything that needs to bridge the WebView back to native code. Spotzee click-tracks email links by wrapping them in a https://<your-tracking-domain>/c?r=<encoded-target-url> URL. The SDK’s handle(universalLink:) unwraps the wrapper, registers the click with Spotzee, then opens the unwrapped target so your app navigates to the right screen.

Configure Associated Domains

In Xcode, open your target’s Signing & Capabilities tab, add Associated Domains, and add an entry for your tracking domain. The SDK detects Spotzee tracking links by their path pattern (/c or /c/), so custom domains work without further configuration once the Associated Domain is registered. Implement application(_:continue:restorationHandler:) and pass the URL through Spotzee.shared.handle(universalLink:). The method returns true if it recognised and handled the URL, false if you should handle it yourself.
For SceneDelegate apps, the equivalent hook is scene(_:continue:).

spotzee:// URL scheme

For deeplinks that don’t need to round-trip to the web (closing the in-app modal, triggering a custom intent), the SDK accepts a spotzee:// URL scheme inside notification HTML: These are interpreted inside the in-app modal’s WebView; you don’t need to register the scheme as a separate URL Type unless you also accept it from outside the app.

Next steps

Set up push providers

APN credentials must be configured before pushes deliver.

Configure custom domains

Set up a custom tracking domain to use as your applinks: host.