Android

Choose the native Android SDK package, initialize the runtime, and branch into pairing, telemetry, JPEG capture, touch input, artifacts, and remote tools.

The native Android SDK exposes Kotlin-friendly APIs for Ansight telemetry, host pairing, live session transport, artifacts, and remote tools.

Packages

PackageRegistryPurpose
ai.ansight:ansight-androidMaven CentralAll-in-one developer package. Includes core, pairing, and standard native tool suites.
ai.ansight:ansight-core-androidMaven CentralRuntime, telemetry, host connection, tools, and artifact abstractions.
ai.ansight:ansight-pairing-androidMaven CentralNative Android pairing UI.
ai.ansight:ansight-tools-visualtree-androidMaven CentralAndroid view hierarchy, screenshot, and overlay tools.
ai.ansight:ansight-tools-filesystem-androidMaven CentralSandboxed file-system tools.
ai.ansight:ansight-tools-preferences-androidMaven CentralSharedPreferences tools.
ai.ansight:ansight-tools-securestorage-androidMaven CentralAllow-listed secure-storage tools.
ai.ansight:ansight-tools-database-androidMaven CentralSQLite discovery, schema, and query tools.
ai.ansight:ansight-tools-reflection-androidMaven CentralExplicit-root reflection tools.

Quickstart

Put this code in your app’s Application subclass, usually app/src/main/java/<your-package>/MyApplication.kt, inside onCreate() after super.onCreate(). Register the class with android:name=".MyApplication" in AndroidManifest.xml. Keep MainActivity for UI and pairing flows that need an activity.

import ai.ansight.Ansight
import android.app.Application

class MyApplication : Application() {
    override fun onCreate() {
        super.onCreate()

        Ansight.initializeAndActivate(
            application = this,
            options = Ansight.developerOptions(
                bundledDeveloperConfigJson = BuildConfig.ANSIGHT_DEVELOPER_PAIRING_JSON,
                clientName = "Android App",
            ),
        )
    }
}

Ansight.developerOptions(...) applies the Android all-in-one developer preset: 400 ms sampling, 120 s retention, FPS, touch capture, JPEG capture every 2000 ms at quality 60 and max width 480, host auto-probe, full tool access, and all standard native tools.

Important: Screen capture will result in an FPS drop while the SDK captures, encodes, and transports frames. Disable session JPEG capture for performance-focused runs unless visual evidence is required.

Use Setup Packages for install details, Android Security before enabling remote tools, Pairing for host connection, and Tools before enabling remote inspection in an app build.