Android quickstart
Add the Extentos Android SDK by hand — Gradle install, manifest permissions, and your first capability call. Voice apps need no vendor token.
The by-hand path for adding Extentos to an existing Android app. Prefer letting an agent do the wiring? Use the agent-driven quickstart — same outcome, less typing. Each step below links to the SDK reference for full detail.
1. Add the dependencies
com.extentos:glasses + com.extentos:glasses-ui are on Maven Central and carry no vendor dependency — nothing else to declare, no token.
android {
buildFeatures {
// AGP 8 defaults this OFF, and the init snippet below reads
// BuildConfig.DEBUG. Without it, step 3 does not compile.
buildConfig = true
}
}
dependencies {
implementation("com.extentos:glasses:2.1.2")
implementation("com.extentos:glasses-ui:2.1.2") // optional — the prebuilt connection page
// The SDK's suspend surface needs a dispatcher from your side.
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.9.0")
}That's everything a voice app needs to build. If your app uses the camera or the display, add the Meta vendor module too — it brings the Meta DAT artifacts, which live on Meta's GitHub Packages and need a read:packages token:
implementation("com.extentos:glasses-meta:2.1.2")The extra repo block + token setup + toolchain floors are in Install the Android SDK. Not sure which you need? Choose your path.
Floors: minSdk 31, compileSdk 35, Kotlin 2.1.20, AGP 8.6+, Gradle 8.7+, JVM 17. You also need namespace set in your android { } block — AGP 8 fails the build without it.
One more thing before you ship a voice app that uses the assistant: bake your project key, or the assistant won't reach the managed gateway from a sideloaded build. It's one line, it never causes a build error, and its absence shows up only at runtime as AssistantError.NoApiKey:
android {
defaultConfig {
buildConfigField("String", "EXTENTOS_PROJECT_KEY", "\"pk_your_project_key\"")
}
}generateConnectionModule mints the key and emits this line; wiring by hand, take it from your dashboard project. Detail: install § the project key.
2. Declare permissions
The library auto-merges the Bluetooth + service entries; you add the capability permissions your app uses — CAMERA, RECORD_AUDIO, INTERNET, and (for background mic) FOREGROUND_SERVICE + FOREGROUND_SERVICE_MICROPHONE. Which capability needs which: Manifest setup and Permissions.
3. Initialize Extentos
Create one ExtentosGlasses for your app's lifetime:
val glasses = ExtentosGlasses.create(
ExtentosConfig(
applicationContext = applicationContext,
environment = if (BuildConfig.DEBUG) ExtentosEnvironment.DEVELOPMENT else ExtentosEnvironment.PRODUCTION,
)
)TransportChoice.Auto (the default) picks the browser simulator during development, real glasses when a vendor module claims one, and otherwise the system-audio baseline — mic and speaker over whatever the OS routed, so a voice app works on a phone with nothing paired. Config table + lifecycle: Initialization.
4. Make your first capability call
Capability calls return ExtentosResult — pattern-match, don't try/catch:
when (val r = glasses.camera.capturePhoto()) {
is ExtentosResult.Ok -> showPhoto(r.value)
is ExtentosResult.Err -> handle(r.error) // CaptureError
}Per-primitive snippets come from the getCapabilityGuide MCP tool; full flows from getCodeExample. For voice AI, the Phase-4 assistant runtime is the canonical path (stable since 1.4.0).
5. Verify in the browser simulator
Run your app against the browser simulator — the same library code, only the transport swapped. Mint a session with the createSimulatorSession MCP tool (or from extentos.com/s); the running app auto-attaches via the local bridge. Watch capability events flow with getEventLog.
Next
- Android SDK reference — install, manifest, init, lifecycle, threading, runtime internals
- Guides — task-shaped recipes (voice, photo, video, display, …)
- From simulator to real glasses — the hardware transition
Related
Android SDK
Add Extentos to your Android app via Gradle. Smart-glasses capabilities for Meta Ray-Ban, Android 12+ (API 31), Kotlin, coroutines.
Quickstart with an AI agent
Install the Extentos MCP server and let your AI agent scaffold Meta Ray-Ban smart-glasses capabilities into a native iOS or Android app. Free to start.
iOS quickstart
The by-hand iOS quickstart — add the Extentos Swift package, set the Info.plist keys, initialize, and make your first capability call.
Concepts
The mental-model pages for Extentos — transport vs app simulation, architecture, the capability vocabulary, the AI gateway, the assistant, and display.