🛠️ Adb Claw
Android端末の画面表示や操作、音声取得
📺 まず動画で見る(YouTube)
▶ 【衝撃】最強のAIエージェント「Claude Code」の最新機能・使い方・プログラミングをAIで効率化する超実践術を解説! ↗
※ jpskill.com 編集部が参考用に選んだ動画です。動画の内容と Skill の挙動は厳密には一致しないことがあります。
📜 元の英語説明(参考)
Your eyes, hands, and ears on Android. See the screen (screenshot + indexed UI tree), interact (tap, swipe, scroll, type, clear-field), navigate via deep links (bypass CJK text input limits), wait for UI state changes instead of polling, monitor live UI text via accessibility framework (works during video playback), capture system audio (Android 11+, WAV stream for piping to ASR tools), manage full app lifecycle (install/uninstall/clear), control screen (on/off/unlock/rotation), run shell commands, and transfer files. Agent-optimized: structured JSON output, indexed element targeting, and App Profiles with pre-built deep links and layouts for popular apps.
🇯🇵 日本人クリエイター向け解説
Android端末の画面表示や操作、音声取得
※ jpskill.com 編集部が日本のビジネス現場向けに補足した解説です。Skill本体の挙動とは独立した参考情報です。
下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o adb-claw.zip https://jpskill.com/download/4273.zip && unzip -o adb-claw.zip && rm adb-claw.zip
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/4273.zip -OutFile "$d\adb-claw.zip"; Expand-Archive "$d\adb-claw.zip" -DestinationPath $d -Force; ri "$d\adb-claw.zip"
完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。
💾 手動でダウンロードしたい(コマンドが難しい人向け)
- 1. 下の青いボタンを押して
adb-claw.zipをダウンロード - 2. ZIPファイルをダブルクリックで解凍 →
adb-clawフォルダができる - 3. そのフォルダを
C:\Users\あなたの名前\.claude\skills\(Win)または~/.claude/skills/(Mac)へ移動 - 4. Claude Code を再起動
⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。
🎯 このSkillでできること
下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。
📦 インストール方法 (3ステップ)
- 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
- 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
- 3. 展開してできたフォルダを、ホームフォルダの
.claude/skills/に置く- · macOS / Linux:
~/.claude/skills/ - · Windows:
%USERPROFILE%\.claude\skills\
- · macOS / Linux:
Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。
詳しい使い方ガイドを見る →- 最終更新
- 2026-05-17
- 取得日時
- 2026-05-18
- 同梱ファイル
- 1
💬 こう話しかけるだけ — サンプルプロンプト
- › Adb Claw を使って、最小構成のサンプルコードを示して
- › Adb Claw の主な使い方と注意点を教えて
- › Adb Claw を既存プロジェクトに組み込む方法を教えて
これをClaude Code に貼るだけで、このSkillが自動発動します。
📖 Skill本文(日本語訳)
※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。
[Skill 名] adb-claw
ADB Claw — Android デバイス制御
Android 上のあなたの目、手、耳です。画面に何が表示されているかを確認し、任意の要素をタップし、コンテンツをスクロールし、ディープリンクを開き、UI の変更を待ち、システムオーディオをキャプチャし、アプリを管理するなど、すべて構造化された JSON 出力を持つ単一の CLI を介して行えます。
ADB Claw を使用する理由
スーパーパワー — 他では得られないもの:
- ライブストリームインテリジェンス —
monitorは Android のアクセシビリティフレームワークに接続し、すべての UI テキストをリアルタイムで読み取ります。これは、uiautomator dumpがハングするビデオ再生中やライブストリーム中でも可能です。チャットメッセージ、キャプション、動的なオーバーレイなど、他のツールではエージェントに公開されないデータです。 - システムオーディオキャプチャ —
audio captureは REMOTE_SUBMIX (Android 11+) を介してデバイスオーディオを録音します。WAV を stdout にストリーミングし、ASR ツールにパイプできます。monitorと組み合わせることで、視覚的なテキストとオーディオという完全な感覚カバー範囲が得られます。
コアの強み:
- 観察 → 実行 → 検証ループ —
observeはスクリーンショットとインデックス付き UI ツリーを 1 回の呼び出しで返します。要素インデックスを使用して、あらゆる画面サイズで正確にターゲットを設定できます。 - ディープリンクは CJK の制限をバイパス —
adb input textは中国語/日本語/韓国語を入力できませんが、adb-claw open 'app://search?keyword=中文'は可能です。 - ポーリングではなく待機 —
wait --text "Done"は UI 要素が表示されるまでブロックし、不安定な sleep/observe ループを置き換えます。 - スマートスクロール — 画面サイズからスワイプ座標を自動計算します。方向、ページ数、特定の要素内のスクロールをサポートします。
- アプリプロファイル — Douyin などの人気アプリ向けに、事前に構築された知識 (ディープリンク、レイアウト、既知の問題) があります。一度ロードすれば、試行錯誤をスキップできます。
- 完全なアプリライフサイクル — インストール、起動、停止、アンインストール、データクリア — 生の
adbは不要です。 - エージェントに最適化された JSON — すべてのコマンドは
{ok, command, data, error, duration_ms}を返し、エラー時には実行可能なsuggestionが含まれます。 - 最小限のデバイスフットプリント — ほとんどすべての操作は純粋な ADB コマンドです。
monitorとaudio captureのみが一時的な約 7KB のヘルパーをプッシュし、これらは自動終了します。
積極的に進化中 — 新しい機能が定期的にリリースされます。各リリースは、Android デバイスで認識および制御できる範囲を拡大します。
はじめに
Claude コード
プラグインをインストールしたら、Claude に話しかけるだけです。スラッシュコマンドは不要です。
claude plugin add llm-net/adb-claw
プラグインは、最初のセッションで adb-claw バイナリを自動ダウンロードします。adb がインストールされており、デバッグが有効なデバイスが USB 経由で接続されていることを確認してください。
次に、Claude に Android デバイスとの対話を依頼するだけです。
"私の携帯電話のスクリーンショットを撮って"
"Douyin を開いて猫咪を検索して"
"ログインボタンをタップして"
"ライブストリームチャットを30秒間監視して"
Claude は以下のトリガーリストを読み取り、メッセージが一致するとこのスキルを自動的にアクティブ化します。明示的な呼び出しは不要です。
OpenClaw
ClawHub からインストールします。
claw install adb-claw
同じ自然言語トリガーが適用されます。エージェントに Android デバイスを制御するように依頼すると、adb-claw コマンドが呼び出されます。
トリガー
これらのパターンは、エージェントにこのスキルをいつアクティブ化するかを伝えます。
- ユーザーが Android デバイスの制御、操作、または自動化を要求する
- ユーザーが Android 上でモバイルアプリまたは UI のテストを要求する
- ユーザーが Android 上でのタップ、スワイプ、スクロール、スクリーンショット、またはアプリ管理について言及する
- ユーザーが接続されたデバイスで URL、ディープリンク、または特定のアプリ画面を開きたい
- ユーザーが Android 上で UI 要素の表示/非表示を待ちたい
- ユーザーが Android 上で画面の状態 (オン/オフ/ロック解除/回転) を管理したい
- ユーザーが Android デバイスとの間でファイルをプッシュ/プルしたい
- ユーザーが Android 上でライブストリームチャットを監視したり、ビデオ再生中に UI テキストを読んだりしたい
- ユーザーが Android デバイスからオーディオをキャプチャまたは録音したい
- ユーザーが Douyin ライブストリームからショッピングカートの製品を取得したい
- ユーザーが Android デバイスでシェルコマンドを実行したい
バイナリ
adb-claw バイナリは ${CLAUDE_PLUGIN_ROOT}/bin/adb-claw にあります。
バイナリは SessionStart フックによって自動的にインストールされます。adb-claw が利用できない場合は、プラグインを再インストールする必要があることをユーザーに通知してください。自分でダウンロードまたはインストールしようとしないでください。
セットアップ
2 つのバイナリが必要です。
- adb-claw — 制御 CLI
- adb — Android Debug Bridge (Android SDK Platform-Tools から)
adb-claw のインストール
プラグインによって自動的にインストールされます。手動インストールについては、GitHub Releases を参照してください。
adb のインストール
# macOS
brew install android-platform-tools
# Linux (Debian/Ubuntu)
sudo apt install android-tools-adb
デバイスの接続
Android デバイスは USB デバッグが有効になっており、USB 経由で接続されている必要があります。これは最も一般的な障害です。ほとんどのユーザーはこれをオンにしていません。ユーザーが最初に電話の制御を要求したときは、常に最初に接続を確認し (adb-claw doctor)、失敗した場合は、他のコマンドを試す前に以下のセットアップ手順を案内してください。
USB デバッグを有効にする方法 (ユーザーを案内してください)
- Android スマートフォンで設定を開く
- 端末情報に移動する (一部の電話: 設定 → マイデバイス)
- ビルド番号 (または MIUI バージョン) を7 回タップする — 開発者モードが有効になったことを確認するトーストが表示されます
- 設定 → その他の設定 → 開発者向けオプションに戻る (パスはブランドによって異なります):
- Xiaomi/Redmi: 設定 → その他の設定 → 開発者向けオプション
- Samsung: 設定 → 開発者向けオプション
- Pixel/Stock: 設定 → システム → 開発者向けオプション
- OPPO/Vivo: 設定 → システム管理 → 開発者向けオプション
- USB デバッグトグルを有効にする
- USB ケーブルで電話をコンピューターに接続する
- 電話に「USB デバッグを許可しますか?」というダイアログが表示されます — 許可をタップする (便宜上、「このコンピューターからの接続を常に許可する」をチェックする)
接続の確認
adb-claw doctor # adb、デバイス接続、および機能をチェックします
doctor がデバイスなしと報告した場合は、ユーザーに次のことを依頼してください。
- USB ケーブルを確認する (一部のケーブルは充電専用でデータ転送不可)
- 別の USB ポートを試す
- 電話で USB デバッグを再認証する (取り消して再許可する)
- 一部の電話では
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開
ADB Claw — Android Device Control
Your eyes, hands, and ears on Android. See what's on screen, tap any element, scroll through content, open deep links, wait for UI changes, capture system audio, manage apps, and more — all through a single CLI with structured JSON output.
Why ADB Claw
Superpowers — What You Can't Get Elsewhere:
- Live stream intelligence —
monitorconnects to Android's accessibility framework, reading all UI text in real-time — even during video playback and live streams whereuiautomator dumphangs. Chat messages, captions, dynamic overlays — data no other tool exposes to agents. - System audio capture —
audio capturerecords device audio via REMOTE_SUBMIX (Android 11+); streams WAV to stdout for piping to ASR tools. Combined withmonitor, you get full sensory coverage: visual text + audio.
Core Strengths:
- Observe → Act → Verify loop —
observereturns screenshot + indexed UI tree in one call; use element indices to target precisely across any screen size - Deep links bypass CJK limits —
adb input textcan't type Chinese/Japanese/Korean;adb-claw open 'app://search?keyword=中文'can - Wait, don't poll —
wait --text "Done"blocks until the UI element appears, replacing fragile sleep/observe loops - Smart scroll — auto-calculates swipe coordinates from screen size; supports direction, page count, and scrolling within specific elements
- App Profiles — pre-built knowledge (deep links, layouts, known issues) for popular apps like Douyin; load once, skip trial-and-error
- Full app lifecycle — install, launch, stop, uninstall, clear data — no raw
adbneeded - Agent-optimized JSON — every command returns
{ok, command, data, error, duration_ms}with actionablesuggestionon errors - Minimal device footprint — nearly all operations are pure ADB commands; only
monitorandaudio capturepush temporary ~7KB helpers that auto-exit
Actively Evolving — new capabilities ship regularly. Each release expands what you can perceive and control on Android devices.
Getting Started
Claude Code
Install the plugin, then just talk to Claude — no slash commands needed:
claude plugin add llm-net/adb-claw
The plugin auto-downloads the adb-claw binary on first session. Make sure adb is installed and a device is connected via USB with debugging enabled.
Then simply ask Claude to interact with your Android device:
"Take a screenshot of my phone"
"Open Douyin and search for 猫咪"
"Tap the Login button"
"Monitor the live stream chat for 30 seconds"
Claude reads the Triggers list below and automatically activates this skill when your message matches — no explicit invocation required.
OpenClaw
Install from ClawHub:
claw install adb-claw
Same natural-language triggers apply. Ask your agent to control an Android device and it will invoke adb-claw commands.
Triggers
These patterns tell the agent when to activate this skill:
- User asks to control, interact with, or automate an Android device
- User asks to test a mobile app or UI on Android
- User mentions tapping, swiping, scrolling, screenshots, or app management on Android
- User wants to open a URL, deep link, or specific app screen on a connected device
- User wants to wait for UI elements to appear/disappear on Android
- User wants to manage screen state (on/off/unlock/rotation) on Android
- User wants to push/pull files to/from an Android device
- User wants to monitor live stream chat or read UI text during video playback on Android
- User wants to capture or record audio from an Android device
- User wants to grab shopping cart products from a Douyin live stream
- User wants to run shell commands on an Android device
Binary
The adb-claw binary is located at ${CLAUDE_PLUGIN_ROOT}/bin/adb-claw.
The binary is installed automatically via the SessionStart hook. If adb-claw is not available, inform the user that the plugin needs to be reinstalled — do not attempt to download or install it yourself.
Setup
Requires two binaries:
- adb-claw — the control CLI
- adb — Android Debug Bridge (from Android SDK Platform-Tools)
Install adb-claw
Installed automatically by the plugin. For manual installation, see GitHub Releases.
Install adb
# macOS
brew install android-platform-tools
# Linux (Debian/Ubuntu)
sudo apt install android-tools-adb
Connect device
The Android device must have USB debugging enabled and be connected via USB. This is the most common blocker — most users haven't turned it on. When a user first asks to control their phone, always check connection first (adb-claw doctor) and if it fails, walk them through the setup steps below before attempting any other commands.
How to enable USB debugging (guide the user through this)
- Open Settings on the Android phone
- Go to About phone (some phones: Settings → My device)
- Tap Build number (or MIUI version) 7 times — a toast confirming Developer Mode is enabled will appear
- Go back to Settings → Additional settings → Developer options (path varies by brand):
- Xiaomi/Redmi: Settings → Additional settings → Developer options
- Samsung: Settings → Developer options
- Pixel/Stock: Settings → System → Developer options
- OPPO/Vivo: Settings → System management → Developer options
- Enable USB debugging toggle
- Connect phone to computer via USB cable
- A dialog "Allow USB debugging?" will appear on the phone — tap Allow (check "Always allow from this computer" for convenience)
Verify connection
adb-claw doctor # Checks adb, device connection, and capabilities
If doctor reports no device, ask the user to:
- Check the USB cable (some cables are charge-only, no data)
- Try a different USB port
- Re-authorize USB debugging on the phone (revoke and re-allow)
- On some phones, change USB mode from "Charging" to "File Transfer" in the notification shade
Quick Start
The core loop is observe → decide → act → observe:
# 1. See what's on screen
adb-claw observe --width 540
# 2. Act on what you see (use element index from observe output)
adb-claw tap --index 3
# 3. Verify the result
adb-claw observe --width 540
For CJK apps, use deep links to bypass text input limits:
# Search in Douyin (Chinese TikTok) — no manual typing needed
adb-claw open 'snssdk1128://search/result?keyword=猫咪'
# Wait for results to load
adb-claw wait --text "综合" --timeout 5000
App Profiles
App Profiles are pre-built knowledge bases for specific apps — deep links, UI layouts, device-specific behavior, and known issues. They dramatically reduce the trial-and-error needed to automate an app.
Available Profiles: skills/apps/ directory
| App | File | Key Content |
|---|---|---|
| Douyin (抖音) | douyin.md |
Search/user/live deep links, feed/search/profile layouts, Phone vs Pad differences, live stream chat monitoring |
| Meituan (美团) | meituan.md |
Search/waimai deep links, homepage/menu/search layouts, WebView workarounds, popup chain handling |
Usage:
adb-claw app current→ get foreground app package name- Check
skills/apps/for a matching Profile - Has Profile → use deep links and known layouts (fast path)
- No Profile →
observe+ explore (slow path) - Check device form factor:
adb-claw device info→ short edge < 1200px = Phone, >= 1200px = Pad
Profiles are plain Markdown files. New app support = drop a .md file into skills/apps/.
Global Flags
| Flag | Short | Description | Default |
|---|---|---|---|
--serial |
-s |
Target device serial (when multiple devices connected) | auto-detect |
--output |
-o |
Output format: json, text, quiet |
json |
--timeout |
Command timeout in milliseconds | 30000 |
|
--verbose |
Enable debug output to stderr | false |
Commands
observe — Screenshot + UI Tree (Primary Command)
Captures screenshot and UI element tree in one call. Always use this before and after actions.
adb-claw observe # Default
adb-claw observe --width 540 # Scale screenshot width
Returns: base64 PNG screenshot, indexed UI elements with text/id/bounds/center coordinates.
screenshot — Capture Screen
adb-claw screenshot # Returns base64 PNG in JSON
adb-claw screenshot -f output.png # Save to file
adb-claw screenshot --width 540 # Scale down
tap — Tap UI Element
Tap by element index (preferred), resource ID, text, or coordinates:
adb-claw tap --index 5 # Tap element #5 from observe output
adb-claw tap --id "com.app:id/btn" # Tap by resource ID
adb-claw tap --text "Submit" # Tap by visible text
adb-claw tap 540 960 # Tap coordinates (x y)
Always prefer --index over coordinates. Index values come from observe output.
long-press — Long Press
adb-claw long-press 540 960 # Default duration
adb-claw long-press 540 960 --duration 2000 # 2 seconds
swipe — Swipe Gesture
adb-claw swipe 540 1800 540 600 # Swipe up (scroll down)
adb-claw swipe 540 600 540 1800 # Swipe down (scroll up)
adb-claw swipe 900 960 100 960 # Swipe left
adb-claw swipe 540 1800 540 600 --duration 500 # Slow swipe
type — Input Text (ASCII only)
adb-claw type "Hello world"
Important: Only ASCII text is supported. For CJK/emoji input, use open with deep links (e.g., adb-claw open 'myapp://search?keyword=中文').
key — Press System Key
adb-claw key HOME # Home screen
adb-claw key BACK # Navigate back
adb-claw key ENTER # Confirm / submit
adb-claw key TAB # Next field
adb-claw key DEL # Delete character
adb-claw key POWER # Power button
adb-claw key VOLUME_UP # Volume up
adb-claw key VOLUME_DOWN # Volume down
adb-claw key PASTE # Paste from clipboard
adb-claw key COPY # Copy selection
adb-claw key CUT # Cut selection
adb-claw key WAKEUP # Wake screen
adb-claw key SLEEP # Sleep screen
clear-field — Clear Input Field
Clear text in the currently focused input field. Optionally tap an element first to focus it.
adb-claw clear-field # Clear focused field
adb-claw clear-field --index 5 # Focus element #5 then clear
adb-claw clear-field --id "input_name" # Focus by resource ID then clear
adb-claw clear-field --text "Username" # Focus by text then clear
Uses Ctrl+A+DEL on SDK 31+, falls back to repeated DEL on older devices.
open — Open URI (Deep Link)
Open any URI using Android's ACTION_VIEW intent. The key to CJK text input — pass Chinese/Japanese/Korean text as URL parameters in deep links.
adb-claw open https://www.google.com
adb-claw open myapp://path/to/screen
adb-claw open "market://details?id=com.example"
adb-claw open "snssdk1128://search/result?keyword=猫咪" # Douyin search in Chinese
scroll — Smart Scroll
Scroll the screen or a specific scrollable element. Auto-calculates swipe coordinates from screen size — no manual coordinate math needed.
adb-claw scroll down # Scroll down one page
adb-claw scroll up # Scroll up one page
adb-claw scroll down --pages 3 # Scroll down 3 pages
adb-claw scroll down --index 5 # Scroll within element #5
adb-claw scroll left --distance 500 # Scroll left 500 pixels
Always prefer scroll over manual swipe for page navigation.
wait — Wait for UI Condition
Wait for a UI element or activity to appear or disappear. Replaces fragile sleep+observe polling loops with a single blocking call.
adb-claw wait --text "Login" # Wait for text to appear
adb-claw wait --id "btn_submit" # Wait for element by ID
adb-claw wait --text "Loading" --gone # Wait for text to disappear
adb-claw wait --activity ".MainActivity" # Wait for activity
adb-claw wait --text "Done" --timeout 20000 # Custom timeout (20s)
Default timeout: 10s. Default poll interval: 800ms.
screen — Screen Management
adb-claw screen status # Display on/off, locked, rotation
adb-claw screen on # Wake up screen
adb-claw screen off # Turn off screen
adb-claw screen unlock # Wake + swipe unlock (no password)
adb-claw screen rotation auto # Enable auto-rotation
adb-claw screen rotation 0 # Portrait
adb-claw screen rotation 1 # Landscape
app — App Management
adb-claw app list # Third-party apps
adb-claw app list --all # Include system apps
adb-claw app current # Current foreground app
adb-claw app launch <pkg> # Launch app by package name
adb-claw app stop <pkg> # Force stop app
adb-claw app install <apk> [--replace] # Install APK
adb-claw app uninstall <pkg> # Uninstall app
adb-claw app clear <pkg> # Clear app data/cache
monitor — Continuous UI Text Monitoring
Monitor UI text by connecting directly to the Android accessibility framework. Unlike ui tree which uses uiautomator dump, this command skips video surface nodes and works reliably during live streams and video playback.
adb-claw monitor # 10s bounded, returns JSON envelope
adb-claw monitor --duration 30000 # 30s bounded
adb-claw monitor --stream --duration 60000 # 60s streaming, JSON lines
adb-claw monitor --interval 1000 # Faster polling (1s)
Bounded mode (default): runs for --duration ms, returns all unique text entries in a JSON envelope.
Streaming mode (--stream): outputs each new text as a JSON line in real time.
Default duration: 10s. Default poll interval: 2s.
Note: This command pushes a small (~7KB) DEX helper to the device on first use. The helper runs temporarily via app_process and exits when monitoring completes.
audio capture — System Audio Capture (Android 11+)
Capture system audio via REMOTE_SUBMIX. Streams WAV (16kHz mono 16-bit PCM) to stdout for piping to external tools, or saves to a file.
WARNING: Device speakers are muted while capturing.
adb-claw audio capture # Stream WAV to stdout (10s)
adb-claw audio capture --duration 30000 # Stream 30s
adb-claw audio capture --duration 0 # Stream until killed (Ctrl+C)
adb-claw audio capture --file recording.wav # Save to file, returns JSON envelope
adb-claw audio capture --rate 44100 # Custom sample rate
Stream mode (default): outputs WAV to stdout — designed for piping:
adb-claw audio capture --stream --duration 30000 | asrclaw transcribe --stream --lang zh
File mode (--file): saves to local file and returns JSON envelope with file path, byte count, and duration.
Default duration: 10s. Default sample rate: 16000 Hz.
Requires Android 11+ (API 30). Like monitor, this command pushes a small DEX helper to the device on first use.
When to use audio capture vs monitor:
monitor— read UI text (chat messages, labels, captions) as structured dataaudio capture— record what's being heard (speech, music, sound effects) as audio
For live streams, they complement each other: monitor captures on-screen chat text while audio capture captures the streamer's voice.
live cart — Douyin Shopping Cart Capture (抖音小黄车)
Grab product information from a Douyin live stream shopping cart. Captures the currently explaining product (without opening the cart) and the first N products in the cart list.
This command is Douyin-specific — it relies on Douyin's UI patterns and accessibility node structure.
adb-claw live cart # Top 10 products + explaining product
adb-claw live cart --count 5 # Top 5 products
adb-claw live cart --count 20 # Top 20 products
How it works:
- Reads the "讲解中" floating card via accessibility (no cart open needed)
- Taps the shopping cart button to open the panel
- Scrolls slowly through products with continuous accessibility polling
- Stops when products 1..N are all captured (consecutive, no gaps)
- Closes the cart and outputs structured JSON
Returns: product number, title, price, sold count, shop name, tags for each product, plus the currently explaining product if any.
Must be used while viewing a Douyin live stream with a shopping cart.
shell — Run Raw Shell Command
Escape hatch for anything adb-claw doesn't have a dedicated command for.
adb-claw shell "ls /sdcard/"
adb-claw shell "getprop ro.build.version.release"
adb-claw shell "settings put system screen_brightness 128"
Returns stdout, stderr, and exit_code in JSON envelope.
file — File Transfer
adb-claw file push ./local.apk /sdcard/ # Push to device
adb-claw file pull /sdcard/photo.jpg ./ # Pull from device
device — Device Info
adb-claw device list # List connected devices
adb-claw device info # Model, Android version, screen size, density
ui — UI Element Inspection
adb-claw ui tree # Full UI element tree
adb-claw ui find --text "Settings" # Find by text
adb-claw ui find --id "com.app:id/title" # Find by resource ID
adb-claw ui find --index 3 # Find by index
Workflow Patterns
Always Observe First
Before any action, run observe to see the screen. After every action, observe again to verify.
1. adb-claw observe → See what's on screen
2. adb-claw tap --index 3 → Perform action
3. adb-claw observe → Verify result
Prefer Index-Based Targeting
Use --index N over coordinates. Indices from observe are stable across screen sizes.
Type After Focus
Always tap an input field first, then type:
1. adb-claw tap --index 7 → Focus the text field
2. adb-claw type "search query" → Enter text
3. adb-claw key ENTER → Submit
Scroll Pattern
adb-claw scroll down # Scroll down one page
adb-claw scroll up --pages 3 # Scroll up multiple pages
adb-claw scroll down --index 5 # Scroll within a specific element
Always prefer scroll over manual swipe. After scrolling, always observe.
CJK Text Input
adb-claw type only supports ASCII. For Chinese/Japanese/Korean input:
- Preferred: Use
adb-claw openwith deep links (e.g.,adb-claw open 'myapp://search?keyword=中文') - Clear before input:
adb-claw clear-field --index 7to clear existing text first
Wait for Page Load
Instead of repeated observe polling, use wait:
1. adb-claw tap --index 3 → Trigger navigation
2. adb-claw wait --text "Welcome" --timeout 15000 → Wait for new page
3. adb-claw observe → See the loaded page
Device Form Factor Detection
Use adb-claw device info to get screen size, then determine form factor:
- Short edge < 1200px → Phone (portrait-first)
- Short edge >= 1200px → Pad/Fold (landscape-first)
Swipe coordinates and UI layouts differ between Phone and Pad. App Profiles document these differences.
Audio Capture
First check if the device supports it:
1. adb-claw device info → Check Android version (need 11+ / SDK 30+)
To record audio to a file for the user:
1. adb-claw audio capture --file recording.wav --duration 30000 → Record 30s
To transcribe live audio (requires asrclaw installed separately):
1. adb-claw audio capture --stream --duration 60000 | asrclaw transcribe --stream --lang zh
Important: Device speakers are muted during capture. Inform the user before starting. For live streams, combine with monitor for complete context (audio + chat text).
Douyin Live Cart
Grab shopping cart products from a Douyin live stream:
1. Enter a Douyin live stream with a shopping cart (小黄车)
2. adb-claw live cart → Capture top 10 products + explaining product
3. adb-claw live cart --count 20 → Capture more products
The command handles everything automatically: opens cart, scrolls, captures, closes. No manual tapping needed.
Error Recovery
If an action fails or produces unexpected results:
- Run
observeto see the current state - Check if the screen changed unexpectedly (dialog, permission prompt)
- Adjust and retry
Output Format
All commands return JSON:
{
"ok": true,
"command": "tap",
"data": { ... },
"duration_ms": 150,
"timestamp": "2026-03-12T10:00:00Z"
}
On error:
{
"ok": false,
"error": {
"code": "DEVICE_NOT_FOUND",
"message": "No device connected",
"suggestion": "Connect a device via USB and enable USB debugging"
}
}
Security & Trust
What adb-claw is: A pure CLI wrapper around standard adb commands. It translates high-level instructions (e.g., adb-claw tap --index 3) into adb shell input tap ... calls. That's it.
What adb-claw does NOT do:
- Does not install APKs or persistent services on the device —
monitorandaudio captureeach push a temporary ~7KB DEX that runs briefly and auto-exits - Does not collect or transmit data — no telemetry, no analytics, no network requests
- Does not request credentials or environment variables
- Does not modify your host system beyond placing the binary
Source code is fully open: github.com/llm-net/adb-claw. If you don't trust pre-built binaries, you can audit the source code and build from source — see the README for instructions. Every release also includes SHA256 checksums for binary verification.
Device sensitivity: adb-claw can capture screenshots, record system audio, and control apps on the connected device — this is the core purpose of the tool. Only connect devices you trust, and disable USB debugging when not actively using adb-claw.
Agent scope: adb-claw commands are the only commands this skill should execute. Do not run install scripts, download binaries, or modify the host system. If adb-claw or adb is not available, inform the user.
Troubleshooting
| Problem | Solution |
|---|---|
| No devices found | Walk the user through: Settings → About phone → tap Build number 7x → Developer options → enable USB debugging → reconnect USB → approve the "Allow USB debugging" dialog on phone. See Setup section for full guide |
| adb not found | brew install android-platform-tools (macOS) |
| Tap hits wrong element | Use --index instead of coordinates; re-run observe |
type doesn't work |
Tap input field first to focus; ASCII only |
| CJK text needed | Use adb-claw open with deep link containing the text as URL parameter |
| UI dump fails | Pause animations (tap to pause video), wait 1s, retry |
| UI dump fails on search pages | Search results may auto-play video previews; use screenshot instead or monitor to read text |
| UI dump fails during live stream | Use monitor command — it bypasses video surfaces via accessibility framework |
| Command timeout | Increase with --timeout 60000 |
| Permission dialog | Use observe to see it, tap the allow/skip button |
| Screen is off | adb-claw screen on or adb-claw screen unlock |
| Audio capture fails | Requires Android 11+ (API 30); check with adb-claw device info |
| No audio captured | REMOTE_SUBMIX may not be available on all devices/ROMs |
| Speakers muted during capture | Expected behavior — REMOTE_SUBMIX redirects audio output |