You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Added support for real-time audiences segmentation in placements based on user properties
* Fixed a bug that appeared only in 3.4.0 and could lead to incorrect audiences segmentation in placements based on store country.
Copy file name to clipboardExpand all lines: Sources/Public/Apphud.swift
+38-50Lines changed: 38 additions & 50 deletions
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ import Foundation
14
14
import UserNotifications
15
15
import SwiftUI
16
16
17
-
internalletapphud_sdk_version="3.4.0"
17
+
internalletapphud_sdk_version="3.5.0"
18
18
19
19
// MARK: - Initialization
20
20
@@ -189,61 +189,25 @@ final public class Apphud: NSObject {
189
189
callback(ApphudInternal.shared.placements, error)
190
190
}
191
191
}
192
-
192
+
193
193
/**
194
-
Asynchronously retrieves the paywalls configured in Product Hub > Paywalls, potentially altered based on the user's involvement in A/B testing, if any. Awaits until the inner `SKProduct`s are loaded from the App Store.
195
-
196
-
- Important: In case of network issues this method may return empty array. To get the possible error use `paywallsDidLoadCallback` method instead.
194
+
Disables automatic paywall and placement requests during the SDK's initial setup. Developers must explicitly call `fetchPlacements` or `await placements()` methods at a later point in the app's lifecycle to fetch placements with inner paywalls.
197
195
198
-
For immediate access without awaiting `SKProduct`s, use `rawPaywalls()` method.
199
-
- parameter maxAttempts: Number of request attempts before throwing an error. Must be between 1 and 10. Default value is 3.
196
+
Example:
200
197
201
-
- Important: This is deprecated method. Retrieve paywalls from within placements instead. See documentation for details: https://docs.apphud.com/docs/paywalls
202
-
203
-
- Returns: An array of `ApphudPaywall` objects, representing the configured paywalls.
204
-
*/
205
-
@available(*, deprecated, message:"Deprecated in favor of placements()")
A list of paywalls, potentially altered based on the user's involvement in A/B testing, if any.
217
-
218
-
- Important: This function doesn't await until inner `SKProduct`s are loaded from the App Store. That means paywalls may or may not have inner StoreKit products at the time you call this function.
219
-
220
-
- Important: This function will return empty array if user is not yet loaded, or placements are not set up in the Product Hub.
221
-
222
-
To get paywalls with awaiting for StoreKit products, use await Apphud.paywalls() or
223
-
Apphud.paywallsDidLoadCallback(...) functions.
224
-
225
-
- Returns: An array of `ApphudPaywall` objects, representing the configured paywalls.
Asynchronously retrieve a specific paywall by identifier configured in Product Hub > Paywalls, potentially altered based on the user's involvement in A/B testing, if any. Awaits until the inner `SKProduct`s are loaded from the App Store.
233
-
234
-
For immediate access without awaiting `SKProduct`s, use `ApphudDelegate`'s `userDidLoad` method or the callback in `Apphud.start(...)`.
205
+
```
235
206
236
-
- Important: In case of network issues this method may return empty array. To get the possible error use `paywallsDidLoadCallback` method instead.
237
-
238
-
- Important: This is deprecated method. Retrieve paywalls from within placements instead. See documentation for details: https://docs.apphud.com/docs/placements
239
-
240
-
- parameter identifier: The unique identifier for the desired paywall.
241
-
- Returns: An optional `ApphudPaywall` object if found, or `nil` if no matching paywall is found.
207
+
Note: You can use this method alongside `forceFlushUserProperties` to achieve real-time user segmentation based on custom user properties.
242
208
*/
243
-
@available(*, deprecated, message:"Deprecated in favor of placement(_ identifier: String)")
0 commit comments