A tutorial-first Android demo that shows how a regular app can expose local capabilities through Android AppFunctions, making the app behave like an on-device MCP-style tool provider for agents.
AppFunctions is experimental. This project focuses on developer integration, KDoc metadata, local registration, and ADB verification. Full Gemini end-to-end access may depend on private preview availability and supported devices.
- Notes and reminders in a normal Compose UI.
- The same workflows exposed as AppFunctions.
- Agent-friendly KDoc with
isDescribedByKDoc = true. - ADB commands for inspecting registered AppFunctions.
- Security boundaries for narrow, non-destructive local functions.
First release media can start as screenshots. Recommended GIF flow:
- Create a note in the UI.
- Run
adb shell cmd app_function list-app-functions. - Show the registered functions for
com.example.appfunctionsplayground. - Show the same data visible in the app UI.
- Android Studio with Android SDK 37 support.
- Android 16+ device or emulator for AppFunctions verification.
- Android Gradle Plugin 9.1.0 or newer.
- JDK 17 or newer. Android Studio's bundled JBR works.
The current AppFunctions 1.0.0-alpha09 artifacts require compileSdk 37 or newer.
From this machine, use Android Studio's bundled JBR and the cached Gradle distribution:
JAVA_HOME="/Applications/Android Studio.app/Contents/jbr/Contents/Home" \
ANDROID_HOME="$HOME/Library/Android/sdk" \
GRADLE_USER_HOME="$PWD/.gradle-work" \
~/.gradle/wrapper/dists/gradle-9.4.1-bin/arn2x92ynaizyzdaamcbpbhtj/gradle-9.4.1/bin/gradle testDebugUnitTest
JAVA_HOME="/Applications/Android Studio.app/Contents/jbr/Contents/Home" \
ANDROID_HOME="$HOME/Library/Android/sdk" \
GRADLE_USER_HOME="$PWD/.gradle-work" \
~/.gradle/wrapper/dists/gradle-9.4.1-bin/arn2x92ynaizyzdaamcbpbhtj/gradle-9.4.1/bin/gradle assembleDebugYou can also open the project directly in Android Studio and run the app configuration.
createNotesearchNotescreateReminderlistRemindersgenerateChecklistFromNotes
adb shell cmd app_function list-app-functions
adb shell cmd app_function list-app-functions | grep --after-context 10 com.example.appfunctionsplaygroundapp/src/main/java/com/example/appfunctionsplayground/
appfunctions/ Agent-facing AppFunctions and serializable DTOs
data/ Room entities, DAOs, and repositories
demo/ Sample data seeding
domain/ Deterministic checklist generation and range parsing
ui/ Compose screens
docs/ Developer-facing guide docs
- Add screenshots and a short demo GIF.
- Add an AppFunction invocation transcript from a supported device.
- Add deeper docs for generated AppFunctions metadata.
- Add optional Expense domain after the tutorial path is stable.