Skip to content

Android Libraries Setup

Overview

This guide provides step-by-step instructions for integrating the Everysight SDK into your Android project.

Since SDK 2.6.0, our SDK libraries are hosted on GitHub Packages, and can be references via standard implementation declaration with the gradle file.

Info

For SDK 2.5.0 please download the libraries from our SDK Github repository.

SDK Maven libraries are supported from version 2.6.0.

Add Github Packages Repository

To access the Everysight SDK libraries on GitHub Packages, add the following maven repository to your project build.gradle.kts file in the repositories block:

Note

You must create a GitHub token via your GitHub account settings.

The github token must scope read:packages (click here to generate a new token)

After generating the token, fill in the missing information as follows:

repositories {
    google()
    mavenCentral()
    maven {
        url = uri("https://maven.pkg.github.com/everysight-maverick/m1-android-maven")
        credentials {
            username = "YOUR_PERSONAL_GITHUB_USERNAME"
            password = "YOUR_PERSONAL_GITHUB_TOKEN"
        }
    }
}

Declare Everysight SDK Modules

Using libs.versions.toml

Add the Everysight SDK versions to your libs.versions.toml file:

[versions]
evskit = "2.6.0"

[libraries]
evskit = { module = "com.everysight:evskit", version.ref = "evskit" }
nativeevskit = { module = "com.everysight:nativeevskit", version.ref = "evskit" }

Add the Everysight SDK modules to your app build.gradle.kts file:

dependencies {
    implementation(libs.evskit)
    implementation(libs.nativeevskit)
}

For older projects

dependencies {
    implementation("com.everysight:evskit:2.6.0")
    implementation("com.everysight:nativeevskit:2.6.0")
}

proguard-rules.pro

When enabling minify, please add the following rules to the proguard-rules.pro file:

-keepattributes InnerClasses

-keep class io.jsonwebtoken.** { *; }
-keepnames class io.jsonwebtoken.* { *; }
-keepnames interface io.jsonwebtoken.* { *; }

-keep class com.google.gson.reflect.TypeToken
-keep class * extends com.google.gson.reflect.TypeToken
-keep public class * implements java.lang.reflect.Type

Learn about the iOS Libraries Setup