AffiseSKAdNetwork pod
AffiseSKAdNetwork ships as a separate pod and SwiftPM product — it is not a subspec of AffiseModule.
Coordinates
Section titled “Coordinates”From AffiseSKAdNetwork.podspec:7-25:
- Pod name:
AffiseSKAdNetwork - Version:
1.7.8 - Platform:
ios(s.platform = "ios"at line 20) - iOS deployment target:
12.0 - Swift version:
5.7 - Linked framework:
StoreKit(s.framework = "StoreKit"at line 24) pod_target_xcconfig = { "DEFINES_MODULE" => "YES" }(line 25)
Podfile
Section titled “Podfile”Verbatim:
# Wrapper for StoreKit Ad Networkpod 'AffiseSKAdNetwork', '1.7.8'Or from GitHub:
# Wrapper for StoreKit Ad Networkpod 'AffiseSKAdNetwork', :git => 'https://github.com/affise/affise-mmp-sdk-ios.git', :tag => '1.7.8'SwiftPM
Section titled “SwiftPM”Product AffiseSKAdNetwork — Package.swift:21. Target AffiseSKAdNetwork at path AffiseSKAdNetwork with sources Classes; companion target AffiseInternalWrapperObjC at path AffiseSKAdNetwork with sources ObjC and linked framework StoreKit (Package.swift:87-101).
Public API
Section titled “Public API”@objc public class AffiseSKAd: NSObject—AffiseSKAdNetwork/Classes/AffiseSKAd.swift:10-11public static func register(_ completionHandler: @escaping (String) -> Void)—AffiseSKAd.swift:13-33(Obj-C:@objc(registerWithCompletionHandler:))public static func updatePostbackConversionValue(fineValue: Int, coarseValue: CoarseValue?, _ completionHandler: @escaping (String) -> Void)—AffiseSKAd.swift:35-57(Obj-C:@objc(updatePostbackWithFineValue:coarseValue:completionHandler:))
@objc public class CoarseConversionValue: NSObject—AffiseSKAdNetwork/Classes/CoarseConversionValue.swift:4- Static helpers
high,low,medium(lines 7, 10, 13) public static func raw(_ value: String) -> CoarseValue(line 15)
- Static helpers
@objc public class CoarseValue: NSObjectwithpublic init(_ value: String)—AffiseSKAdNetwork/Classes/CoarseValue.swift:4-10- Obj-C wrapper
@interface AffiseStoreKitWrapper : NSObject—AffiseSKAdNetwork/ObjC/AffiseStoreKitWrapper.h:16-24
Platform gates
Section titled “Platform gates”From the implementation (AffiseSKAd.swift:15-56):
- iOS 16.1+ —
updatePostbackConversionValue(fine + coarse)viaSKAdNetwork. - iOS 15.4+ —
updatePostbackConversionValue(fine only)viaSKAdNetwork. - iOS 14.0+ — legacy
updateConversionValue(_:);registerusesregisterAppForAdNetworkAttribution(). - Otherwise — completion receives
"<OS> <version> Not supported".
Related
Section titled “Related”- SKAdNetwork feature — usage examples,
Info.plistendpoint, and Swift/Obj-C tabs.