Integration

Overview

  • You will need the Channel key of the project, which is the key that our system uses to identify it, so it is unique for each project.
  • Xcode
    * An iOS device to run the app

Pod instalation

Attention

❗️

indigitall-chat is released up to version 1.4.2 via cocoapods. For the most current versions they will be available on Swift Package Manager

This article shows the minimum development that must be done to start registering devices and being able to carry out the first push campaigns.

Adding the Chat dependencies
Chat is available through CocoaPods.

CocoaPods is a valid dependency manager for Swift and Objective-C, being the most popular in iOS development.

If you don't have it yet, install CocoaPods. Open your terminal and run the following commands:

$ cd /ROOT/OF/YOUR/PROJECT
$ gem install cocoapods
$ pod init

To integrate the Chat of indigitall it is necessary to add the following dependencies:

  • The SocketIO-client library
  • Indigitall's Chat

Modify the PodFile file of your project and add this code:

target '<YourTarget>' do
    pod 'indigitall-ios-chat'
end

🚧

Remember

Add the corresponding pod of the Chat inside the names of the target that your application has.

Update the CocoaPod repository and install the dependencies from the terminal:

$ pod repo update
$ pod install

🚧

Attention

From here you must use .workspace instead of .xcproject to work on the project.
The main difference is that .xcproject is for a single project and .workspace can contain multiple projects.

Swift Package Manager

📘

From chat 1.6.0 version

SPM, or Swift Package Manager, is a tool for distributing iOS code. In the same way that we have explained with CocoaPods. But in this case, to import the package, you have to go to File->Add Pacakages and it will show you the following screen:

Then, go to the search engine at the top right, and add the following url: https://bitbucket.org/indigitallfuente/ios-chat-pod/src/master/ as show below


You add the package, and you can continue with the integration.