@bigcrunch/react-native-ads 0.3.1 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/android/bigcrunch-ads/com/bigcrunch/ads/BigCrunchAds.kt +434 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/BigCrunchBannerView.kt +484 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/BigCrunchInterstitial.kt +403 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/BigCrunchRewarded.kt +409 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/adapters/GoogleAdsAdapter.kt +592 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/core/AdOrchestrator.kt +623 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/core/AnalyticsClient.kt +719 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/core/BidRequestClient.kt +364 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/core/ConfigManager.kt +301 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/core/DeviceContext.kt +385 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/core/RewardedCallback.kt +42 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/core/SessionManager.kt +330 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/internal/DeviceHelper.kt +60 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/internal/HttpClient.kt +114 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/internal/Logger.kt +71 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/internal/PrivacyStore.kt +125 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/internal/Storage.kt +88 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/listeners/BannerAdListener.kt +55 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/listeners/InterstitialAdListener.kt +55 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/listeners/RewardedAdListener.kt +58 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/models/AdEvent.kt +880 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/models/AppConfig.kt +90 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/models/DeviceData.kt +18 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/models/PlacementConfig.kt +70 -0
- package/android/bigcrunch-ads/com/bigcrunch/ads/models/SessionInfo.kt +21 -0
- package/android/build.gradle +22 -10
- package/android/settings.gradle +2 -6
- package/android/src/main/java/com/bigcrunch/ads/react/BigCrunchAdsModule.kt +0 -23
- package/ios/BigCrunchAds/Sources/Adapters/GoogleAdsAdapter.swift +512 -0
- package/ios/BigCrunchAds/Sources/BigCrunchAds.swift +387 -0
- package/ios/BigCrunchAds/Sources/BigCrunchBannerView.swift +448 -0
- package/ios/BigCrunchAds/Sources/BigCrunchInterstitial.swift +412 -0
- package/ios/BigCrunchAds/Sources/BigCrunchRewarded.swift +523 -0
- package/ios/BigCrunchAds/Sources/Core/AdOrchestrator.swift +514 -0
- package/ios/BigCrunchAds/Sources/Core/AnalyticsClient.swift +874 -0
- package/ios/BigCrunchAds/Sources/Core/BidRequestClient.swift +344 -0
- package/ios/BigCrunchAds/Sources/Core/ConfigManager.swift +306 -0
- package/ios/BigCrunchAds/Sources/Core/DeviceContext.swift +284 -0
- package/ios/BigCrunchAds/Sources/Core/SessionManager.swift +392 -0
- package/ios/BigCrunchAds/Sources/Internal/HTTPClient.swift +146 -0
- package/ios/BigCrunchAds/Sources/Internal/Logger.swift +62 -0
- package/ios/BigCrunchAds/Sources/Internal/PrivacyStore.swift +129 -0
- package/ios/BigCrunchAds/Sources/Internal/Storage.swift +73 -0
- package/ios/BigCrunchAds/Sources/Models/AdEvent.swift +784 -0
- package/ios/BigCrunchAds/Sources/Models/AppConfig.swift +100 -0
- package/ios/BigCrunchAds/Sources/Models/DeviceData.swift +68 -0
- package/ios/BigCrunchAds/Sources/Models/PlacementConfig.swift +137 -0
- package/ios/BigCrunchAds/Sources/Models/SessionInfo.swift +48 -0
- package/ios/BigCrunchAdsModule.swift +5 -14
- package/ios/BigCrunchBannerViewManager.swift +0 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +3 -2
- package/lib/types/config.d.ts +22 -9
- package/lib/types/config.d.ts.map +1 -1
- package/lib/types/events.d.ts +4 -4
- package/lib/types/events.d.ts.map +1 -1
- package/package.json +11 -4
- package/react-native-bigcrunch-ads.podspec +1 -3
- package/scripts/inject-version.js +55 -0
- package/src/index.ts +3 -2
- package/src/types/config.ts +23 -9
- package/src/types/events.ts +4 -4
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Top-level application configuration returned from the BigCrunch backend
|
|
5
|
+
*
|
|
6
|
+
* This config contains all placement definitions and is fetched once at SDK initialization
|
|
7
|
+
* and cached for subsequent sessions.
|
|
8
|
+
*/
|
|
9
|
+
public struct AppConfig: Codable {
|
|
10
|
+
public let propertyId: String
|
|
11
|
+
public let appName: String
|
|
12
|
+
public let environment: String
|
|
13
|
+
public let gamNetworkCode: String
|
|
14
|
+
public let s2s: S2SConfig
|
|
15
|
+
public let bidders: [String: BidderEntry]?
|
|
16
|
+
public let amazonAps: GlobalAmazonConfig?
|
|
17
|
+
public let useTestAds: Bool
|
|
18
|
+
public let refresh: RefreshConfig?
|
|
19
|
+
public let placements: [PlacementConfig]
|
|
20
|
+
|
|
21
|
+
public init(
|
|
22
|
+
propertyId: String,
|
|
23
|
+
appName: String,
|
|
24
|
+
environment: String,
|
|
25
|
+
gamNetworkCode: String,
|
|
26
|
+
s2s: S2SConfig,
|
|
27
|
+
bidders: [String: BidderEntry]? = nil,
|
|
28
|
+
amazonAps: GlobalAmazonConfig?,
|
|
29
|
+
useTestAds: Bool = false,
|
|
30
|
+
refresh: RefreshConfig? = nil,
|
|
31
|
+
placements: [PlacementConfig]
|
|
32
|
+
) {
|
|
33
|
+
self.propertyId = propertyId
|
|
34
|
+
self.appName = appName
|
|
35
|
+
self.environment = environment
|
|
36
|
+
self.gamNetworkCode = gamNetworkCode
|
|
37
|
+
self.s2s = s2s
|
|
38
|
+
self.bidders = bidders
|
|
39
|
+
self.amazonAps = amazonAps
|
|
40
|
+
self.useTestAds = useTestAds
|
|
41
|
+
self.refresh = refresh
|
|
42
|
+
self.placements = placements
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* S2S (server-to-server) auction configuration
|
|
49
|
+
*
|
|
50
|
+
* Controls the connection to the BigCrunch S2S endpoint for bid requests.
|
|
51
|
+
*/
|
|
52
|
+
public struct S2SConfig: Codable {
|
|
53
|
+
public let enabled: Bool
|
|
54
|
+
public let serverUrl: String
|
|
55
|
+
public let timeoutMs: Int
|
|
56
|
+
|
|
57
|
+
public init(enabled: Bool = true, serverUrl: String, timeoutMs: Int) {
|
|
58
|
+
self.enabled = enabled
|
|
59
|
+
self.serverUrl = serverUrl
|
|
60
|
+
self.timeoutMs = timeoutMs
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
public init(from decoder: Decoder) throws {
|
|
64
|
+
let container = try decoder.container(keyedBy: CodingKeys.self)
|
|
65
|
+
enabled = try container.decodeIfPresent(Bool.self, forKey: .enabled) ?? true
|
|
66
|
+
serverUrl = try container.decode(String.self, forKey: .serverUrl)
|
|
67
|
+
timeoutMs = try container.decode(Int.self, forKey: .timeoutMs)
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Top-level bidder entry with shared params and per-placement params
|
|
73
|
+
*
|
|
74
|
+
* Each bidder has optional shared params (applied to all impressions) and
|
|
75
|
+
* a placements map (placementId → imp-level params for that bidder).
|
|
76
|
+
*/
|
|
77
|
+
public struct BidderEntry: Codable {
|
|
78
|
+
public let params: [String: AnyCodable]?
|
|
79
|
+
public let placements: [String: [String: AnyCodable]]?
|
|
80
|
+
|
|
81
|
+
public init(params: [String: AnyCodable]?, placements: [String: [String: AnyCodable]]?) {
|
|
82
|
+
self.params = params
|
|
83
|
+
self.placements = placements
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Global Amazon APS configuration
|
|
89
|
+
*/
|
|
90
|
+
public struct GlobalAmazonConfig: Codable {
|
|
91
|
+
public let enabled: Bool
|
|
92
|
+
public let pubId: String
|
|
93
|
+
public let timeout: Int
|
|
94
|
+
|
|
95
|
+
public init(enabled: Bool, pubId: String, timeout: Int) {
|
|
96
|
+
self.enabled = enabled
|
|
97
|
+
self.pubId = pubId
|
|
98
|
+
self.timeout = timeout
|
|
99
|
+
}
|
|
100
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Device information for analytics and ad targeting
|
|
5
|
+
*
|
|
6
|
+
* Contains device hardware and software information used for analytics
|
|
7
|
+
* and can be exposed to React Native.
|
|
8
|
+
*/
|
|
9
|
+
public struct DeviceData {
|
|
10
|
+
/// Persistent device identifier (same as userId from SessionManager)
|
|
11
|
+
public let deviceId: String
|
|
12
|
+
|
|
13
|
+
/// Device model identifier (e.g., "iPhone14,2")
|
|
14
|
+
public let deviceModel: String
|
|
15
|
+
|
|
16
|
+
/// Operating system version (e.g., "17.0")
|
|
17
|
+
public let osVersion: String
|
|
18
|
+
|
|
19
|
+
/// App version string (e.g., "1.2.3")
|
|
20
|
+
public let appVersion: String
|
|
21
|
+
|
|
22
|
+
/// Screen width in points
|
|
23
|
+
public let screenWidth: Int
|
|
24
|
+
|
|
25
|
+
/// Screen height in points
|
|
26
|
+
public let screenHeight: Int
|
|
27
|
+
|
|
28
|
+
/// User's language code (e.g., "en")
|
|
29
|
+
public let language: String
|
|
30
|
+
|
|
31
|
+
/// User's country code (e.g., "US")
|
|
32
|
+
public let country: String
|
|
33
|
+
|
|
34
|
+
/// Whether the device is a tablet
|
|
35
|
+
public let isTablet: Bool
|
|
36
|
+
|
|
37
|
+
/// Mobile carrier name (if available)
|
|
38
|
+
public let carrier: String?
|
|
39
|
+
|
|
40
|
+
/// Network connection type (e.g., "wifi", "cellular")
|
|
41
|
+
public let networkType: String?
|
|
42
|
+
|
|
43
|
+
public init(
|
|
44
|
+
deviceId: String,
|
|
45
|
+
deviceModel: String,
|
|
46
|
+
osVersion: String,
|
|
47
|
+
appVersion: String,
|
|
48
|
+
screenWidth: Int,
|
|
49
|
+
screenHeight: Int,
|
|
50
|
+
language: String,
|
|
51
|
+
country: String,
|
|
52
|
+
isTablet: Bool,
|
|
53
|
+
carrier: String? = nil,
|
|
54
|
+
networkType: String? = nil
|
|
55
|
+
) {
|
|
56
|
+
self.deviceId = deviceId
|
|
57
|
+
self.deviceModel = deviceModel
|
|
58
|
+
self.osVersion = osVersion
|
|
59
|
+
self.appVersion = appVersion
|
|
60
|
+
self.screenWidth = screenWidth
|
|
61
|
+
self.screenHeight = screenHeight
|
|
62
|
+
self.language = language
|
|
63
|
+
self.country = country
|
|
64
|
+
self.isTablet = isTablet
|
|
65
|
+
self.carrier = carrier
|
|
66
|
+
self.networkType = networkType
|
|
67
|
+
}
|
|
68
|
+
}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Configuration for a single ad placement
|
|
5
|
+
*
|
|
6
|
+
* Contains all information needed to request and display an ad at a specific
|
|
7
|
+
* location in the app. Bidder configuration is no longer stored here — it lives
|
|
8
|
+
* in the top-level `AppConfig.bidders` dictionary.
|
|
9
|
+
*/
|
|
10
|
+
public struct PlacementConfig: Codable {
|
|
11
|
+
public let placementId: String
|
|
12
|
+
public let format: String // "banner", "interstitial", "rewarded"
|
|
13
|
+
public let gamAdUnit: String
|
|
14
|
+
public let sizes: [AdSize]?
|
|
15
|
+
public let refresh: RefreshConfig?
|
|
16
|
+
|
|
17
|
+
public init(
|
|
18
|
+
placementId: String,
|
|
19
|
+
format: String,
|
|
20
|
+
gamAdUnit: String,
|
|
21
|
+
sizes: [AdSize]?,
|
|
22
|
+
refresh: RefreshConfig? = nil
|
|
23
|
+
) {
|
|
24
|
+
self.placementId = placementId
|
|
25
|
+
self.format = format
|
|
26
|
+
self.gamAdUnit = gamAdUnit
|
|
27
|
+
self.sizes = sizes
|
|
28
|
+
self.refresh = refresh
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Type-erased Codable wrapper for arbitrary JSON values
|
|
34
|
+
*
|
|
35
|
+
* Supports String, Int, Double, Bool, nested objects, and arrays.
|
|
36
|
+
*/
|
|
37
|
+
public struct AnyCodable: Codable, Equatable {
|
|
38
|
+
public let value: Any
|
|
39
|
+
|
|
40
|
+
public init(_ value: Any) {
|
|
41
|
+
self.value = value
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
public init(from decoder: Decoder) throws {
|
|
45
|
+
let container = try decoder.singleValueContainer()
|
|
46
|
+
if let intVal = try? container.decode(Int.self) {
|
|
47
|
+
value = intVal
|
|
48
|
+
} else if let doubleVal = try? container.decode(Double.self) {
|
|
49
|
+
value = doubleVal
|
|
50
|
+
} else if let boolVal = try? container.decode(Bool.self) {
|
|
51
|
+
value = boolVal
|
|
52
|
+
} else if let stringVal = try? container.decode(String.self) {
|
|
53
|
+
value = stringVal
|
|
54
|
+
} else if let arrayVal = try? container.decode([AnyCodable].self) {
|
|
55
|
+
value = arrayVal.map { $0.value }
|
|
56
|
+
} else if let dictVal = try? container.decode([String: AnyCodable].self) {
|
|
57
|
+
value = dictVal.mapValues { $0.value }
|
|
58
|
+
} else {
|
|
59
|
+
throw DecodingError.dataCorruptedError(in: container, debugDescription: "Unsupported JSON value")
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
public func encode(to encoder: Encoder) throws {
|
|
64
|
+
var container = encoder.singleValueContainer()
|
|
65
|
+
switch value {
|
|
66
|
+
case let intVal as Int:
|
|
67
|
+
try container.encode(intVal)
|
|
68
|
+
case let doubleVal as Double:
|
|
69
|
+
try container.encode(doubleVal)
|
|
70
|
+
case let boolVal as Bool:
|
|
71
|
+
try container.encode(boolVal)
|
|
72
|
+
case let stringVal as String:
|
|
73
|
+
try container.encode(stringVal)
|
|
74
|
+
case let arrayVal as [Any]:
|
|
75
|
+
try container.encode(arrayVal.map { AnyCodable($0) })
|
|
76
|
+
case let dictVal as [String: Any]:
|
|
77
|
+
try container.encode(dictVal.mapValues { AnyCodable($0) })
|
|
78
|
+
default:
|
|
79
|
+
throw EncodingError.invalidValue(value, EncodingError.Context(codingPath: encoder.codingPath, debugDescription: "Unsupported value type"))
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
public static func == (lhs: AnyCodable, rhs: AnyCodable) -> Bool {
|
|
84
|
+
switch (lhs.value, rhs.value) {
|
|
85
|
+
case let (l as Int, r as Int): return l == r
|
|
86
|
+
case let (l as Double, r as Double): return l == r
|
|
87
|
+
case let (l as Bool, r as Bool): return l == r
|
|
88
|
+
case let (l as String, r as String): return l == r
|
|
89
|
+
default: return false
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* Ad size dimensions
|
|
96
|
+
*
|
|
97
|
+
* When `type` is "adaptive" or "smart", the SDK will use Google's adaptive
|
|
98
|
+
* banner API to calculate the optimal height for the given `width`.
|
|
99
|
+
* A `width` of 0 means "use screen width".
|
|
100
|
+
*/
|
|
101
|
+
/// Typealias for disambiguation when module name collides with BigCrunchAds class name
|
|
102
|
+
public typealias BCAdSize = AdSize
|
|
103
|
+
|
|
104
|
+
public struct AdSize: Codable, Equatable {
|
|
105
|
+
public let width: Int
|
|
106
|
+
public let height: Int
|
|
107
|
+
public let type: String?
|
|
108
|
+
|
|
109
|
+
public var isAdaptive: Bool {
|
|
110
|
+
type == "adaptive" || type == "smart"
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
public init(width: Int, height: Int, type: String? = nil) {
|
|
114
|
+
self.width = width
|
|
115
|
+
self.height = height
|
|
116
|
+
self.type = type
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
public static func adaptive(width: Int = 0) -> AdSize {
|
|
120
|
+
AdSize(width: width, height: 0, type: "adaptive")
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
/**
|
|
125
|
+
* Refresh configuration for banner ads
|
|
126
|
+
*/
|
|
127
|
+
public struct RefreshConfig: Codable {
|
|
128
|
+
public let enabled: Bool
|
|
129
|
+
public let intervalMs: Int
|
|
130
|
+
public let maxRefreshes: Int
|
|
131
|
+
|
|
132
|
+
public init(enabled: Bool, intervalMs: Int, maxRefreshes: Int) {
|
|
133
|
+
self.enabled = enabled
|
|
134
|
+
self.intervalMs = intervalMs
|
|
135
|
+
self.maxRefreshes = maxRefreshes
|
|
136
|
+
}
|
|
137
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Session information for analytics tracking
|
|
5
|
+
*
|
|
6
|
+
* Provides current session state including identifiers and tracking counts.
|
|
7
|
+
* This data is used for analytics and can be exposed to React Native.
|
|
8
|
+
*/
|
|
9
|
+
public struct SessionInfo {
|
|
10
|
+
/// Unique identifier for the current session (changes each app launch)
|
|
11
|
+
public let sessionId: String
|
|
12
|
+
|
|
13
|
+
/// Persistent user identifier (stable across app launches)
|
|
14
|
+
public let userId: String
|
|
15
|
+
|
|
16
|
+
/// ISO 8601 timestamp when the session started
|
|
17
|
+
public let startTime: String
|
|
18
|
+
|
|
19
|
+
/// Number of screen views in this session
|
|
20
|
+
public let screenViewCount: Int
|
|
21
|
+
|
|
22
|
+
/// Number of ad requests made in this session
|
|
23
|
+
public let adRequestCount: Int
|
|
24
|
+
|
|
25
|
+
/// Number of ad impressions recorded in this session
|
|
26
|
+
public let adImpressionCount: Int
|
|
27
|
+
|
|
28
|
+
/// Total revenue in micros (1/1,000,000 of currency unit) for this session
|
|
29
|
+
public let totalRevenueMicros: Int64
|
|
30
|
+
|
|
31
|
+
public init(
|
|
32
|
+
sessionId: String,
|
|
33
|
+
userId: String,
|
|
34
|
+
startTime: String,
|
|
35
|
+
screenViewCount: Int,
|
|
36
|
+
adRequestCount: Int,
|
|
37
|
+
adImpressionCount: Int,
|
|
38
|
+
totalRevenueMicros: Int64
|
|
39
|
+
) {
|
|
40
|
+
self.sessionId = sessionId
|
|
41
|
+
self.userId = userId
|
|
42
|
+
self.startTime = startTime
|
|
43
|
+
self.screenViewCount = screenViewCount
|
|
44
|
+
self.adRequestCount = adRequestCount
|
|
45
|
+
self.adImpressionCount = adImpressionCount
|
|
46
|
+
self.totalRevenueMicros = totalRevenueMicros
|
|
47
|
+
}
|
|
48
|
+
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import Foundation
|
|
2
|
-
import BigCrunchAds
|
|
3
2
|
#if canImport(React)
|
|
4
3
|
import React
|
|
5
4
|
#endif
|
|
@@ -257,9 +256,10 @@ class BigCrunchAdsModule: RCTEventEmitter {
|
|
|
257
256
|
"appName": config.appName,
|
|
258
257
|
"environment": config.environment,
|
|
259
258
|
"gamNetworkCode": config.gamNetworkCode,
|
|
260
|
-
"
|
|
261
|
-
"
|
|
262
|
-
"
|
|
259
|
+
"s2s": [
|
|
260
|
+
"enabled": config.s2s.enabled,
|
|
261
|
+
"serverUrl": config.s2s.serverUrl,
|
|
262
|
+
"timeoutMs": config.s2s.timeoutMs
|
|
263
263
|
],
|
|
264
264
|
"placements": config.placements.map { placement in
|
|
265
265
|
var placementDict: [String: Any] = [
|
|
@@ -270,15 +270,6 @@ class BigCrunchAdsModule: RCTEventEmitter {
|
|
|
270
270
|
if let sizes = placement.sizes {
|
|
271
271
|
placementDict["sizes"] = sizes.map { ["width": $0.width, "height": $0.height] }
|
|
272
272
|
}
|
|
273
|
-
if let bidders = placement.bidders {
|
|
274
|
-
placementDict["bidders"] = bidders.map { bidderConfig in
|
|
275
|
-
var bidderDict: [String: Any] = ["bidder": bidderConfig.bidder]
|
|
276
|
-
if let params = bidderConfig.params {
|
|
277
|
-
bidderDict["params"] = params.mapValues { $0.value }
|
|
278
|
-
}
|
|
279
|
-
return bidderDict
|
|
280
|
-
}
|
|
281
|
-
}
|
|
282
273
|
return placementDict
|
|
283
274
|
}
|
|
284
275
|
]
|
|
@@ -400,7 +391,7 @@ class BigCrunchAdsModule: RCTEventEmitter {
|
|
|
400
391
|
return
|
|
401
392
|
}
|
|
402
393
|
|
|
403
|
-
// customTargeting can be used in future for custom
|
|
394
|
+
// customTargeting can be used in future for custom S2S targeting
|
|
404
395
|
// let customTargeting = options["customTargeting"] as? [String: String]
|
|
405
396
|
|
|
406
397
|
BigCrunchRewarded.preload(placementId: placementId) { [weak self] result in
|
package/lib/index.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ import BigCrunchRewarded from './BigCrunchRewarded';
|
|
|
13
13
|
export * from './types';
|
|
14
14
|
export type { InitializationOptions, Environment, AdFormat, BannerSize, CustomSize, BigCrunchBannerViewProps, InterstitialAd, RewardedAd, AdEvent, AdEventListener, EventSubscription, AdError, AdRevenue, AppConfig, PlacementConfig, SessionInfo, DeviceContext, } from './types';
|
|
15
15
|
export { AdErrorCode } from './types';
|
|
16
|
-
export declare const SDK_VERSION
|
|
16
|
+
export declare const SDK_VERSION: string;
|
|
17
17
|
/**
|
|
18
18
|
* Default export for convenience
|
|
19
19
|
*/
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EAAE,YAAY,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAG9E,OAAO,EAAE,mBAAmB,EAAE,OAAO,IAAI,0BAA0B,EAAE,MA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,EACV,UAAU,EAGV,wBAAwB,EACxB,cAAc,EACd,UAAU,EAGV,OAAO,EACP,eAAe,EACf,iBAAiB,EACjB,OAAO,EACP,SAAS,EAGT,SAAS,EACT,eAAe,EAGf,WAAW,EACX,aAAa,GACd,MAAM,SAAS,CAAC;AAGjB,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAItC,eAAO,MAAM,WAAW,EAAE,MAA2C,CAAC;AAEtE;;GAEG;;;;;;;;AACH,wBAME"}
|
package/lib/index.js
CHANGED
|
@@ -18,8 +18,9 @@ import BigCrunchRewarded from './BigCrunchRewarded';
|
|
|
18
18
|
export * from './types';
|
|
19
19
|
// Export error codes enum
|
|
20
20
|
export { AdErrorCode } from './types';
|
|
21
|
-
// Version
|
|
22
|
-
|
|
21
|
+
// Version - read from package.json
|
|
22
|
+
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
23
|
+
export const SDK_VERSION = require('../package.json').version;
|
|
23
24
|
/**
|
|
24
25
|
* Default export for convenience
|
|
25
26
|
*/
|
package/lib/types/config.d.ts
CHANGED
|
@@ -10,6 +10,10 @@ export interface AppConfig {
|
|
|
10
10
|
propertyId: string;
|
|
11
11
|
/** Property name */
|
|
12
12
|
propertyName: string;
|
|
13
|
+
/** S2S auction configuration */
|
|
14
|
+
s2s?: S2SConfig;
|
|
15
|
+
/** Top-level bidder configurations (bidderName → BidderEntry) */
|
|
16
|
+
bidders?: Record<string, BidderEntry>;
|
|
13
17
|
/** List of configured placements */
|
|
14
18
|
placements: PlacementConfig[];
|
|
15
19
|
/** Global settings */
|
|
@@ -33,8 +37,6 @@ export interface PlacementConfig {
|
|
|
33
37
|
gamAdUnit: string;
|
|
34
38
|
/** Ad size configuration */
|
|
35
39
|
size?: AdSizeConfig;
|
|
36
|
-
/** Prebid bidder configurations */
|
|
37
|
-
bidders?: BidderConfig[];
|
|
38
40
|
/** Amazon APS configuration */
|
|
39
41
|
amazonConfig?: AmazonConfig;
|
|
40
42
|
/** Placement-specific settings */
|
|
@@ -54,16 +56,27 @@ export interface AdSizeConfig {
|
|
|
54
56
|
adaptive?: boolean;
|
|
55
57
|
}
|
|
56
58
|
/**
|
|
57
|
-
*
|
|
59
|
+
* S2S (server-to-server) configuration for bid requests
|
|
60
|
+
*/
|
|
61
|
+
export interface S2SConfig {
|
|
62
|
+
/** Whether S2S is enabled */
|
|
63
|
+
enabled: boolean;
|
|
64
|
+
/** S2S auction server URL */
|
|
65
|
+
serverUrl: string;
|
|
66
|
+
/** Timeout for S2S requests in milliseconds */
|
|
67
|
+
timeoutMs: number;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Configuration for a single bidder at the app level
|
|
58
71
|
*
|
|
59
|
-
* Contains
|
|
60
|
-
* to
|
|
72
|
+
* Contains shared bidder params and a map of placement-specific params.
|
|
73
|
+
* Bidder-to-placement mapping is resolved from this structure.
|
|
61
74
|
*/
|
|
62
|
-
export interface
|
|
63
|
-
/**
|
|
64
|
-
bidder: string;
|
|
65
|
-
/** Bidder-specific parameters */
|
|
75
|
+
export interface BidderEntry {
|
|
76
|
+
/** Shared bidder-level parameters */
|
|
66
77
|
params?: Record<string, any>;
|
|
78
|
+
/** Per-placement params: placementId → imp-level params */
|
|
79
|
+
placements?: Record<string, Record<string, any>>;
|
|
67
80
|
}
|
|
68
81
|
/**
|
|
69
82
|
* Amazon APS configuration
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/types/config.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAEnC;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB,kBAAkB;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,oBAAoB;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,oCAAoC;IACpC,UAAU,EAAE,eAAe,EAAE,CAAC;IAC9B,sBAAsB;IACtB,QAAQ,CAAC,EAAE,cAA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C;IACxB,2BAA2B;IAC3B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,0CAA0C;IAC1C,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,6BAA6B;IAC7B,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,0BAA0B;IAC1B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,6BAA6B;IAC7B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,uBAAuB;IACvB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,iEAAiE;IACjE,OAAO,CAAC,EAAE,aAAa,CAAC;CACzB;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,iCAAiC;IACjC,OAAO,EAAE,OAAO,CAAC;IACjB,uCAAuC;IACvC,UAAU,EAAE,MAAM,CAAC;IACnB,kCAAkC;IAClC,YAAY,EAAE,MAAM,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,sDAAsD;IACtD,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,4BAA4B;IAC5B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,kCAAkC;IAClC,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,uCAAuC;IACvC,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,0CAA0C;IAC1C,eAAe,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC1C"}
|
package/lib/types/events.d.ts
CHANGED
|
@@ -44,7 +44,7 @@ export interface AdImpressionEvent extends BaseAdEvent {
|
|
|
44
44
|
gamAdUnit?: string;
|
|
45
45
|
/** Ad size (e.g., "320x50") */
|
|
46
46
|
adSize?: string;
|
|
47
|
-
/** Auction ID from
|
|
47
|
+
/** Auction ID from S2S bid request */
|
|
48
48
|
auctionId?: string;
|
|
49
49
|
/** Winning bidder name */
|
|
50
50
|
bidder?: string;
|
|
@@ -60,7 +60,7 @@ export interface AdImpressionEvent extends BaseAdEvent {
|
|
|
60
60
|
creativeId?: string;
|
|
61
61
|
/** Refresh count for this placement */
|
|
62
62
|
refreshCount?: number;
|
|
63
|
-
/** Demand channel (e.g., "
|
|
63
|
+
/** Demand channel (e.g., "S2S Header", "GAM Direct") */
|
|
64
64
|
demandChannel?: string;
|
|
65
65
|
}
|
|
66
66
|
/**
|
|
@@ -219,7 +219,7 @@ export interface ImpressionEvent extends WebSchemaCommonFields {
|
|
|
219
219
|
gamAdUnit: string;
|
|
220
220
|
/** Ad format (banner, interstitial, rewarded) */
|
|
221
221
|
format: string;
|
|
222
|
-
/** Auction ID from
|
|
222
|
+
/** Auction ID from S2S bid request */
|
|
223
223
|
auctionId?: string;
|
|
224
224
|
/** Refresh count for this placement */
|
|
225
225
|
refreshCount?: number;
|
|
@@ -247,7 +247,7 @@ export interface ImpressionEvent extends WebSchemaCommonFields {
|
|
|
247
247
|
amznPrice?: string;
|
|
248
248
|
/** Demand type (banner, video, etc.) */
|
|
249
249
|
demandType?: string;
|
|
250
|
-
/** Demand channel (e.g., "
|
|
250
|
+
/** Demand channel (e.g., "S2S Header", "GAM Direct") */
|
|
251
251
|
demandChannel?: string;
|
|
252
252
|
}
|
|
253
253
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/types/events.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAEvD;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,mBAAmB;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,gBAAgB;IAChB,MAAM,EAAE,QAAQ,CAAC;IACjB,6BAA6B;IAC7B,SAAS,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,WAAW;IAChD,IAAI,EAAE,UAAU,CAAC;IACjB,oCAAoC;IACpC,SAAS,CAAC,EAAE,MAAM,CAAC;I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AAM,CAAC;CACxB;AAED;;;GAGG;AACH,MAAM,WAAW,eAAgB,SAAQ,qBAAqB;IAC5D,uCAAuC;IACvC,WAAW,EAAE,MAAM,CAAC;IACpB,2CAA2C;IAC3C,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,kBAAkB;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,kCAAkC;IAClC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sBAAsB;IACtB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED;;GAEG;AACH,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bigcrunch/react-native-ads",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "BigCrunch Mobile Ads SDK for React Native - Simplified in-app advertising with
|
|
3
|
+
"version": "0.5.0",
|
|
4
|
+
"description": "BigCrunch Mobile Ads SDK for React Native - Simplified in-app advertising with S2S demand and Google Ad Manager",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
7
7
|
"react-native": "src/index.ts",
|
|
@@ -24,6 +24,9 @@
|
|
|
24
24
|
"ios/*.swift",
|
|
25
25
|
"ios/*.m",
|
|
26
26
|
"ios/*.h",
|
|
27
|
+
"ios/BigCrunchAds/**/*.swift",
|
|
28
|
+
"android/bigcrunch-ads/**/*.kt",
|
|
29
|
+
"scripts/inject-version.js",
|
|
27
30
|
"react-native-bigcrunch-ads.podspec",
|
|
28
31
|
"!**/__tests__",
|
|
29
32
|
"!**/__fixtures__",
|
|
@@ -33,6 +36,9 @@
|
|
|
33
36
|
"typescript": "tsc --noEmit",
|
|
34
37
|
"build": "tsc",
|
|
35
38
|
"prepare": "npm run build || echo 'Build skipped during install'",
|
|
39
|
+
"prepack": "mkdir -p ios/BigCrunchAds && cp -r ../ios/BigCrunchAds/Sources/ ios/BigCrunchAds/Sources/ && mkdir -p android/bigcrunch-ads && cp -r ../android/bigcrunch-ads/src/main/java/ android/bigcrunch-ads/ && node scripts/inject-version.js --prepack",
|
|
40
|
+
"postpack": "rm -rf ios/BigCrunchAds/Sources android/bigcrunch-ads/java",
|
|
41
|
+
"sync-version": "node scripts/inject-version.js --sync",
|
|
36
42
|
"release": "release-it",
|
|
37
43
|
"example": "yarn --cwd example",
|
|
38
44
|
"clean": "del-cli lib"
|
|
@@ -44,7 +50,8 @@
|
|
|
44
50
|
"ads",
|
|
45
51
|
"advertising",
|
|
46
52
|
"monetization",
|
|
47
|
-
"
|
|
53
|
+
"s2s",
|
|
54
|
+
"header-bidding",
|
|
48
55
|
"google-ad-manager",
|
|
49
56
|
"gam",
|
|
50
57
|
"banner",
|
|
@@ -85,4 +92,4 @@
|
|
|
85
92
|
"optional": false
|
|
86
93
|
}
|
|
87
94
|
}
|
|
88
|
-
}
|
|
95
|
+
}
|
|
@@ -7,7 +7,7 @@ Pod::Spec.new do |s|
|
|
|
7
7
|
s.version = package["version"]
|
|
8
8
|
s.summary = package["description"]
|
|
9
9
|
s.description = <<-DESC
|
|
10
|
-
BigCrunch Mobile Ads SDK for React Native - Simplified in-app advertising with
|
|
10
|
+
BigCrunch Mobile Ads SDK for React Native - Simplified in-app advertising with S2S demand and Google Ad Manager
|
|
11
11
|
DESC
|
|
12
12
|
s.homepage = "https://github.com/bigcrunch/mobile-ads-sdk"
|
|
13
13
|
s.license = "MIT"
|
|
@@ -19,9 +19,7 @@ Pod::Spec.new do |s|
|
|
|
19
19
|
s.requires_arc = true
|
|
20
20
|
|
|
21
21
|
s.dependency "React"
|
|
22
|
-
s.dependency "BigCrunchAds", "~> 0.1.0" # Reference to main iOS SDK
|
|
23
22
|
s.dependency "Google-Mobile-Ads-SDK", ">= 10.14.0"
|
|
24
|
-
s.dependency "PrebidMobile", "~> 2.3.1"
|
|
25
23
|
|
|
26
24
|
s.swift_version = "5.9"
|
|
27
25
|
end
|