All notable changes to this project are documented in this file.
This project adheres to Semantic Versioning.
:warning: Be Advised :warning: |
---|
<p>We have begun rewriting the iOS SDK in Swift in order to modernize the code base.</p><p>Please monitor the changelog for updates to existing interfaces but keep in mind that some interfaces will be unstable during this process. As such, updating to a minor version may introduce compilation issues related to language interoperability.</p>Please bear with us as we work towards providing an improved experience for integrating with the Facebook platform. |
.graphAPIDebugInfo
logging behavior.AppLinkNavigation.Type
type has been renamed tp AppLinkNavigationType
.init(appLink:extras:appLinkData:settings:)
in AppLinkNavigation
ignores the settings
argument if one is passed.navigation(with:extras:appLinkData:settings:)
in AppLinkNavigation
ignores the settings
argument if one is passed.navigation(with:extras:appLinkData:settings:)
method in AppLinkNavigation
is deprecated in favor of the init(appLink:extras:appLinkData:)
designated init.init(appLink:extras:appLinkData:settings:)
initializer in AppLinkNavigation
is deprecated in favor of the init(appLink:extras:appLinkData:)
designated init.Profile.enableUpdatesOnAccessTokenChange(_:)
method is deprecated in favor of the Profile.isUpdatedWithAccessTokenChange
property.SettingsProtocol.codelessDebugLogEnabled
is deprecated in favor of SettingsProtocol.isCodelessDebugLogEnabled
.SettingsProtocol.advertiserIDCollectionEnabled
is deprecated in favor of SettingsProtocol.isAdvertiserIDCollectionEnabled
.SettingsProtocol.advertiserTrackingEnabled
is deprecated in favor of SettingsProtocol.isAdvertiserTrackingEnabled
.SettingsProtocol.graphAPIDebugParamValue
is deprecated in favor of its new name SettingsProtocol.graphAPIDebugParameterValue
Settings.autoLogAppEventsEnabled
is deprecated in favor of Settings.isAutoLogAppEventsEnabled
.SettingsProtocol.graphAPIDebugParamValue
has been renamed to SettingsProtocol.graphAPIDebugParameterValue
Profile
conformance to NSCopying
has been removed as well as custom hashability and equatability.Settings.isCodelessDebugLogEnabled
has been corrected to indicate that the default value is false
.AEMReporter.configure(networker:appID:)
method.ContextDialogPresenter.showCreateContextDialog(withContent:delegate:)
method.ContextDialogPresenter.showSwitchContextDialog(withContent:delegate:)
method.ContextDialogPresenter.showChooseContextDialog(withContent:delegate:)
method.ContextDialogPresenter.showChooseContextDialog(with:delegate:)
method.ContextDialogPresenter.createContextDialog(withContent:delegate:)
method.ContextDialogPresenter.switchContextDialog(withContent:delegate:)
method.SwitchContextDialog.dialog(content:windowFinder:delegate:)
method.LoginConfiguration.authType(for:)
method.AuthenticationTokenSettings
protocol.LoginManagerLoginResult.token
immutable.LoginManagerLoginResult.authenticationToken
immutable.LoginManagerLoginResult.isCancelled
immutable.LoginManagerLoginResult.grantedPermissions
immutable.LoginManagerLoginResult.declinedPermissions
immutable.AccessToken.currentAccessToken
use a Swift name of current
.AuthenticationToken.currentAuthenticationToken
use a Swift name of current
.SharingValidation
protocol to SharingValidatable
.FBSDKUserIdentifier
to be NSString *
instead of NSString
for Swift compatibility.The minimum supported version of iOS is now 11.0 for all frameworks. The minimum supported version of tvOS is now 11.0 for all frameworks. The XCFramework binaries are now built with Xcode 13 so Xcode 12 is no longer supported.
Starting with the v13.0 release, client tokens must be included in apps for Graph API calls. An exception is now raised when running apps without a client token. See the instructions for more information.
A number of types have been converted from Objective-C to Swift. As a consequence, developers may need to use modular import statements when using GamingServicesKit and a majority of ShareKit in order to avoid encountering compilation errors in Objective-C.
// When importing a framework in this form:
#import <FBSDKShareKit/FBSDKShareKit.h>
// You may be need to update to this form when unknown symbol warnings appear:
@import FBSDKShareKit;
We have further reduced the use of Objective-C value-type practices in ShareKit. ShareKit content types will no longer implement the following behaviors:
NSCopying
protocolNSSecureCoding
More app event reporting interfaces now use formal app event names and parameter names. Developers working in Swift code are required to use AppEvents.Name
and AppEvents.ParameterName
instances to represent app event names and app event parameter names, respectively.
The example below works without changes in Objective-C:
NSDictionary<NSString *, id> *parameters = @{
FBSDKAppEventParameterNameNumItems: @5,
@"custom_parameter": @"special info"
};
[FBSDKAppEvents logEvent:FBSDKAppEventNamePurchased
parameters:parameters];
This next example is how it would look in Swift for an updated API:
let parameters: [AppEvents.ParameterName: Any] = [
.numItems: 5,
.init("custom_parameter"): "special info"
]
AppEvents.logEvent(.purchased, parameters: parameters)
frictionlessRequestsEnabled
property on GameRequestDialog
in Objective-C; use isFrictionlessRequestsEnabled
and setIsFrictionlessRequestsEnabled:
instead.contentURL
in protocol SharingContent
AppInviteDestination
to AppInviteContent.Destination
userGenerated
property on SharePhoto
in Objective-C; use isUserGenerated
and setIsUserGenerated:
instead.FacebookGamingServices
CocoaPod; please use the FBSDKGamingServicesKit
pod instead. SPM users should continue to use FacebookGamingServices
.A few types have been moved from FBSDKShareKit to FBSDKGamingServicesKit. If you were using any of these you will have to add @import FBSDKGamingServicesKit
in order to access these:
NSObjectProtocol
conformance/inheritance from multiple types in ShareKit.SDKError
type; ErrorFactory
and/or NetworkErrorChecker
should be used instead.ReferralCode
, ReferralManager
, ReferralManagerResult
and related classes.AppGroupContent
class, AppGroupPrivacy
enum and NSStringFromFBSDKAppGroupPrivacy
function.SharingScheme
protocol from ShareKitlogInWithURL:handler
from LoginManager
init
and new
methods from AppInviteContent
AppLinkResolverRequestBuilder
.facebookApp
, .facebookShareExtension
and .masqueradePlayer
; use .facebookAPI
instead.init
and new
methods from CrashHandler
init
and new
methods from MessageDialog
; use init(content:delegate:)
instead.init
and new
methods from Logger
init
and new
methods from FBSDKURLSession
init
and new
methods from ShareDialog
; use init(viewController:content:delegate:)
instead.init
and new
from ShareCameraEffectContent
; use init(effectID:contentURL:)
instead.init(appLink:extras:appLinkData:)
from AppLinkNavigation
; use init(appLink:extras:appLinkData:settings:)
instead”.SharePhoto
:
+photoWithImage:userGenerated:
, +photoWithImageURL:userGenerated:
, +photoWithPhotoAsset:userGenerated:
. Also removed init
and new
; use the new convenience initializers instead.ShareVideo
: +videoWithData:
, +videoWithData:previewPhoto:
, +videoWithVideoAsset:
, +videoWithVideoAsset:previewPhoto:
, +videoWithVideoURL:
, +videoWithVideoURL:previewPhoto:
. Also removed init
and new
; use the new convenience initializers instead.videoURL
property from PHAsset
.isEqualToHashtag:
and hashtagWithString:
methods from Hashtag. Use isEqual:
and initWithString:
instead.Use AppEvents.shared
in places where AppEvents
was used before. (Many class methods and properties in AppEvents have been deprecated in favor of their instance-based equivalents.)
AppEvents.flushBehavior
(use AppEvents.shared.flushBehavior
instead)AppEvents.loggingOverrideAppID
(use AppEvents.shared.loggingOverrideAppID
instead)AppEvents.userID
(use AppEvents.shared.userID
instead)AppEvents.anonymousID
(use AppEvents.shared.anonymousID
instead)AppEvents.logEvent(_:)
(use AppEvents.shared.logEvent(_:)
instead)AppEvents.logEvent(_:valueToSum:)
(use AppEvents.shared.logEvent(_:valueToSum:)
instead)AppEvents.logEvent(_:parameters:)
(use AppEvents.shared.logEvent(_:parameters:)
instead)AppEvents.logEvent(_:valueToSum:parameters:)
(use AppEvents.shared.logEvent(_:valueToSum:parameters:)
instead)AppEvents.logEvent(_:valueToSum:parameters:accessToken:)
(use AppEvents.shared.logEvent(_:valueToSum:parameters:accessToken:)
instead)AppEvents.logPurchase(_:currency:)
(use AppEvents.shared.logPurchase(amount:currency:)
instead)AppEvents.logPurchase(_:currency:parameters:)
(use AppEvents.shared.logPurchase(amount:currency:parameters:)
instead)AppEvents.logPurchase(_:currency:parameters:accessToken:)
(use AppEvents.shared.logPurchase(amount:currency:parameters:accessToken:)
instead)AppEvents.logPushNotificationOpen(_:)
(use AppEvents.shared.logPushNotificationOpen(payload:)
instead)AppEvents.logPushNotificationOpen(_:action:)
(use AppEvents.shared.logPushNotificationOpen(payload:action:)
instead)AppEvents.logProductItem(_:availability:condition:description:imageLink:link:title:priceAmount:currency:gtin:mpn:brand:parameters:)
(use AppEvents.shared.logProductItem(id:availability:condition:description:imageLink:link:title:priceAmount:currency:gtin:mpn:brand:parameters:)
instead)AppEvents.setPushNotificationsDeviceToken(_:)
(use AppEvents.shared.setPushNotificationsDeviceToken(_:)
instead)AppEvents.setPushNotificationsDeviceToken(_:)
(use AppEvents.shared.setPushNotificationsDeviceToken(_:)
instead)AppEvents.flush()
(use AppEvents.shared.flush()
instead)AppEvents.requestForCustomAudienceThirdPartyID(with:)
(use AppEvents.shared.requestForCustomAudienceThirdPartyID(accessToken:)
instead)AppEvents.clearUserID
is deprecated and will be removed in the next major release, please set AppEvents.shared.userID
to nil
instead)AppEvents.augmentHybridWKWebView(_:)
(use AppEvents.shared.augmentHybridWebView(_:)
instead)AppEvents.setIsUnityInit(_:)
(use AppEvents.shared.setIsUnityInitialized(_:)
instead)AppEvents.sendEventBindingsToUnity()
(use AppEvents.shared.sendEventBindingsToUnity()
instead)AppEvents.setUser(email:firstName:lastName:phone:dateOfBirth:gender:city:state:zip:country:)
(use AppEvents.shared.setUser(email:firstName:lastName:phone:dateOfBirth:gender:city:state:zip:country:)
instead)AppEvents.clearUserData()
(use AppEvents.shared.clearUserData()
instead)AppEvents.getUserData()
(use AppEvents.shared.getUserData()
instead)AppEvents.setUserData(_:forType:)
(use AppEvents.shared.setUserData(_:forType:)
instead)AppEvents.clearUserDataForType(_:)
(use AppEvents.shared.clearUserDataForType(_:)
instead)Use Settings.shared
in places where Settings
was used before. (Many class methods and properties in FBSDKSettings have been deprecated in favor of their instance-based equivalents.)
Settings.sdkVersion
(use Settings.shared.sdkVersion
instead”)Settings.defaultGraphAPIVersion
(use Settings.shared.defaultGraphAPIVersion
instead”)Settings.JPEGCompressionQuality
(use Settings.shared.JPEGCompressionQuality
instead”)Settings.isAutoLogAppEventsEnabled
(use Settings.shared.isAutoLogAppEventsEnabled
instead”)Settings.isCodelessDebugLogEnabled
(use Settings.shared.isCodelessDebugLogEnabled
instead”)Settings.isAdvertiserIDCollectionEnabled
(use Settings.shared.isAdvertiserIDCollectionEnabled
instead”)Settings.isSKAdNetworkReportEnabled
(use Settings.shared.isSKAdNetworkReportEnabled
instead”)Settings.shouldLimitEventAndDataUsage
(use Settings.shared.isEventDataUsageLimited
instead”)Settings.shouldUseCachedValuesForExpensiveMetadata
(use Settings.shared.shouldUseCachedValuesForExpensiveMetadata
instead”)Settings.isGraphErrorRecoveryEnabled
(use Settings.shared.isGraphErrorRecoveryEnabled
instead”)Settings.appID
(use Settings.shared.appID
instead”)Settings.appURLSchemeSuffix
(use Settings.shared.appURLSchemeSuffix
instead”)Settings.clientToken
(use Settings.shared.clientToken
instead”)Settings.displayName
(use Settings.shared.displayName
instead”)Settings.facebookDomainPart
(use Settings.shared.facebookDomainPart
instead”)Settings.loggingBehaviors
(use Settings.shared.loggingBehaviors
instead”)Settings.graphAPIVersion
(use the Settings.shared.graphAPIVersion
property instead”)Settings.isAdvertiserTrackingEnabled()
(use the Settings.shared.isAdvertiserTrackingEnabled
property instead”)Settings.setAdvertiserTrackingEnabled(_:)
(use the Settings.shared.isAdvertiserTrackingEnabled
property to set a value instead”)Settings.setDataProcessingOptions(_:)
(use the Settings.shared.setDataProcessingOptions(_:)
method to set the data processing options instead”)Settings.setDataProcessingOptions(_:_:_:)
(use the Settings.shared.setDataProcessingOptions(_:_:_:)
method to set the data processing options instead”)Settings.enableLoggingBehavior()
(use Settings.shared.enableLoggingBehavior()
instead”)Settings.disableLoggingBehavior()
(use Settings.shared.disableLoggingBehavior()
instead”)This release contains various fixes for FBAEMKit
defaultComponents
accessor for CoreKitComponents
. Fixes issue #2010.NetworkErrorChecking
) and concrete implementation (NetworkErrorChecker
)ErrorCreating
) and concrete implementation (ErrorFactory
)configureWithWebViewProvider:urlOpener:
from FBSDKWebDialogView
SDKError
has been deprecated in favor of the new ErrorFactory
and NetworkErrorChecker
typesNSStringFromFBSDKShareDialogMode()
has been deprecated in favor of ShareDialog.Mode.description
ObjC
linker flag (issue #1972)Note: There is a known issue with using the ObjC
linker flag with this version. We are working on a patch fix. If you rely on the ObjC
linker flag, you will want to wait for the patch fix before upgrading.
LSApplicationQueriesSchemes
for their Info.plist
. Only the fbapi
and fb-messenger-share-api
custom URL schemes are needed. With the change to iOS 15 that limits LSApplicationQueriesSchemes
to 50 schemes, this should relieve some pressure that apps may face when running up against this limit. As part of this change the following symbols are deprecated:
URLScheme.facebookApp
URLScheme.facebookShareExtension
URLScheme.masqueradePlayer
ApplicationDelegate
where added application observers were notified twice for application:didFinishLaunchingWithOptions:
.
The return type of ApplicationDelegate.application:didFinishLaunchingWithOptions:
was also incorrectly stated as, “YES if the url was intended for the Facebook SDK, NO if not”. In actuality, the method returns whether there are any application observers that themselves return true from calling their implementation of application:didFinishLaunchingWithOptions:
.
This fix means that application observers will now only be notified once per app launch, however, if ApplicationDelegate.application:didFinishLaunchingWithOptions:
is called after calling ApplicationDelegate.initializeSDK
then the return type will always be false regardless of any application observers.AppEvents
has been deprecated. Please use the instance properties and methods on AppEvents.shared
instead.FBSDKReferralCode
, FBSDKReferralManager
and FBSDKReferralManagerResult
are deprecated and will be removed in v13.0.0Note: Binaries for v12.0.1 were built with Xcode 13 and will not work with Xcode 12. See #1911. Use release v12.0.2 instead.
Starting with version 12.0.0, CocoaPods and Swift Package Manager (SPM) are vending pre-built XCFrameworks. You no longer need to build the SDK when using CocoaPods or SPM, which should save you between a few seconds and a few minutes per build.
Because XCFrameworks do not allow embedded frameworks, note the following:
FacebookAEM
and FacebookBasics
even though you won’t use them directly.You can no longer build from source using Carthage. Instead use Carthage to obtain the pre-built XCFrameworks. For instructions, see: https://github.com/Carthage/Carthage#migrating-a-project-from-framework-bundles-to-xcframeworks.
For more details, see https://developers.facebook.com/docs/ios/getting-started.
🚨 IMPORTANT 🚨
Changes to FBSDKLoginButton
when defined in a Storyboard or XIB file: There is a known issue with using XCFrameworks in conjunction with Storyboard or XIB files. If you do not follow the instructions for using Interface Builder at https://developers.facebook.com/docs/facebook-login/ios/advanced/, FBSDKLoginButton
does not load or decorate correctly. Add [FBSDKLoginButton class]
to application:didFinishLaunchingWithOptions:
so that the Storyboard can find it. If you don’t, any methods that you call on it may result in a runtime crash.
AppEvents
(given the property name shared
) to start moving away from a class-based interface.FacebookGamingServices
and FBSDKGamingServicesKit
— There are two libraries related to Gaming Services. FBSDKGamingServicesKit
is a superset of FacebookGamingServices
that includes Objective-C wrapper classes for FBSDKContextDialogPresenter
and FBSDKContextDialogPresenter
. If you don’t need an Objective-C interface for these types,
we recommend that you use only FacebookGamingServices
.The following table contains changes to the iOS SDK in version 12.0.0.
Removed or Changed | Version 12.0.0 Replacement or Change |
---|---|
AccessToken convenience initializers that include graphDomain |
— |
AccessToken.graphDomain class property. |
AccessToken.graphDomain instance property. |
AccessToken.refreshCurrentAccessToken(completionHandler:) |
AccessToken.refreshCurrentAccessToken(completion:) |
AppEvents.activateApp class method. |
AppEvents.activateApp instance method that you access on the AppEvents.shared instance. |
FBSDKGraphErrorRecoveryProcessor - you can no longer create new instances without using designated initializers. |
— |
GamingContext.type |
— |
GamingImageUploader.uploadImage(configuration:andResultCompletionHandler:) |
GamingImageUploader.uploadImage(configuration:andResultCompletion:) |
GamingImageUploader.uploadImage(configuration:completionHandler:andProgressHandler:) |
GamingImageUploader.uploadImage(configuration:completion:andProgressHandler:) |
GamingPayload.gameRequestID |
You can obtain the game request ID from GamingPayloadDelegate.parsedGameRequestURLContaining(_:gameRequestID:) |
GamingPayloadDelegate.updatedURLContaining(_:) |
GamingPayloadDelegate.parsedGameRequestURLContaining(_:gameRequestID:) |
GamingPayloadObserver.shared |
You must now create instances of this object by using a delegate. |
GamingServiceResultCompletionHandler |
GamingServiceResultCompletion |
GamingVideoUploader.uploadVideo(configuration:andResultCompletionHandler:) |
GamingVideoUploader.uploadVideo(configuration:andResultCompletion:) |
GamingVideoUploader.uploadVideo(configuration:completionHandler:andProgressHandler:) |
GamingVideoUploader.uploadVideo(configuration:completion:andProgressHandler:) |
GraphRequest.start(completionHandler:) |
GraphRequest.start(completion:) |
GraphRequestBlock |
GraphRequestCompletion |
GraphRequestConnection.add(_:completionHandler:) |
GraphRequestConnection.add(_:completion:) |
GraphRequestConnection.add(_:batchEntryName:completionHandler:) |
GraphRequestConnection.add(_:name:completion:) |
GraphRequestConnection.add(_:batchParameters:completionHandler:) |
GraphRequestConnection.add(_:parameters:completion:) |
initializeSDK
method to FBSDKApplicationDelegate
generate-projects.sh
to ensure that the project files they are using are the same as those being used in CI and for releases. The next major version will remove the project files from version control. If you experience any of these issues, please open an issue and we will look into it..xcodeproj
file. We are planning to remove the .xcodeproj
files in the next major release as they will be generated on an as needed basis using Xcodegen. There is a strong likelihood that this change will break several integrations that use Carthage. You will still be able to use Carthage by pulling the pre-built binaries or XCFrameworks directly from the release. If this does not work for your use case, we recommend checking out Swift Package Manager as an alternative.GamingServiceResultCompletionHandler
. Replaced by GamingServiceResultCompletion
which passes a dictionary instead of a string for the result. Additionally the following methods have been updated:
uploadImageWithConfiguration:andResultCompletionHandler
is replaced by uploadImageWithConfiguration:andResultCompletion
uploadImageWithConfiguration:completionHandler:andProgressHandler
is replaced by uploadImageWithConfiguration:completion:andProgressHandler:
uploadVideoWithConfiguration:completionHandler:andProgressHandler:
is replaced by uploadVideoWithConfiguration:completion:andProgressHandler:
uploadVideoWithConfiguration:andResultCompletionHandler
is replaced by uploadVideoWithConfiguration:andResultCompletion
FBSDKGamingPayloadObserver
’s shared
instance. Going forward a user should create and retain their own instance of a payload observer for as long as they’d like to receive callbacks from its delegate.initializeSDK
deprecation #1731ATTENTION: The Platform SDK v11.0 release introduces a few key changes to how dependencies will be managed moving forward. These changes are being implemented to drive more efficiency in our development process and reduce an over-reliance on singletons and tight coupling.. As part of these changes, we are currently in the process of converting existing types to use injected dependencies. As a result, many types will no longer be usable until the SDK is initialized. In order to ensure that types are configured correctly before being used, you will need to call FBSDKApplicationDelegate.application:didFinishLaunchingWithOptions:
first before attempting to (i) get or set any properties, or (ii) invoke any methods on the SDK.
The source code has been updated to include reminders in the form of exceptions in DEBUG
builds across several locations. These reminders will serve as pointers for Developers to call FBSDKApplicationDelegate.application:didFinishLaunchingWithOptions:
before using the SDK. For more information see: https://github.com/facebook/facebook-ios-sdk/issues/1763.
AuthenticationToken
instance.user_hometown
, user_location
, user_gender
and user_link
permissions under public beta.user_messenger_contact
permission to enable Login Connect with Messenger. This new feature allows people to opt in to being contacted by a business on Messenger following the FB Login flow.messenger_page_id
param to FBSDKLoginButton
and FBSDKLoginConfiguration
FBSDKApplicationObserving
- a protocol for describing types that can optional respond to lifecycle events propagated by ApplicationDelegate
addObserver:
and removeObserver:
to FBSDKApplicationDelegate
startWithCompletion:
to FBSDKGraphRequest
. Replaces startWithCompletionHandler:
addRequest:completion
to FBSDKGraphRequestConnection
. Replaces addRequest:completionHandler:
.addRequest:name:completion:
to FBSDKGraphRequestConnection
. Replaces addRequest:batchEntryName:completionHandler:
.addRequest:parameters:completion:
to FBSDKGraphRequestConnection
. Replaces addRequest:batchParameters:completionHandler:
.activateApp
to AppEvents
.FBSDKGraphRequestBlock
. Replaced by FBSDKGraphRequestCompletion
which returns an abstract FBSDKGraphRequestConnection
in the form id<FBSDKGraphRequestConnecting>
(ObjC) or GraphRequestConnecting
(Swift)FBSDKGraphRequest
’s startWithCompletionHandler:
replaced by startWithCompletion:
FBSDKGraphRequestConnection
’s addRequest:completionHandler:
replaced by addRequest:completion:
FBSDKGraphRequestConnection
’s addRequest:batchEntryName:completionHandler:
replaced by addRequest:name:completion:
FBSDKGraphRequestConnection
’s addRequest:batchParameters:completionHandler:
replaced by addRequest:parameters:completion:
FBSDKGraphRequestBlock
AppEvents.activateApp
. It is replaced by an instance method of the same name.FBSDKApplicationDelegate.initializeSDK:launchOptions:
. The replacement method is FBSDKApplicationDelegate.application:didFinishLaunchingWithOptions:
FBSDKAppEvents
’ updateUserProperties:handler:
method.FBSDKAppEvents
’s updateUserProperties:handler:
method.FBSDKAppLinkReturnToRefererControllerDelegate
FBSDKAppLinkReturnToRefererController
FBSDKIncludeStatusBarInSize
FBSDKAppLinkReturnToRefererViewDelegate
FBAppLinkReturnToRefererView
FBSDKErrorRecoveryAttempting
’s attemptRecoveryFromError:optionIndex:delegate:didRecoverSelector:contextInfo:
FBSDKProfile
’s initWithUserID:firstName:middleName:lastName:name:linkURL:refreshDate:imageURL:email:
FBSDKProfile
’s initWithUserID:firstName:middleName:lastName:name:linkURL:refreshDate:imageURL:email:friendIDs:birthday:ageRange:isLimited:
FBSDKProfile
’s initWithUserID:firstName:middleName:lastName:name:linkURL:refreshDate:imageURL:email:friendIDs:
FBSDKProfile
’s initWithUserID:firstName:middleName:lastName:name:linkURL:refreshDate:imageURL:email:friendIDs:birthday:ageRange:
FBSDKAccessTokensBlock
FBSDKTestUsersManager
FBSDKGraphErrorRecoveryProcessor
’s delegate
propertyFBSDKGraphErrorRecoveryProcessor
’s didPresentErrorWithRecovery:contextInfo:
FBSDKGamingVideoUploader
’s uploadVideoWithConfiguration:andCompletionHandler:
FBSDKGamingImageUploader
’s uploadImageWithConfiguration:andCompletionHandler:
NOT RELEASED
Reason: The SDK is primarily a means of interacting with the Graph API. The decision was made to skip this version in order to maintain major version parity. Since Graph API is on v11, it did not make sense to release a v10 then immediately release a v11.
Performance Improvements
external_id
support in advanced matching.GamingServicesKit
changed the Game Request feature flow where if the user has the facebook app installed, they will not see a webview to complete a game request. Instead they will switch to the facebook app and app switch back once the request is sent or the user cancels the dialog.user_friends
, user_birthday
and user_age_range
permissions under public beta.birthday
and ageRange
fields using the claims from the AuthenticationToken
. (NOTE: birthday and ageRange fields are in public beta mode)Profile
as part of fixing a bug where upgrading from limited to regular login would fail to fetch the profile using the newly available access token.GamingServicesKit
added an observer class where if developers set the delegate we will trigger the delegate method with a GamingPayload
object if any urls contain gaming payload data. (NOTE: This feature is currently under development)Performance Improvements
didBecomeActive
ASIdentifierManager
to avoid dynamic loading on every didBecomeActive
Bug Fixes
generate_multiple_pod_projects
flag. #1707explicitOnly
.BITCODE_GENERATION_MODE = bitcode
to fix errors where Xcode is unable to build apps with bitcode enabled. #1698TestUsersManager
. The APIs that back this convenience type still exist but there is no compelling reason to have this be part of the core SDK. See the commit message for more on the rationale.AudioResourceLoader
.friendIDs
property added to FBSDKProfile
(NOTE: We are building out the friendIDs
property in Limited Login with the intention to roll it out in early spring)FBSDKProfile
initializer that includes optional friendIDs
argumentclaims
property of type FBSDKAuthenticationTokenClaims
added to FBSDKAuthenticationToken
FBSDKGraphErrorRecoveryProcessor
FBSDKURLSessionTask
AppEvents
singleton when setting overriding app ID #1647FBSDKDynamicFrameworkLoader
with ARC.FBSDKGraphErrorRecoveryProcessor
’s delegate
propertyFBSDKGraphErrorRecoveryProcessor
’s didPresentErrorWithRecovery:contextInfo:
methodFBSDKAppLinkReturnToRefererView
FBSDKAppLinkReturnToRefererController
FBSDKErrorRecoveryAttempter
We have a number of exciting changes in this release! For more information on the v9 release please read our associated blog post!
linkURL
property of FBSDKProfile
will only be populated if the user has granted the user_link
permission.FacebookSDK
now vendors XCFrameworks. Note: this may cause conflicts with other CocoaPods that have dependencies on the our libraries, ex: Audience Network. If you encounter a conflict it is easy to resolve by using one or more of the individual library pods instead of the aggregate pod.autoInitEnabled
option is removed from the SDK. From here on, developers are required to initialize the SDK explicitly with the initializeSDK
method or implicitly by calling it in applicationDidFinishLaunching
.FBSDKUserDataStore
as public for apps using Audience Network SDK only to use advanced matching.AppLinkResolverRequestBuilder
for use in cleaning up and adding tests around AppLinkResolver
AppLinkResolver
to use a request builderFBSDKProfile
and FBSDKProfilePictureView
FBSDKSettings
to use ADIdentifierManager
for tracking statusUI_USER_INTERFACE_IDIOM()
FBSDKVideoUploader
bug #1512setAdvertiserTrackingEnabled
to overwrite the advertiser_tracking_enabled
flagSKAdNetwork
support for installsSKAdNetwork
support for conversion value in iOS 14FBSDKReferralManager
for integrating with the web referral dialogloginWithURL
to FBSDKLoginManager
for supporting deep link authenticationsetAdvertiserTrackingEnabled
is called with false
in iOS 14FBSDKProfile - imageURLForPictureMode:size:
- User profile images will only be available when an access or client token is availableFBSDKSettings - isAutoInitEnabled
- Auto-initialization flag. Will be removed in the next major release. Future versions of the SDK will not utilize the + load
method to automatically initialize the SDK.🚨🚨🚨Attention! 🚨🚨🚨
This release fixes the ability to parse bad server configuration data. Please upgrade to at least this version to help avoid major outtages such as #1374 and #1427
NSJSONSerialization
methods to FBSDKTypeUtility
and changed callsitesenable()
function was called after the update()
functionFBSDKTypeUtility
to provide type safety for Dictionaries and ArraysNSKeyedUnarchiver
method calls will continue to work no matter what the iOS deployment target is set to.This primarily matters for how you include CocoaPods
Distribution Channel | Old way | New Way |
---|---|---|
CocoaPods | pod 'FBSDKCoreKit/Swift' |
pod 'FBSDKCoreKit' |
Swift Package Manager | No change | No change |
Carthage | No change | No change |
FBSDKMessageDialog now accepts FBSDKSharePhotoContent.
FBSDKGamingServicesKit/FBSDKGamingImageUploader.h
uploadImageWithConfiguration:andResultCompletionHandler:
uploadImageWithConfiguration:completionHandler:andProgressHandler:
FBSDKGamingServicesKit/FBSDKGamingVideoUploader.h
uploadVideoWithConfiguration:andResultCompletionHandler:
uploadVideoWithConfiguration:completionHandler:andProgressHandler:
FBSDKGamingServicesKit/FBSDKGamingImageUploader.h
uploadImageWithConfiguration:andCompletionHandler:
FBSDKGamingServicesKit/FBSDKGamingVideoUploader.h
uploadVideoWithConfiguration:andCompletionHandler:
Various bug fixes, CI improvements
FBSDKShareDialog
delegate callbacks on apps using iOS 13FBSDKMessengerActionButton
FBSDKShareMessengerGenericTemplateContent
FBSDKShareMessengerGenericTemplateElement
FBSDKShareMessengerMediaTemplateMediaType
FBSDKShareMessengerMediaTemplateContent
FBSDKShareMessengerOpenGraphMusicTemplateContent
FBSDKShareMessengerURLActionButton
FBSDKShareAPI
since it exists to make sharing of open graph objects easier. It also requires the deprecated publish_actions
permission which is deprecated.pageID
from FBSDKSharingContent
since it only applies to sharing to Facebook MessengerFBSDKShareOpenGraphAction
FBSDKShareOpenGraphContent
FBSDKShareOpenGraphObject
FBSDKShareOpenGraphValueContainer
FBSDKSettings
property instrumentEnabled
FBSDKAppEventNameSubscriptionHeartbeat
FBSDKLoginBehavior
Login flows no longer support logging in through the native application. This change reflects that.FBSDKCOCOAPODS
)use-frameworks!
)+[FBSDKSettings isInstrumentEnabled]
, please use +[FBSDKSettings isAutoLogEnabled]
insteadNS_DESIGNATED_INITIALIZER
for required initsNS_TYPED_EXTENSIBLE_ENUM
where made sensegetter
name for certain properties, like booleansNS_ASSUME_NONNULL_BEGIN
, NS_ASSUME_NONNULL_END
, and other nullability annotationsNS_SWIFT_NAME
to remove the FBSDK
prefix where necessary (left FB
prefix for UI elements)FBSDKLoginManager -logInWithPermissions:fromViewController:handler:
FBSDKLoginButton permissions
FBSDKDeviceLoginButton permissions
FBSDKDeviceLoginViewController permissions
FBSDKAppEventName
valuesinstancetype
for initsNSError **
translate to throws on Swiftreadonly
propertiesreadwrite
propertiesNS_REFINED_FOR_SWIFT
where advisableFBSDKLoginManager -logInWithReadPermissions:fromViewController:handler:
FBSDKLoginManager -logInWithWritePermissions:fromViewController:handler:
FBSDKLoginButton readPermissions
FBSDKLoginButton writePermissions
FBSDKDeviceLoginButton readPermissions
FBSDKDeviceLoginButton writePermissions
FBSDKDeviceLoginViewController readPermissions
FBSDKDeviceLoginViewController writePermissions
FBSDKUtility SHA256HashString
FBSDKUtility SHA256HashData
init
and new
unavailable where necessaryNS_SWIFT_UNAVAILABLE
where necessaryNS_TYPED_EXTENSIBLE_ENUM
attribute. All your existing code should work just fine.NS_SWIFT_NAME
was applied where applicable. Most of these changes Xcode can fix automatically.
FBSDK
prefix for UI elements has been replaced with the simpler FB
prefix.FBSDK
prefix for all other types has been removed.FBSDKError
is now CoreError
.NS_ERROR_ENUM
is used to handling errors now. For more details, view Apple’s documentation on
Handling Cocoa Errors in Swift.NS_TYPED_EXTENSIBLE_ENUM
attribute:
FBSDKAppEventNamePurchased
-> AppEvents.Name.purchased
"custom_app_event"
-> AppEvents.Name("custom_app_event")
NS_REFINED_FOR_SWIFT
and can be customized via either:
// Custom extensions
public extension AccessToken {
var permissions: Set<String> {
return Set(__permissions)
}
}
extension AppEvents.Name {
static let customAppEvent = AppEvents.Name("custom_app_event")
}
extension ShareDialog.Mode: CustomStringConvertible {
public var description: String {
return __NSStringFromFBSDKShareDialogMode(self)
}
}
// Later in code
let perms: Set<String> = AccessToken(...).permissions
let event: AppEvents.Name = .customAppEvent
let mode: ShareDialog.Mode = .native
let description: String = "\(mode)"
_inBackground
now indicates correct application state_inBackground
for app eventsFBSDKLoginBehaviorNative
FBSDKLoginBehaviorSystemAccount
FBSDKLoginBehaviorWeb
[FBSDKLoginManager renewSystemCredentials]
2019-01-08 | Full Changelog | Facebook Developer Docs Changelog