diff --git a/docs/_config.yml b/docs/_config.yml index 35036163c..cf13847ad 100644 --- a/docs/_config.yml +++ b/docs/_config.yml @@ -1,5 +1,5 @@ title: "CLAWDBOT Docs" -description: "A TypeScript/Node gateway + macOS/iOS companions for WhatsApp (web) and Telegram (bot)." +description: "A TypeScript/Node gateway + macOS/iOS/Android companions for WhatsApp (web) and Telegram (bot)." markdown: kramdown highlighter: rouge @@ -35,9 +35,11 @@ nav: - title: "WebChat" url: "/webchat.html" - title: "macOS App" - url: "/clawdbot-mac.html" - - title: "iOS Node" - url: "/ios/connect.html" + url: "/macos.html" + - title: "iOS App" + url: "/ios.html" + - title: "Android App" + url: "/android.html" - title: "Telegram" url: "/telegram.html" - title: "Security" diff --git a/docs/architecture.md b/docs/architecture.md index fce9f0768..ee98631ae 100644 --- a/docs/architecture.md +++ b/docs/architecture.md @@ -32,6 +32,12 @@ Last updated: 2026-01-05 - Canvas + actions: `WKWebView` with A2UI action bridge; accepts actions from local-network or trusted file URLs; intercepts `clawdbot://` deep links and forwards `agent.request` to the bridge. - Voice/talk: voice wake sends `voice.transcript` events and syncs triggers via `voicewake.get` + `voicewake.changed`; Talk Mode attaches to the bridge. +### Android node (`apps/android`) +- Discovery + pairing: `BridgeDiscovery` uses mDNS/NSD to find `_clawdbot-bridge._tcp`, with manual host/port fallback. +- Auto-connect: `NodeRuntime` restores a stored token, performs `pair-and-hello`, and reconnects to the last discovered or manual bridge. +- Bridge runtime: `BridgeSession` owns the TCP JSONL session (`hello`/`hello-ok`, ping/pong, `req/res`, `event`, `invoke`); stores `canvasHostUrl`. +- Commands: `NodeRuntime` executes `canvas.*`, `canvas.a2ui.*`, `camera.*`, and chat/session events; foreground-only for canvas/camera. + ## Components and flows - **Gateway (daemon)** - Maintains WhatsApp (Baileys), Telegram (grammY), Slack (Bolt), Discord (discord.js), Signal (signal-cli), and iMessage (imsg) connections. diff --git a/docs/docs.json b/docs/docs.json index 2a6c4b5a2..9d10e946c 100644 --- a/docs/docs.json +++ b/docs/docs.json @@ -70,8 +70,9 @@ "mac/dev-setup", "mac/menu-bar", "mac/voicewake", - "ios/connect", - "android/connect", + "macos", + "ios", + "android", "webchat", "web" ] diff --git a/docs/index.md b/docs/index.md index 156262657..704447c69 100644 --- a/docs/index.md +++ b/docs/index.md @@ -42,7 +42,8 @@ WhatsApp / Telegram / Discord ├─ CLI (clawdbot …) ├─ Chat UI (SwiftUI) ├─ macOS app (Clawdbot.app) - └─ iOS node via Bridge + pairing + ├─ iOS node via Bridge + pairing + └─ Android node via Bridge + pairing ``` Most operations flow through the **Gateway** (`clawdbot gateway`), a single long-running process that owns provider connections and the WebSocket control plane. @@ -70,6 +71,7 @@ Most operations flow through the **Gateway** (`clawdbot gateway`), a single long - 🎤 **Voice notes** — Optional transcription hook - 🖥️ **WebChat + macOS app** — Local UI + menu bar companion for ops and voice wake - 📱 **iOS node** — Pairs as a node and exposes a Canvas surface +- 📱 **Android node** — Pairs as a node and exposes Canvas + Chat + Camera Note: legacy Claude/Codex/Gemini/Opencode paths have been removed; Pi is the only coding-agent path. diff --git a/docs/mac/peekaboo.md b/docs/mac/peekaboo.md index 913d5545b..50511bea6 100644 --- a/docs/mac/peekaboo.md +++ b/docs/mac/peekaboo.md @@ -23,7 +23,7 @@ Peekaboo’s privileged execution moved from “CLI → XPC helper” to “CLI - It lets us piggyback on **either** Peekaboo.app’s permissions **or** Clawdbot.app’s permissions (whichever is running). - It avoids “two apps with two TCC bubbles” unless needed. -Reference (Peekaboo submodule): `docs/bridge-host.md`. +Reference (Peekaboo submodule): `Peekaboo/docs/bridge-host.md`. ## Architecture ### Processes diff --git a/docs/macos.md b/docs/macos.md index 318f3c741..7412a2fc8 100644 --- a/docs/macos.md +++ b/docs/macos.md @@ -94,7 +94,7 @@ Notes: - In remote mode, Clawdbot will use the configured remote tunnel/endpoint. ## Build & dev workflow (native) -- `cd native && swift build` (debug) / `swift build -c release`. +- `cd apps/macos && swift build` (debug) / `swift build -c release`. - Run app for dev: `swift run Clawdbot` (or Xcode scheme). - Package app + CLI: `scripts/package-mac-app.sh` (builds bun CLI + gateway). - Tests: add Swift Testing suites under `apps/macos/Tests`.