@xerg/cli 0.1.4 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -20,6 +20,22 @@ xerg doctor
20
20
  xerg audit
21
21
  ```
22
22
 
23
+ ## Bundled skill
24
+
25
+ The published `@xerg/cli` package includes the portable Xerg skill bundle at:
26
+
27
+ ```text
28
+ node_modules/@xerg/cli/skills/xerg/SKILL.md
29
+ ```
30
+
31
+ That file is a packaged copy of the canonical repo skill at [`skills/xerg/SKILL.md`](../../skills/xerg/SKILL.md). Use it if your agent platform imports skills from disk; installing the npm package does not automatically register the skill with every agent product.
32
+
33
+ ## Supported runtime
34
+
35
+ `@xerg/cli` supports Node `20`, `22`, and `24`.
36
+
37
+ If you are developing in this repo, `.nvmrc` still pins the default local toolchain to Node `24.14.0`.
38
+
23
39
  ## Sample output
24
40
 
25
41
  ```text
@@ -71,6 +87,11 @@ xerg audit --since 24h --compare
71
87
  - If OpenClaw runs remotely, SSH into the machine where the logs live and run Xerg there
72
88
  - Or point Xerg at exported files directly with flags
73
89
 
90
+ Remote prerequisites:
91
+
92
+ - SSH audits require `ssh` and `rsync` on your `PATH`
93
+ - Railway audits require the `railway` CLI on your `PATH`
94
+
74
95
  ## Default paths
75
96
 
76
97
  By default, Xerg checks:
@@ -85,6 +106,30 @@ xerg audit --log-file /path/to/openclaw.log
85
106
  xerg audit --sessions-dir /path/to/sessions
86
107
  ```
87
108
 
109
+ ## Authentication and config
110
+
111
+ Push commands resolve credentials in this order:
112
+
113
+ 1. `XERG_API_KEY`
114
+ 2. `~/.xerg/config.json`
115
+ 3. `xerg login` browser credentials stored at `~/.config/xerg/credentials.json`
116
+
117
+ Optional API URL overrides:
118
+
119
+ - `XERG_API_URL`
120
+ - `apiUrl` in `~/.xerg/config.json`
121
+
122
+ Example `~/.xerg/config.json`:
123
+
124
+ ```json
125
+ {
126
+ "apiKey": "sk_live_or_test_key",
127
+ "apiUrl": "https://api.xerg.ai"
128
+ }
129
+ ```
130
+
131
+ `xerg login` stores a browser-issued token in `~/.config/xerg/credentials.json`. That token store is separate from `~/.xerg/config.json`.
132
+
88
133
  ## What the audit shows
89
134
 
90
135
  - Total spend by workflow and model, in dollars
@@ -97,6 +142,19 @@ xerg audit --sessions-dir /path/to/sessions
97
142
 
98
143
  Xerg v0 stores economic metadata and audit summaries locally. It does not store prompt or response content.
99
144
 
145
+ ## Exit codes
146
+
147
+ - `0`: success
148
+ - `1`: general failure
149
+ - `2`: no OpenClaw data was found
150
+ - `3`: a `--fail-above-waste-rate` or `--fail-above-waste-usd` threshold was exceeded
151
+
152
+ ## Troubleshooting
153
+
154
+ - `better-sqlite3` is a native dependency. If install fails, retry on a supported Node version and make sure standard native build tooling is available for your platform.
155
+ - If `xerg audit --remote ...` fails before pulling files, verify that both `ssh` and `rsync` are installed and reachable on your `PATH`.
156
+ - If `xerg audit --railway` fails immediately, verify that the `railway` CLI is installed, authenticated, and can access the target project.
157
+
100
158
  ## Pilot and support
101
159
 
102
160
  - Pilot: [xerg.ai/pilot](https://xerg.ai/pilot)