$npx -y skills add SafeAI-Lab-X/ClawKeeper --skill node-connectDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps. Use when QR/setup code/manual connect fails, local Wi-Fi works but VPS/tailnet does not, or errors mention pairing required, unauthorized, bootstrap token invalid or expired, gatewa
| 1 | # Node Connect |
| 2 | |
| 3 | Goal: find the one real route from node -> gateway, verify OpenClaw is advertising that route, then fix pairing/auth. |
| 4 | |
| 5 | ## Topology first |
| 6 | |
| 7 | Decide which case you are in before proposing fixes: |
| 8 | |
| 9 | - same machine / emulator / USB tunnel |
| 10 | - same LAN / local Wi-Fi |
| 11 | - same Tailscale tailnet |
| 12 | - public URL / reverse proxy |
| 13 | |
| 14 | Do not mix them. |
| 15 | |
| 16 | - Local Wi-Fi problem: do not switch to Tailscale unless remote access is actually needed. |
| 17 | - VPS / remote gateway problem: do not keep debugging `localhost` or LAN IPs. |
| 18 | |
| 19 | ## If ambiguous, ask first |
| 20 | |
| 21 | If the setup is unclear or the failure report is vague, ask short clarifying questions before diagnosing. |
| 22 | |
| 23 | Ask for: |
| 24 | |
| 25 | - which route they intend: same machine, same LAN, Tailscale tailnet, or public URL |
| 26 | - whether they used QR/setup code or manual host/port |
| 27 | - the exact app text/status/error, quoted exactly if possible |
| 28 | - whether `openclaw devices list` shows a pending pairing request |
| 29 | |
| 30 | Do not guess from `can't connect`. |
| 31 | |
| 32 | ## Canonical checks |
| 33 | |
| 34 | Prefer `openclaw qr --json`. It uses the same setup-code payload Android scans. |
| 35 | |
| 36 | ```bash |
| 37 | openclaw config get gateway.mode |
| 38 | openclaw config get gateway.bind |
| 39 | openclaw config get gateway.tailscale.mode |
| 40 | openclaw config get gateway.remote.url |
| 41 | openclaw config get gateway.auth.mode |
| 42 | openclaw config get gateway.auth.allowTailscale |
| 43 | openclaw config get plugins.entries.device-pair.config.publicUrl |
| 44 | openclaw qr --json |
| 45 | openclaw devices list |
| 46 | openclaw nodes status |
| 47 | ``` |
| 48 | |
| 49 | If this OpenClaw instance is pointed at a remote gateway, also run: |
| 50 | |
| 51 | ```bash |
| 52 | openclaw qr --remote --json |
| 53 | ``` |
| 54 | |
| 55 | If Tailscale is part of the story: |
| 56 | |
| 57 | ```bash |
| 58 | tailscale status --json |
| 59 | ``` |
| 60 | |
| 61 | ## Read the result, not guesses |
| 62 | |
| 63 | `openclaw qr --json` success means: |
| 64 | |
| 65 | - `gatewayUrl`: this is the actual endpoint the app should use. |
| 66 | - `urlSource`: this tells you which config path won. |
| 67 | |
| 68 | Common good sources: |
| 69 | |
| 70 | - `gateway.bind=lan`: same Wi-Fi / LAN only |
| 71 | - `gateway.bind=tailnet`: direct tailnet access |
| 72 | - `gateway.tailscale.mode=serve` or `gateway.tailscale.mode=funnel`: Tailscale route |
| 73 | - `plugins.entries.device-pair.config.publicUrl`: explicit public/reverse-proxy route |
| 74 | - `gateway.remote.url`: remote gateway route |
| 75 | |
| 76 | ## Root-cause map |
| 77 | |
| 78 | If `openclaw qr --json` says `Gateway is only bound to loopback`: |
| 79 | |
| 80 | - remote node cannot connect yet |
| 81 | - fix the route, then generate a fresh setup code |
| 82 | - `gateway.bind=auto` is not enough if the effective QR route is still loopback |
| 83 | - same LAN: use `gateway.bind=lan` |
| 84 | - same tailnet: prefer `gateway.tailscale.mode=serve` or use `gateway.bind=tailnet` |
| 85 | - public internet: set a real `plugins.entries.device-pair.config.publicUrl` or `gateway.remote.url` |
| 86 | |
| 87 | If `gateway.bind=tailnet set, but no tailnet IP was found`: |
| 88 | |
| 89 | - gateway host is not actually on Tailscale |
| 90 | |
| 91 | If `qr --remote requires gateway.remote.url`: |
| 92 | |
| 93 | - remote-mode config is incomplete |
| 94 | |
| 95 | If the app says `pairing required`: |
| 96 | |
| 97 | - network route and auth worked |
| 98 | - approve the pending device |
| 99 | |
| 100 | ```bash |
| 101 | openclaw devices list |
| 102 | openclaw devices approve --latest |
| 103 | ``` |
| 104 | |
| 105 | If the app says `bootstrap token invalid or expired`: |
| 106 | |
| 107 | - old setup code |
| 108 | - generate a fresh one and rescan |
| 109 | - do this after any URL/auth fix too |
| 110 | |
| 111 | If the app says `unauthorized`: |
| 112 | |
| 113 | - wrong token/password, or wrong Tailscale expectation |
| 114 | - for Tailscale Serve, `gateway.auth.allowTailscale` must match the intended flow |
| 115 | - otherwise use explicit token/password |
| 116 | |
| 117 | ## Fast heuristics |
| 118 | |
| 119 | - Same Wi-Fi setup + gateway advertises `127.0.0.1`, `localhost`, or loopback-only config: wrong. |
| 120 | - Remote setup + setup/manual uses private LAN IP: wrong. |
| 121 | - Tailnet setup + gateway advertises LAN IP instead of MagicDNS / tailnet route: wrong. |
| 122 | - Public URL set but QR still advertises something else: inspect `urlSource`; config is not what you think. |
| 123 | - `openclaw devices list` shows pending requests: stop changing network config and approve first. |
| 124 | |
| 125 | ## Fix style |
| 126 | |
| 127 | Reply with one concrete diagnosis and one route. |
| 128 | |
| 129 | If there is not enough signal yet, ask for setup + exact app text instead of guessing. |
| 130 | |
| 131 | Good: |
| 132 | |
| 133 | - `The gateway is still loopback-only, so a node on another network can never reach it. Enable Tailscale Serve, restart the gateway, run openclaw qr again, rescan, then approve the pending device pairing.` |
| 134 | |
| 135 | Bad: |
| 136 | |
| 137 | - `Maybe LAN, maybe Tailscale, maybe port forwarding, maybe public URL.` |