AdMacroProvider
@objc(AASDKAdMacroProvider)
public protocol AdMacroProvider
The AdMacroProvider protocol encapsulates values for various VAST macros that cannot be automatically computed by AdswizzSDK.
Pass an AdMacroProvider implementation suitable to your integration scenario in AdRequest and AdManager. The values will then be used by the internal macro replacer into their coresspondent pixel tracking URLs and/or VAST request URIs.
-
Value for [CONTENTID] macro. The publisher-specific content identifier for the content asset into which the ad is being loaded or inserted. The format is similar to the [UNIVERSALADID] macro, consisting of a registry identifier and a registry-specific content identifier. e.g “my-domain.com my-audio-123”. Do not encode the value. Applicable for VAST request URIs and all tracking pixels.
Declaration
Swift
var contentId: String? { get } -
Value for [CONTENTURI] macro. The URI of the main media content asset into which the ad is being loaded or inserted. Do not encode the value. Applicable for VAST request URIs and all tracking pixels.
Declaration
Swift
var contentUri: String? { get } -
Value for [MEDIAPLAYHEAD] macro. Playhead for the video or audio content (NOT the ad creative). Measured in seconds. Applicable for VAST request URIs and all tracking pixels.
Declaration
Swift
var mediaPlayhead: TimeInterval { get }