Events
Events are the primary signals from your app. Use NuxieSDK.shared.trigger.
Shape
json
{
"name": "purchase_completed",
"properties": {
"sku": "pro_annual",
"price": 59.99,
"currency": "USD"
},
"timestamp": "2025-01-01T12:34:56Z"
}Common examples (illustrative)
app_openedonboarding_completed{method}viewed_paywall{placement, paywallId}purchase_started{sku}purchase_completed{sku, price, currency}trial_started{sku}trial_ending_soon{daysRemaining}
Usage
- Triggers: start a campaign when an event occurs.
- Segmentation: include/exclude users based on event history or properties.
- Analytics: correlate paywall shows with downstream conversions.
Tracking API
swift
// Fire-and-forget
NuxieSDK.shared.trigger("app_opened")
// With properties
NuxieSDK.shared.trigger("feature_used", properties: ["feature": "editor"])
// Observe immediate outcomes
NuxieSDK.shared.trigger("paywall_shown", properties: ["id": "paywall_summer_launch"]) { result in
switch result {
case .noInteraction: break
case .screen(let completion): print(completion.outcome)
case .failed(let error): print(error)
}
}Keep your team’s event names short, consistent, and documented.