Getting Started
This page provides requirements and instructions to install the Genies Android SDK.
Requirements
- Android Studio Hedgehog (2023.1.1) or later
minSdk28+ (lower won't resolve)compileSdk34+- Java 11 / Kotlin JVM target 11
- Supported ABIs:
arm64-v8a,x86_64
Install
The Genies Partner SDK is published on GitHub Packages (private — geniesinc org).
Add the Partner SDK as your dependency — it brings the NAF libraries with it:
implementation("com.genies.auth:genies-auth:0.2.0")
The NAF artifacts below are exposed transitively, so you only need to declare them directly if you want to pin or inspect them individually.
An auth token is required to install the Genies Android SDK. Reach out to Genies for a classic GitHub PAT with read:packages scope, SSO-authorized for geniesinc.
1. Credentials
Drop the PAT into ~/.gradle/gradle.properties:
genies.gpr.user=<your-github-username>
genies.gpr.key=<classic-PAT-with-read:packages>
CI alternative: expose GITHUB_ACTOR / GITHUB_TOKEN as env vars — the snippet below falls back to those.
2. settings.gradle.kts
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
maven {
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/geniesinc/genies-naf-android")
credentials {
username = providers.gradleProperty("genies.gpr.user").orNull
?: System.getenv("GITHUB_ACTOR")
password = providers.gradleProperty("genies.gpr.key").orNull
?: System.getenv("GITHUB_TOKEN")
}
}
}
}
3. App build.gradle.kts
0.1.3 below is an example — use the version you need. See the Release Notes section for available versions.
android {
namespace = "com.example.myapp"
compileSdk = 34
defaultConfig {
applicationId = "com.example.myapp"
// Minimum supported by the SDK — lower than 28 won't resolve.
minSdk = 28
targetSdk = 34
}
// The SDK ships arm64-v8a + x86_64 only.
splits {
abi {
isEnable = true
reset()
include("arm64-v8a", "x86_64")
isUniversalApk = false
}
}
packaging {
jniLibs.pickFirsts += "**/libc++_shared.so"
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}
kotlinOptions { jvmTarget = "11" }
// Only needed if you'll embed `NafAvatarView` in a Composable host.
buildFeatures { compose = true }
}
dependencies {
// Headless session, container, builder
implementation("com.genies.naf:naf-core:0.1.3")
// Bundled resolver config + default-asset JSON.
implementation("com.genies.naf:naf-config:0.1.3")
// Renderer-agnostic helpers — camera, picker, transform gizmo.
implementation("com.genies.naf:naf-tools:0.1.3")
// Vulkan renderer + `NafView` + Compose bridge. Skip if you're rendering
// yourself.
implementation("com.genies.naf:naf-ui:0.1.3")
}
4. Verify
./gradlew :app:dependencies --configuration releaseRuntimeClasspath | grep com.genies.naf
All four artifacts at the requested version should be listed.
Bumping the version
Single source: change the :0.1.3 suffixes (or, if cataloged, the version ref in gradle/libs.versions.toml). Then re-resolve:
./gradlew --refresh-dependencies :app:assembleRelease