diff --git a/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h b/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h index b22e806a47..7856038263 100644 --- a/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h +++ b/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h @@ -1,4 +1,4 @@ -// Generated by Apple Swift version 6.0.2 effective-5.10 (swiftlang-6.0.2.1.2 clang-1600.0.26.4) +// Generated by Apple Swift version 6.0 effective-5.10 (swiftlang-6.0.0.9.10 clang-1600.0.26.2) #ifndef REVENUECAT_SWIFT_H #define REVENUECAT_SWIFT_H #pragma clang diagnostic push @@ -726,12 +726,12 @@ SWIFT_CLASS_NAMED("Builder") @interface RCConfigurationBuilder (SWIFT_EXTENSION(RevenueCat)) -- (RCConfigurationBuilder * _Nonnull)withObserverMode:(BOOL)observerMode SWIFT_WARN_UNUSED_RESULT SWIFT_AVAILABILITY(macos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(watchos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(tvos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(ios,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy."); +- (RCConfigurationBuilder * _Nonnull)withUsesStoreKit2IfAvailable:(BOOL)usesStoreKit2IfAvailable SWIFT_WARN_UNUSED_RESULT SWIFT_DEPRECATED_MSG("Use .with(storeKitVersion:) to enable StoreKit 2"); @end @interface RCConfigurationBuilder (SWIFT_EXTENSION(RevenueCat)) -- (RCConfigurationBuilder * _Nonnull)withUsesStoreKit2IfAvailable:(BOOL)usesStoreKit2IfAvailable SWIFT_WARN_UNUSED_RESULT SWIFT_DEPRECATED_MSG("Use .with(storeKitVersion:) to enable StoreKit 2"); +- (RCConfigurationBuilder * _Nonnull)withObserverMode:(BOOL)observerMode SWIFT_WARN_UNUSED_RESULT SWIFT_AVAILABILITY(macos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(watchos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(tvos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(ios,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy."); @end /// Specifies the behavior for a caching API. @@ -958,11 +958,11 @@ SWIFT_CLASS_NAMED("CustomerInfo") - @interface RCCustomerInfo (SWIFT_EXTENSION(RevenueCat)) @property (nonatomic, readonly, copy) NSDictionary * _Nonnull rawData; @end + @class RCStoreTransaction; @interface RCCustomerInfo (SWIFT_EXTENSION(RevenueCat)) @@ -1240,6 +1240,9 @@ typedef SWIFT_ENUM_NAMED(NSInteger, RCPurchasesErrorCode, "ErrorCode", open) { RCFeatureNotAvailableInCustomEntitlementsComputationMode SWIFT_COMPILE_NAME("featureNotAvailableInCustomEntitlementsComputationMode") = 36, RCSignatureVerificationFailed SWIFT_COMPILE_NAME("signatureVerificationFailed") = 37, RCFeatureNotSupportedWithStoreKit1 SWIFT_COMPILE_NAME("featureNotSupportedWithStoreKit1") = 38, + RCInvalidWebPurchaseToken SWIFT_COMPILE_NAME("invalidWebPurchaseToken") = 39, + RCAlreadyRedeemedWebPurchaseToken SWIFT_COMPILE_NAME("alreadyRedeemedWebPurchaseToken") = 40, + RCExpiredWebPurchaseToken SWIFT_COMPILE_NAME("expiredWebPurchaseToken") = 41, }; static NSString * _Nonnull const RCPurchasesErrorCodeDomain = @"RevenueCat.ErrorCode"; @@ -1707,6 +1710,13 @@ SWIFT_CLASS("_TtC10RevenueCat24PostReceiptDataOperation") +SWIFT_CLASS("_TtC10RevenueCat30PostRedeemWebPurchaseOperation") +@interface PostRedeemWebPurchaseOperation : CacheableNetworkOperation +@end + + + + SWIFT_CLASS("_TtC10RevenueCat33PostSubscriberAttributesOperation") @interface PostSubscriberAttributesOperation : NetworkOperation @end @@ -1921,6 +1931,7 @@ SWIFT_CLASS_NAMED("PurchaserInfo") SWIFT_AVAILABILITY(macos,obsoleted=1,message= @protocol RCPurchasesDelegate; @class NSError; +@class RCWebPurchaseRedemption; /// Interface for Purchases. SWIFT_PROTOCOL_NAMED("PurchasesType") @@ -2619,6 +2630,16 @@ SWIFT_PROTOCOL_NAMED("PurchasesType") /// /// - (void)syncAttributesAndOfferingsIfNeededWithCompletionHandler:(void (^ _Nonnull)(RCOfferings * _Nullable, NSError * _Nullable))completionHandler SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=13.0) SWIFT_AVAILABILITY(macos,introduced=10.15) SWIFT_AVAILABILITY(ios,introduced=13.0); +/// Redeems a web purchase previously parsed from a deep link with Purchases/parseAsWebPurchaseRedemption(_:). +/// seealso: +/// Purchases/redeemWebPurchase(_:) +/// \param webPurchaseRedemption WebPurchaseRedemption object previously parsed from +/// a URL using Purchases/parseAsWebPurchaseRedemption(_:) +/// +/// \param completion The completion block to be called with the updated CustomerInfo +/// on a successful redemption, or the error if not. +/// +- (void)redeemWebPurchaseWithWebPurchaseRedemption:(RCWebPurchaseRedemption * _Nonnull)webPurchaseRedemption completion:(void (^ _Nonnull)(RCCustomerInfo * _Nullable, NSError * _Nullable))completion; - (void)setAttributes:(NSDictionary * _Nonnull)attributes; @property (nonatomic) BOOL allowSharingAppStoreAccount SWIFT_DEPRECATED; - (void)setEmail:(NSString * _Nullable)email SWIFT_DEPRECATED; @@ -2780,6 +2801,9 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, copy) NSString * _No + + + SWIFT_AVAILABILITY(visionos,introduced=2.0) SWIFT_AVAILABILITY(watchos,introduced=11.0) SWIFT_AVAILABILITY(tvos,introduced=18.0) SWIFT_AVAILABILITY(macos,introduced=15.0) SWIFT_AVAILABILITY(ios,introduced=18.0) @interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) /// Returns the win-back offers that the subscriber is eligible for on the provided product. @@ -2794,9 +2818,6 @@ SWIFT_AVAILABILITY(visionos,introduced=2.0) SWIFT_AVAILABILITY(watchos,introduce @end - - - SWIFT_PROTOCOL("_TtP10RevenueCat29PurchasesOrchestratorDelegate_") @protocol PurchasesOrchestratorDelegate - (void)readyForPromotedProduct:(RCStoreProduct * _Nonnull)product purchase:(void (^ _Nonnull)(void (^ _Nonnull)(RCStoreTransaction * _Nullable, RCCustomerInfo * _Nullable, NSError * _Nullable, BOOL)))startPurchase; @@ -2852,6 +2873,35 @@ SWIFT_CLASS_NAMED("PlatformInfo") @end +@interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) +/// Enable debug logging. Useful for debugging issues with the lovely team @RevenueCat. +SWIFT_CLASS_PROPERTY(@property (nonatomic, class) BOOL debugLogsEnabled SWIFT_DEPRECATED_MSG("use Purchases.logLevel instead");) ++ (BOOL)debugLogsEnabled SWIFT_WARN_UNUSED_RESULT; ++ (void)setDebugLogsEnabled:(BOOL)newValue; +/// Deprecated +@property (nonatomic) BOOL allowSharingAppStoreAccount SWIFT_DEPRECATED_MSG("\n Configure behavior through the RevenueCat dashboard instead. If you have configured the \"Legacy\" restore\n behavior in the [RevenueCat Dashboard](app.revenuecat.com) and are currently setting this to `true`, keep\n this setting active.\n "); +/// Deprecated. Where responsibility for completing purchase transactions lies. +@property (nonatomic) BOOL finishTransactions SWIFT_DEPRECATED_MSG("Use ``purchasesAreCompletedBy`` instead."); +/// Deprecated ++ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network SWIFT_DEPRECATED_MSG("Use the set functions instead"); +/// Send your attribution data to RevenueCat so you can track the revenue generated by your different campaigns. +///

Related articles

+/// +/// \param data Dictionary provided by the network. +/// +/// \param network Enum for the network the data is coming from, see AttributionNetwork for supported +/// networks. +/// +/// \param networkUserId User Id that should be sent to the network. Default is the current App User Id. +/// ++ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network forNetworkUserId:(NSString * _Nullable)networkUserId SWIFT_DEPRECATED_MSG("Use the set functions instead"); +@end + + @interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) /// Configures an instance of the Purchases SDK with a specified Configuration. /// The instance will be set as a singleton. @@ -2950,35 +3000,10 @@ SWIFT_CLASS_NAMED("PlatformInfo") @interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) -/// Enable debug logging. Useful for debugging issues with the lovely team @RevenueCat. -SWIFT_CLASS_PROPERTY(@property (nonatomic, class) BOOL debugLogsEnabled SWIFT_DEPRECATED_MSG("use Purchases.logLevel instead");) -+ (BOOL)debugLogsEnabled SWIFT_WARN_UNUSED_RESULT; -+ (void)setDebugLogsEnabled:(BOOL)newValue; -/// Deprecated -@property (nonatomic) BOOL allowSharingAppStoreAccount SWIFT_DEPRECATED_MSG("\n Configure behavior through the RevenueCat dashboard instead. If you have configured the \"Legacy\" restore\n behavior in the [RevenueCat Dashboard](app.revenuecat.com) and are currently setting this to `true`, keep\n this setting active.\n "); -/// Deprecated. Where responsibility for completing purchase transactions lies. -@property (nonatomic) BOOL finishTransactions SWIFT_DEPRECATED_MSG("Use ``purchasesAreCompletedBy`` instead."); -/// Deprecated -+ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network SWIFT_DEPRECATED_MSG("Use the set functions instead"); -/// Send your attribution data to RevenueCat so you can track the revenue generated by your different campaigns. -///

Related articles

-/// -/// \param data Dictionary provided by the network. -/// -/// \param network Enum for the network the data is coming from, see AttributionNetwork for supported -/// networks. -/// -/// \param networkUserId User Id that should be sent to the network. Default is the current App User Id. -/// -+ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network forNetworkUserId:(NSString * _Nullable)networkUserId SWIFT_DEPRECATED_MSG("Use the set functions instead"); -@end - - -@interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) +/// Parses a deep link URL to verify it’s a RevenueCat web purchase redemption link +/// seealso: +/// Purchases/redeemWebPurchase(_:) ++ (RCWebPurchaseRedemption * _Nullable)parseAsWebPurchaseRedemption:(NSURL * _Nonnull)url SWIFT_WARN_UNUSED_RESULT; @property (nonatomic, readonly, copy) NSString * _Nonnull appUserID; @property (nonatomic, readonly) BOOL isAnonymous; - (void)getOfferingsWithCompletion:(void (^ _Nonnull)(RCOfferings * _Nullable, NSError * _Nullable))completion; @@ -3241,6 +3266,8 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class) BOOL automaticAppleSearchAdsAt - (void)eligiblePromotionalOffersForProduct:(RCStoreProduct * _Nonnull)product completionHandler:(void (^ _Nonnull)(NSArray * _Nonnull))completionHandler; - (void)showManageSubscriptionsWithCompletion:(void (^ _Nonnull)(NSError * _Nullable))completion SWIFT_AVAILABILITY(macos,introduced=10.15) SWIFT_AVAILABILITY(ios,introduced=13.0) SWIFT_AVAILABILITY(tvos,unavailable) SWIFT_AVAILABILITY(watchos,unavailable); - (void)showManageSubscriptionsWithCompletionHandler:(void (^ _Nonnull)(NSError * _Nullable))completionHandler SWIFT_AVAILABILITY(macos,introduced=10.15) SWIFT_AVAILABILITY(ios,introduced=13.0) SWIFT_AVAILABILITY(tvos,unavailable) SWIFT_AVAILABILITY(watchos,unavailable); +/// Warning: This is currently experimental and subject to change. +- (void)redeemWebPurchaseWithWebPurchaseRedemption:(RCWebPurchaseRedemption * _Nonnull)webPurchaseRedemption completion:(void (^ _Nonnull)(RCCustomerInfo * _Nullable, NSError * _Nullable))completion; @end /// Where responsibility for completing purchase transactions lies. @@ -3331,6 +3358,7 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong, getter=defau @end + @interface RCPurchasesDiagnostics (SWIFT_EXTENSION(RevenueCat)) /// Perform tests to ensure SDK is configured correctly. ///
    @@ -3344,7 +3372,6 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong, getter=defau - /// A type that can parse Apple receipts from a device. /// This implements parsing based on Apple’s documentation. /// To use this class you must access PurchasesReceiptParser/default: @@ -3928,6 +3955,17 @@ typedef SWIFT_ENUM_NAMED(NSInteger, RCVerificationResult, "VerificationResult", }; +/// Class representing a web redemption deep link that can be redeemed by the SDK. +/// Warning: This is currently experimental and subject to change. +/// seealso: +/// Purchases/redeemWebPurchase(_:) +SWIFT_CLASS_NAMED("WebPurchaseRedemption") +@interface RCWebPurchaseRedemption : NSObject +- (nonnull instancetype)init SWIFT_UNAVAILABLE; ++ (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable"); +@end + + /// Represents an Apple win-back offer. SWIFT_CLASS_NAMED("WinBackOffer") @interface RCWinBackOffer : NSObject