# Adding SDK to a Client’s Mobile App

## CocoaPods

To integrate OZLivenessSDK into an Xcode project via the [CocoaPods](https://cocoapods.org/) dependency manager, add the following code to Podfile:

```swift
pod 'OZLivenessSDK', :git => 'https://gitlab.com/oz-forensics/oz-liveness-ios', :tag => 'VERSION'
```

Version is optional as, by default, the newest version is integrated. However, if necessary, you can find the older version number in [Changelog](/oz-knowledge/guides/developer-guide/sdk/oz-mobile-sdk/ios/changelog.md).

Since 8.1.0, you can also use a simpler code:

```swift
// for the latest version
pod ‘OZLivenessSDK’
// OR, for the specific version
// pod ‘OZLivenessSDK’, ‘8.22.0’
```

By default, the full version is being installed. It contains both server-based and on-device analysis modes. To install the server-based version only, use the following code:

```swift
pod 'OZLivenessSDK/Core', :git => 'https://gitlab.com/oz-forensics/oz-liveness-ios.git',  :tag => 'VERSION'
```

For 8.1.0 and higher:

```swift
pod ‘OZLivenessSDK/Core’
// OR
// pod ‘OZLivenessSDK/Core’, ‘8.22.0’
```

## SPM

Please note: installation via SPM is available for versions 8.7.0 and above.

Add the following package dependencies via SPM: <https://gitlab.com/oz-forensics/oz-mobile-ios-sdk> (if you need a guide on adding the package dependencies, please refer to the [Apple documentation](https://developer.apple.com/documentation/xcode/adding-package-dependencies-to-your-app)). **OzLivenessSDK** is mandatory. If you don't need the on-device analyses, skip the **OzLivenessSDKOnDevice** file.

## Manual Installation

You can also add the necessary frameworks to your project manually.&#x20;

1. Download the SDK files from [here](https://gitlab.com/oz-forensics/oz-liveness-ios) and add them to your project.

* **OZLivenessSDK.xcframework**,&#x20;
* **OZLivenessSDKResources.bundle**,
* **OZLivenessSDKOnDeviceResources.bundle** (if you don't need the on-device analyses, skip this file)**.**

2. Download the TensorFlow framework 2.11 from [here](https://github.com/tensorflow/tensorflow/releases).
3. Make sure that:

* both **xcframework** are in **Target-Build Phases -> Link Binary With Libraries** and **Target-General -> Frameworks, Libraries, and Embedded Context**;
* the **bundle** file(s) are in **Target-Build Phases -> Copy Bundle Resources**.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.ozforensics.com/oz-knowledge/guides/developer-guide/sdk/oz-mobile-sdk/ios/adding-sdk-to-a-clients-mobile-app.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
