ShizukuTools

Provider object for the Shizuku-backed shell tools. Wires the shared :droid-mcp-shell-core tool set against ShizukuShellBackend.

Shizuku activation is a special-access flow (the user installs the Shizuku app, activates it via wireless debugging on Android 11+ or ADB, then grants the runtime permission to this host app). See docs/SHELL.md.

Functions

Link copied to clipboard
fun all(context: Context, policy: ShellPolicy = ShellPolicy.RECOMMENDED): List<McpTool>

The shell-core tool set wired against the Shizuku backend.

Link copied to clipboard
Link copied to clipboard

Settings-style intent for the host to launch when Shizuku isn't ready — either opens Shizuku itself (so the user can activate it) or the Play Store install page if Shizuku isn't installed yet. The host activity should add Intent.FLAG_ACTIVITY_NEW_TASK if launching from a non-activity context.

Link copied to clipboard

True when both the Shizuku binder is reachable AND the host has been granted the permission. False if Shizuku isn't installed/activated or if the user hasn't granted access.

Link copied to clipboard
Link copied to clipboard
fun requestPermission(requestCode: Int)

Ask Shizuku to show its permission dialog (Shizuku.requestPermission). Does nothing if the Shizuku service isn't running — check isShizukuReady first, and use installOrOpenIntent to send the user to Shizuku when it isn't. The result arrives via Shizuku's OnRequestPermissionResultListener.

Link copied to clipboard

No Manifest.permission.* runtime grants — Shizuku's permission is its own runtime check via Shizuku.checkSelfPermission(), gated by permissionStatus.

Link copied to clipboard