trackImpression(analytics:)
Introduction
The trackImpression(analytics:)
method allows the SDK to notify your app of user impressions for analytics tracking purposes. This function is designed to capture passive interactions, such as views or impressions, and relay this information using a dictionary of key-value pairs. Although the specific details of the analytics data are still to be determined (TBD), this method serves as an integration point for your analytics or logging framework to monitor user impressions.
Parameters
Parameter | Type | Description | Example |
---|---|---|---|
analytics | [String: String] | A dictionary containing analytics data related to the user impression. | ["impression": "panel_view", "panel": "keyPlays"] |
Code Example
// Example analytics data for tracking a user impression
let analyticsData: [String: String] = [
"impression": "panel_view",
"panel": "keyPlays",
"timestamp": "\(Date().timeIntervalSince1970)"
]
// Notify the SDK about the user impression for analytics tracking.
delegate.trackImpression(analytics: analyticsData)