A small Android application written entirely in Kotlin, showing how to use the Featurevisor Java SDK.
Learn more about Featurevisor here.
The application evaluates the same flag, variation, feature variables, and global variables as the other Featurevisor SDK examples.
Install Android Studio with Android SDK 36 and JDK 17.
The Featurevisor SDK is published through GitHub Packages. Add GitHub credentials with the read:packages scope to ~/.gradle/gradle.properties:
gpr.user=YOUR_GITHUB_USERNAME
gpr.key=YOUR_GITHUB_TOKENKeep these credentials outside the repository.
- Open the repository in Android Studio.
- Allow Gradle to resolve the Featurevisor dependency.
- Select an Android emulator or connected device.
- Run the
appconfiguration.
The application uses this production datafile:
https://featurevisor-example-cloudflare.pages.dev/production/featurevisor-sdk-v3.json
The direct SDK integration lives in MainActivity.kt. Change its context values to see how Featurevisor selects different rules, variations, and global variable overrides.
./gradlew testDebugUnitTest lintDebug assembleDebugLearn more in the Featurevisor Java SDK documentation.