appfunctions

Generates Kotlin AppFunctions exposing Android app workflows to on-device AI agents.

1|Updated Jun 9, 2026
One-click install
npx skills add https://github.com/kariemSeiam/android-claw --skill appfunctions-kariemseiam
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: appfunctions
Source: https://github.com/kariemSeiam/android-claw/tree/main/skills/installed/device-ai-appfunctions
Command: npx skills add https://github.com/kariemSeiam/android-claw --skill appfunctions-kariemseiam

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Android apps cannot expose their core workflows to system AI agents without significant boilerplate, correct KSP configuration, and agent-readable documentation. This Skill guides the full AppFunctions lifecycle so features like creating notes or sending messages become discoverable and executable by on-device agents without opening the app UI. ## Core Features & Use Cases - Feature Discovery: Analyzes AndroidManifest.xml, Activities, and Services to recommend high-value AppFunctions with rationale focused on mutations and rich queries. - Kotlin Implementation & Configuration: Generates @AppFunction and @AppFunctionSerializable code with correct KSP setup, app_metadata.xml, and optional Hilt-based dependency injection. - KDoc Refinement & ADB Testing: Optimizes documentation for LLM consumption and provides adb shell cmd app_function commands to list, execute, and enable functions on a device. - Use Case: A notes app developer asks to expose note creation to Gemini; the Skill discovers the workflow, generates the Kotlin functions with proper KDoc, and verifies registration via ADB. ## Quick Start Analyze my Android app and implement AppFunctions so system AI agents can create notes without opening the app UI.

Frequently Asked Questions about appfunctions

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement AppFunctions in an Android app?▼

Add the androidx.appfunctions, appfunctions-service, and KSP compiler dependencies, then annotate suspend functions with @AppFunction(isDescribedByKDoc = true). The first parameter must be AppFunctionContext, and you must define app_metadata.xml referenced from AndroidManifest.xml.

How to test AppFunctions with ADB commands?▼

Use adb shell cmd app_function list-app-functions to see registered functions, then execute one with adb shell cmd app_function execute-app-function --package <pkg> --function <id> --parameters '<json>'. Wrap the JSON in single quotes to prevent shell interpretation.

What Android version is required for AppFunctions?▼

The app must target SDK 36 or newer, since AppFunctions are part of the Android platform API available from Android 16 onwards. Always use the Jetpack library, which handles backwards compatibility.

Why is my AppFunction metadata missing after build?▼

KSP only extracts documentation for @AppFunctionSerializable classes when KDoc is written inline per property, not as class-level @param tags. Also verify the ksp argument appfunctions:aggregateAppFunctions is set to true and the compiler dependency is applied.

What data types can AppFunction parameters use?▼

Supported types include primitives, primitive arrays, String, PendingIntent, Uri, LocalDateTime, Instant, classes annotated with @AppFunctionSerializable, and Lists of supported non-primitive types. Non-essential parameters should be optional with sensible defaults.