These docs are for v0.0.1. Click to read the latest docs for v1.0.62.

iOS SDK

This page describes how to get started with the iOS SDK

Prerequisites to Implementing iOS SDK

🚧

Download the iOS SDK before proceeding

Make sure you download the iOS SDK here from DevConnect before continuing through this integration guide

iOS SDK

To add the AvMessagingSdk.framework library to your XCode project, follow the steps below to install the framework using CocoaPods

  1. First, install CocoaPods if it isn't already
gem install cocoapods
  1. Copy the AvMessagingSdk.framework and AvMessagingSdk.podspec files somewhere in your project directory, for example in vendor/AvMessagingSdk
  2. Add the AvMessagingSdk dependency to your Podfile, using a local path that points to the directory in step 2
target 'YourApp' do
    pod 'AvMessagingSdk', :path => 'vendor/AvMessagingSdk'
end
  1. Install the pod
pod install
  1. Open the generated .xcworkspace file and add the following keys to your app's Info.plist file (replacing the values if desired):
<key>NSPhotoLibraryUsageDescription</key>
<string>${PRODUCT_NAME} will read your photo library to gather additional information</string>
<key>NSPhotoLibraryAddUsageDescription</key>
<string>${PRODUCT_NAME} will write to your photo library to gather additional information</string>
<key>NSCameraUsageDescription</key>
<string>${PRODUCT_NAME} will use your camera to gather additional information</string>
  1. Start using the framework in your code.

Objective-C:

#import <AvMessagingSdk/AvMessagingSdk.h>

[AvMessagingSdk initWithSettings:[AVASettings settingsWithIntegrationId:@"YOUR_INTEGRATION_ID"] completionHandler:^(NSError * _Nullable error, NSDictionary * _Nullable userInfo) {
    // Your code after init is complete
}];

Swift:

AvMessagingSdk.initWith(AVASettings(integrationId: "YOUR_INTEGRATION_ID")) { (error: Error?, userInfo: [AnyHashable : Any]?) in
    // Your code after init is complete
}

Version

This is version 1.0.1 of AvMessagingSdk.