# Installing UIKit (deprecated)

{% hint style="warning" %}
To provide greater customization options, we have open-sourced our UIKit and deprecated the managed UIKit version previously available. For the best quality and access to the latest features, we strongly recommend integrating our UIKit with the open-source version. For more details  Please refer to [Android UIKit Installation Guide](https://docs.social.plus/social-plus-uikit/uikit-3/android/android-uikit-installation-guide) section.
{% endhint %}

## Prerequisite

SDK supports Android 5.0 (API Level 21) and above

```
android {
    ...
    defaultConfig {
        minSDKVersion 21 // at least 21
    }
}
```

## Installation

Add the Jitpack repository in your project level `build.grade` at the end of repositories:

```
allprojects {
  repositories {
    ...
    maven { url 'https://jitpack.io' }
  }
}
```

Add the dependency in your module level `build.grade.` Find latest UIKit version at [Changelog](https://docs.social.plus/social-plus-uikit/changelogs/changelog-1).

```
// add buildFeatures, compileOptions and kotlinOptions in android tag
android {

    buildFeatures {
        dataBinding = true
    }
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
    kotlinOptions {
        jvmTarget = JavaVersion.VERSION_1_8
    }
    
}
    
dependency {
implementation 'com.github.AmityCo.Amity-Social-Cloud-UIKit-Android:amity-uikit:x.y.z'
}
```

{% hint style="warning" %}
AmityUIKit already includes our SDK. Don’t install AmitySDK separately if you have already installed the UIKit.

From the version 3.x. please install the UIKit with the open source guideline here [android-uikit-installation-guide](https://docs.social.plus/social-plus-uikit/uikit-3/android/android-uikit-installation-guide "mention")
{% endhint %}

## Managing Conflicting File Generation

In your app module's `build.gradle` , add the following packaging options.

```kotlin
android {
    ...
    packagingOptions {
        exclude 'META-INF/INDEX.LIST'
        exclude 'META-INF/io.netty.versions.properties'
    }
}
```

## Code Obfuscation

By using our SDK, you can use the Android ProGuard tool to obfuscate, shrink, and optimize your code. Obfuscated code can be more difficult for other people to reverse engineer. ProGuard renames classes, fields, and methods with semantically obscure names and removes unused code. However, you need to add these configurations to your ProGuard rules when using our SDK.

```
-keep class com.ekoapp.ekosdk.** { *; }
-keep interface com.ekoapp.ekosdk.** { *; }
-keep enum com.ekoapp.ekosdk.** { *; }
-keep class com.amity.socialcloud.** { *; }
-keep interface com.amity.socialcloud.** { *; }
-keep enum com.amity.socialcloud.** { *; }
```
