Implement the SDK with CocoaPods
To add the SDK as a dependency in your app’s Podfile, add the pod to your Xcode project. See Using CocoaPods: Adding Pods to an Xcode project.
1target 'MyApp' do
2 pod 'MarketingCloudSDK'
3 pod 'SFPushFeatureSDK'
4 pod 'SFInAppMessagingFeatureSDK'
5end
1target 'MyApp' do
2 pod 'MarketingCloudSDK'
3 pod 'SFPushFeatureSDK'
4end
1target 'MyApp' do
2 pod 'MarketingCloudSDK'
3end
The pods listed in these examples include the SFMCSDK module automatically. Don’t add the module to your podfile manually.
Next, open the .xcworkspace created by the install process using Xcode and start using the SDK.
Don’t open .xcodeproj directly. Opening a project file instead of a workspace can lead to errors.
After you install the dependencies, configure the SDK.