Requirements
- D·engage Integration Key
- iOS Push Certificate
- iOS Device (you need to test on a real device for notifications)
- A mac with latest Xcode
- D·engage Mobil SDK for iOS supports version iOS 10 and later.
Integration Methods
1. CocoaPods Integration
Dengage is available through CocoaPods.
To install it, simply add the following line to your Podfile:
// 5.61.1 Sdk without geofence module
pod 'Dengage', '~> 5.61.1'
// 5.61.2 Sdk with geofence module
pod 'Dengage', '~> 5.61.2'
Run
pod install
via terminal
2. SPM Integration
Installing the iOS SDK via Swift Package Manager (SPM) automates the majority of the installation process for you. Before beginning this process, ensure that you are using Xcode 12 or greater. (Note:Applies to new SDK.)
Open your project and navigate to your project's settings. Select the tab named Swift Packages and click on the add button (+) at the bottom left.
Enter the URL of our iOS SDK repository in the text field and click Add Package.
Paste URL: https://github.com/dengage-tech/dengage-ios-sdk.git
Select the latest branch and You can find the latest released branch here https://github.com/dengage-tech/dengage-ios-sdk/tags
On the next screen, select the SDK version and click Add Package.
Select the package and click finish
3. End Point Configuration
For initial setup, if you have been given URL addresses by D·engage Support Team, you need to set up URL addresses by using Info.Plist
file.
Please see API Endpoints By Datacenter to set your subscription end point.
4. Completing the integration
If you are integrating our iOS SDK with CocoaPods, Carthage or SPM add the following line of code to your AppDelegate.swift
import Dengage
After installation, you can access SDK's methods by importing
Add the line at the beginning of your code file.
5. How to create an Apple iOS Certificate
5.1 Visit your project account page on Developer Apple and navigate to Certificates, Identifiers & Profiles > Certificates page.
5.2 Navigate to the Keys page. Create a new Keys.
5.3 Enter a key name and select "Apple Push Notifications service (APNs)"Continue > Register > Download > Done
6. Defining iOS Application
6.1 Visit your project account page on Developer Apple and navigate to
Certificates, Identifiers & Profiles > Identifiers > Select Your Application page. Copy your Team ID and Bundle ID.
6.2 Visit your project account page on Developer Apple and navigate to
Certificates, Identifiers & Profiles > Keys > Select Your Keys page. Copy your Key ID.
6.3 Visit your project account page on Developer Apple and navigate to
App Store Connect > Go To App Store Connect page. Select Your Apps > General > App Information > Copy your Apple ID. (For alias area)
6.4 Login your D·engage Panel. Navigate "Settings > Push Applications" page and click the "Add > IOS Application" button.
6.5 Paste your Key ID, Team ID, Bundle ID, Apple ID and upload .p8 file on your D·engage ios app settings page. If you are testing the application in debug environment i.e via Xcode use sandbox environment and if you are testing it via testflight or Appstore use Prod environment and update the Integartion keys accordingly.This p8 file can be downloaded only once and only maximum 2 keys can be generated