feat(cli): improve gateway status output
This commit is contained in:
@@ -51,11 +51,16 @@ Notes:
|
||||
|
||||
All query commands use WebSocket RPC.
|
||||
|
||||
Shared options:
|
||||
- `--url <url>`: Gateway WebSocket URL (defaults to `gateway.remote.url` when configured).
|
||||
- `--token <token>`: Gateway token (if required).
|
||||
- `--password <password>`: Gateway password (password auth).
|
||||
- `--timeout <ms>`: timeout (default `10000`).
|
||||
Output modes:
|
||||
- Default: human-readable (colored in TTY).
|
||||
- `--json`: machine-readable JSON (no styling/spinner).
|
||||
- `--no-color` (or `NO_COLOR=1`): disable ANSI while keeping human layout.
|
||||
|
||||
Shared options (where supported):
|
||||
- `--url <url>`: Gateway WebSocket URL.
|
||||
- `--token <token>`: Gateway token.
|
||||
- `--password <password>`: Gateway password.
|
||||
- `--timeout <ms>`: timeout/budget (varies per command).
|
||||
- `--expect-final`: wait for a “final” response (agent calls).
|
||||
|
||||
### `gateway health`
|
||||
@@ -66,8 +71,15 @@ clawdbot gateway health --url ws://127.0.0.1:18789
|
||||
|
||||
### `gateway status`
|
||||
|
||||
`gateway status` is the “debug everything” command. It always probes:
|
||||
- your configured remote gateway (if set), and
|
||||
- localhost (loopback) **even if remote is configured**.
|
||||
|
||||
If multiple gateways are reachable, it prints all of them and warns this is an unconventional setup (usually you want only one gateway).
|
||||
|
||||
```bash
|
||||
clawdbot gateway status --url ws://127.0.0.1:18789
|
||||
clawdbot gateway status
|
||||
clawdbot gateway status --json
|
||||
```
|
||||
|
||||
### `gateway call <method>`
|
||||
@@ -104,4 +116,3 @@ Examples:
|
||||
clawdbot gateway discover --timeout 4000
|
||||
clawdbot gateway discover --json | jq '.beacons[].wsUrl'
|
||||
```
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@ This page describes the current CLI behavior. If commands change, update this do
|
||||
|
||||
- `--dev`: isolate state under `~/.clawdbot-dev` and shift default ports.
|
||||
- `--profile <name>`: isolate state under `~/.clawdbot-<name>`.
|
||||
- `--no-color`: disable ANSI colors.
|
||||
- `-V`, `--version`, `-v`: print version and exit.
|
||||
|
||||
## Output styling
|
||||
@@ -20,7 +21,7 @@ This page describes the current CLI behavior. If commands change, update this do
|
||||
- ANSI colors and progress indicators only render in TTY sessions.
|
||||
- OSC-8 hyperlinks render as clickable links in supported terminals; otherwise we fall back to plain URLs.
|
||||
- `--json` (and `--plain` where supported) disables styling for clean output.
|
||||
- `--no-color` disables ANSI styling where supported; `NO_COLOR=1` is also respected.
|
||||
- `--no-color` disables ANSI styling; `NO_COLOR=1` is also respected.
|
||||
- Long-running commands show a progress indicator (OSC 9;4 when supported).
|
||||
|
||||
## Color palette
|
||||
|
||||
Reference in New Issue
Block a user