Skip to content

VideoSubscriberAccount iOS xcode26.0 b1

Rolf Bjarne Kvinge edited this page Aug 29, 2025 · 3 revisions

#VideoSubscriberAccount.framework https://github.com/dotnet/macios/pull/23710

diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInAuthorization.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInAuthorization.h --- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInAuthorization.h	1969-12-31 19:00:00 +++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInAuthorization.h	2025-05-25 02:38:00 @@ -0,0 +1,22 @@ +// +// VSAutoSignInAuthorization.h +// VideoSubscriberAccount +// +// Created by Felipe (fcy) Cypriano on 2/26/25. +// Copyright © 2025 Apple Inc. All rights reserved. +// + +#import <VideoSubscriberAccount/VideoSubscriberAccountDefines.h> +#import <Foundation/Foundation.h> + + +/// Auto sign in authorization state. +typedef NS_ENUM(NSInteger, VSAutoSignInAuthorization) { + /// Consent to auto sign in hasn't been granted nor denied. + VSAutoSignInAuthorizationNotDetermined = 0, + /// Authorized to store and use auto sign in tokens. + VSAutoSignInAuthorizationGranted, + /// Consent to use auto sign in has been denied. + VSAutoSignInAuthorizationDenied +} NS_REFINED_FOR_SWIFT API_AVAILABLE(ios(26.0), tvos(26.0), macos(26.0), visionos(26.0)) API_UNAVAILABLE(watchos, macCatalyst); + diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInToken.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInToken.h --- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInToken.h	1969-12-31 19:00:00 +++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInToken.h	2025-05-25 02:38:00 @@ -0,0 +1,30 @@ +// +// VSAutoSignInToken.h +// VideoSubscriberAccountFramework +// +// Created by Felipe (fcy) Cypriano on 3/11/25. +// Copyright © 2025 Apple Inc. All rights reserved. +// + +#import <Foundation/Foundation.h> +#import <VideoSubscriberAccount/VideoSubscriberAccountDefines.h> + + +#import <VideoSubscriberAccount/VSAutoSignInAuthorization.h> + +NS_ASSUME_NONNULL_BEGIN + +API_AVAILABLE(ios(26.0), tvos(26.0), macos(26.0), visionos(26.0)) API_UNAVAILABLE(watchos, macCatalyst) +NS_REFINED_FOR_SWIFT +@interface VSAutoSignInToken : NSObject <NSSecureCoding> + +@property (nonatomic, readonly) VSAutoSignInAuthorization authorization; +@property (nonatomic, readonly, nullable) NSString *value; + +- (instancetype)init NS_UNAVAILABLE; ++ (instancetype)new NS_UNAVAILABLE; + +@end + +NS_ASSUME_NONNULL_END + diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInTokenUpdateContext.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInTokenUpdateContext.h --- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInTokenUpdateContext.h	1969-12-31 19:00:00 +++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSAutoSignInTokenUpdateContext.h	2025-05-25 02:38:00 @@ -0,0 +1,32 @@ +// +// VSAutoSignInTokenUpdateContext.h +// VideoSubscriberAccountFramework +// +// Created by Felipe (fcy) Cypriano on 2/26/25. +// Copyright © 2025 Apple Inc. All rights reserved. +// + +#import <Foundation/Foundation.h> +#import <VideoSubscriberAccount/VideoSubscriberAccountDefines.h> + + +#import <VideoSubscriberAccount/VSAutoSignInAuthorization.h> + +NS_ASSUME_NONNULL_BEGIN + +/// Context object used to update the auto sign in token. +/// This object has to be obtained through a user consent flow using `-[VSUserAccountManager requestAutoSignInAuthorizationWithCompletionHandler:]`, +/// then it is passed to `-[VSUserAccountManager updateAutoSignInToken:updateContext:completionHandler:]` +VS_EXPORT API_AVAILABLE(ios(26.0), tvos(26.0)) API_UNAVAILABLE(macos, watchos, macCatalyst, visionos) +NS_REFINED_FOR_SWIFT +@interface VSAutoSignInTokenUpdateContext : NSObject + +@property (nonatomic, readonly) VSAutoSignInAuthorization authorization; + +- (instancetype)init NS_UNAVAILABLE; ++ (instancetype)new NS_UNAVAILABLE; + +@end + +NS_ASSUME_NONNULL_END + diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSSubscription.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSSubscription.h --- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSSubscription.h	2025-04-19 05:18:12 +++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSSubscription.h	2025-05-25 02:38:00 @@ -21,12 +21,12 @@ VSSubscriptionAccessLevelUnknown, /// The default access level. Setting a subscription with this level will raise an exception. VSSubscriptionAccessLevelFreeWithAccount, /// The customer has access to content that is offered for free to users with a valid account. This value corresponds content in your availability feed with the "account" offering type. VSSubscriptionAccessLevelPaid, /// The customer also has access to content that is offered as part of a paid subscription. The value corresponds content in your availability feed with the "subscription" offering type. -} API_DEPRECATED_WITH_REPLACEMENT("VSUserAccountType", ios(11.0, 18.0), tvos(11.0, 18.0), visionos(1.0, 2.0)) API_UNAVAILABLE(macCatalyst); +} API_DEPRECATED("Use VSUserAccount and VSUserAccountType instead.", ios(11.0, 18.0), tvos(11.0, 18.0), visionos(1.0, 2.0)) API_UNAVAILABLE(macCatalyst); /// A VSSubscription instance describes the extent to which a subscriber has /// access to content. -VS_EXPORT API_DEPRECATED_WITH_REPLACEMENT("VSUserAccount", ios(11.0, 18.0), tvos(11.0, 18.0), visionos(1.0, 2.0)) API_UNAVAILABLE(macCatalyst) - @interface VSSubscription : NSObject +VS_EXPORT API_DEPRECATED("Use VSUserAccount instead.", ios(11.0, 18.0), tvos(11.0, 18.0), visionos(1.0, 2.0)) API_UNAVAILABLE(macCatalyst) +@interface VSSubscription : NSObject /// After this point in time, the subscription will be considered inactive. /// diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSUserAccountManager.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSUserAccountManager.h --- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSUserAccountManager.h	2025-04-19 05:18:12 +++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VSUserAccountManager.h	2025-05-25 08:23:24 @@ -10,7 +10,10 @@ #import <Foundation/Foundation.h> - +@class VSAutoSignInToken; +#if ((TARGET_OS_IOS && !TARGET_OS_MACCATALYST && !TARGET_OS_VISION) || TARGET_OS_TV) +@class VSAutoSignInTokenUpdateContext; +#endif // ((TARGET_OS_IOS && !TARGET_OS_MACCATALYST && !TARGET_OS_VISION) || TARGET_OS_TV) @class VSUserAccount; NS_ASSUME_NONNULL_BEGIN @@ -33,6 +36,38 @@ // device only. To query the VSUserAccounts registered on all of the devices signed into the // users iCloud account, use the query flag VSUserAccountQueryAllDevices. - (void)queryUserAccountsWithOptions:(VSUserAccountQueryOptions)options completion:(void (^)(NSArray<VSUserAccount *> * _Nullable accounts, NSError * _Nullable error))completion NS_REFINED_FOR_SWIFT; + + +// MARK: Auto Sign In + +/// Query the auto sign in token and authorization state. +- (void)queryAutoSignInTokenWithCompletionHandler:(void(^)(VSAutoSignInToken *_Nullable token, NSError *_Nullable error))completion NS_REFINED_FOR_SWIFT API_AVAILABLE(ios(26.0), tvos(26.0), macos(26.0), visionos(26.0)) API_UNAVAILABLE(watchos, macCatalyst); + +#if (TARGET_OS_IOS && !TARGET_OS_MACCATALYST && !TARGET_OS_VISION) || TARGET_OS_TV + +/// Request user authorization to store and use an auto sign in token. An UI prompt will be shown to the user to confirm this action. +/// Make sure to only call this method after your app is signed in: +/// - If the app is already authenticated, check the authorization status by calling `queryAutoSignInTokenWithCompletionHandler:` and only request +/// authorization if the authorization value is `VSAutoSignInAuthorizationNotDetermined`. +/// - If the user is signing in for the first time, or after going through the manual sign in flow again, you should always request authorization. +/// +/// @return A `VSAutoSignInTokenUpdateContext` that you pass to `updateAutoSignInToken:updateContext:completionHandler:`. +- (void)requestAutoSignInAuthorizationWithCompletionHandler:(void(^)(VSAutoSignInTokenUpdateContext *_Nullable updateContext, NSError *_Nullable error))completion NS_REFINED_FOR_SWIFT API_AVAILABLE(ios(26.0), tvos(26.0)) API_UNAVAILABLE(macos, watchos, macCatalyst, visionos); + +/// Sets the auto sign in token. +/// You're in full control of your token, it doesn't have any implied expiration dates. Use +/// `-[VSUserAccountManager deleteAutoSignInTokenWithCompletionHandler:]` if you need to remove an old token. +/// +/// Before calling this method you have to obtain an update context object using +/// `-[VSUserAccountManager requestAutoSignInAuthorizationWithCompletionHandler:]`. Updating the token will fail if the user hasn't +/// granted authorization. +- (void)updateAutoSignInToken:(NSString *)autoSignInToken updateContext:(VSAutoSignInTokenUpdateContext *)context completionHandler:(void(^)(NSError *_Nullable error))completion NS_REFINED_FOR_SWIFT API_AVAILABLE(ios(26.0), tvos(26.0)) API_UNAVAILABLE(macos, watchos, macCatalyst, visionos); + +#endif // (TARGET_OS_IOS && !TARGET_OS_MACCATALYST && !TARGET_OS_VISION) || TARGET_OS_TV + +/// Deletes the auto sign in token. +- (void)deleteAutoSignInTokenWithCompletionHandler:(void(^)(NSError *_Nullable error))completion NS_REFINED_FOR_SWIFT API_AVAILABLE(ios(26.0), tvos(26.0), macos(26.0), visionos(26.0)) API_UNAVAILABLE(watchos, macCatalyst); + @end diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VideoSubscriberAccount.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VideoSubscriberAccount.h --- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VideoSubscriberAccount.h	2025-04-19 05:18:11 +++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/VideoSubscriberAccount.framework/Headers/VideoSubscriberAccount.h	2025-05-25 02:37:59 @@ -12,6 +12,9 @@ #import <VideoSubscriberAccount/VSAccountMetadataRequest.h> #import <VideoSubscriberAccount/VSAccountProviderResponse.h> #import <VideoSubscriberAccount/VSAppleSubscription.h> +#import <VideoSubscriberAccount/VSAutoSignInAuthorization.h> +#import <VideoSubscriberAccount/VSAutoSignInToken.h> +#import <VideoSubscriberAccount/VSAutoSignInTokenUpdateContext.h> #import <VideoSubscriberAccount/VSSubscription.h> #import <VideoSubscriberAccount/VSSubscriptionRegistrationCenter.h> #import <VideoSubscriberAccount/VSUserAccount.h> 
Clone this wiki locally