Skip to main content

Android properties plugin

If you are targeting Android(AOSP), then the following plugin will automatically include meta information about android runtime, such as build number, build key types (dev vs rel), build types (user,userdebug,eng), etc.

Setup

For this plugin to work, make sure to set up core metrics sdk.

Add dependencies

To add android.properties plugin, add the following artifact to your build.gradle.kts (Kotlin DSL) or build.gradle (Groovy):

implementation("com.hexdroid.client.metrics:android.properties:0.0.1")

Latest version can be found on Maven Central

Install

val reportingClient = createReportingClient(apiKey) // from previous step

// Add this
reportingClient.addPropertyPlugin(AndroidBuildPropertiesPlugin())

Once integrated, all reported metrics to HexDroid will contain the following information:

  • android.os.Build.MODEL
  • android.os.Build.BOARD
  • android.os.Build.BRAND
  • android.os.Build.DEVICE
  • android.os.Build.DISPLAY
  • android.os.Build.FINGERPRINT
  • android.os.Build.ID
  • android.os.Build.TYPE