diff --git a/README.md b/README.md index e02e7eb..c6cb7ad 100644 --- a/README.md +++ b/README.md @@ -49,8 +49,9 @@ Open `http://localhost:5173`. ### 4) Pair with an agent 1. Enter the WebSocket endpoint (default: `ws://127.0.0.1:32123/ws`). -2. Enter a 6-digit pairing PIN. -3. After `pairing_result`, the UI switches to chat mode. +2. If your backend requires `web.accounts..auth_token` (common for non-loopback binds), set it in the optional `auth_token` field. +3. Enter a 6-digit pairing PIN. +4. After `pairing_result`, the UI switches to chat mode. ## Scripts @@ -101,7 +102,7 @@ Detailed docs: `localStorage` keys: -- `nullclaw_ui_auth_v1` - endpoint URL, `access_token`, `shared_key`, `expires_at`. +- `nullclaw_ui_auth_v1` - endpoint URL (may include `?token=` when used), `access_token`, `shared_key`, `expires_at`. - `nullclaw_ui_theme` - current theme. - `nullclaw_ui_effects` - visual effects toggle. diff --git a/docs/operations.md b/docs/operations.md index e9e9a77..47377fb 100644 --- a/docs/operations.md +++ b/docs/operations.md @@ -24,6 +24,7 @@ Implications: WebSocket endpoint is currently user-entered in `PairingScreen`. Default value: `ws://127.0.0.1:32123/ws`. +For deployments that enforce `web.accounts..auth_token`, users can provide the value via the optional `auth_token` field in the pairing form (it is appended as `?token=...` when opening the WebSocket). To change default endpoint, update initial `url` in `src/lib/components/PairingScreen.svelte`. @@ -31,7 +32,7 @@ To change default endpoint, update initial `url` in `src/lib/components/PairingS `nullclaw_ui_auth_v1` in local storage includes: -- endpoint URL +- endpoint URL (may include `token` query param when configured in UI) - `access_token` - `shared_key` (base64url) - `expires_at` diff --git a/src/lib/components/ConnectionModal.svelte b/src/lib/components/ConnectionModal.svelte index 858b9e6..9ee05ad 100644 --- a/src/lib/components/ConnectionModal.svelte +++ b/src/lib/components/ConnectionModal.svelte @@ -1,5 +1,6 @@