@hyperscale0/cli 1.0.334 → 1.0.336
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/AGENTS.md +4 -2
- package/README.md +17 -13
- package/hyperscale.js +103 -102
- package/package.json +2 -2
package/AGENTS.md
CHANGED
|
@@ -86,8 +86,10 @@ JSON output has no ANSI codes, banners, spinners or prompts.
|
|
|
86
86
|
Exit codes: 0 success, 1 server refusal or failure, 2 usage (unknown command
|
|
87
87
|
or option, or an argument, flag or input refused before any request; also an
|
|
88
88
|
HSX check or plan that cannot proceed), 3 live action waiting for human
|
|
89
|
-
approval, 4
|
|
90
|
-
conflict with the current state (409)
|
|
89
|
+
approval, 4 sign in (401, or no login found; Code `auth_required`), 5 not
|
|
90
|
+
found (404), 6 conflict with the current state (409), 7 signed in but not
|
|
91
|
+
allowed (403; the Code names the missing permission or scope). New codes take
|
|
92
|
+
the next number; a code never changes meaning. `refusals.js` holds the table;
|
|
91
93
|
`help --json` prints it as `exitCodes`.
|
|
92
94
|
|
|
93
95
|
`hsx watch --json` emits one JSON object per line with `type` set to `check`,
|
package/README.md
CHANGED
|
@@ -55,8 +55,9 @@ way. The browser signup and its email link keep working.
|
|
|
55
55
|
`hyperscale auth logout` removes the local login. Add `--revoke` to revoke the
|
|
56
56
|
token too. Tokens and saved requests use macOS Keychain when available, with
|
|
57
57
|
an owner-only file fallback (mode 0600). `HYPERSCALE_CREDENTIAL_STORE=file`
|
|
58
|
-
selects file storage. `HYPERSCALE_CONFIG_DIR` or `--config-dir <path>` sets
|
|
59
|
-
|
|
58
|
+
selects file storage. `HYPERSCALE_CONFIG_DIR` or `--config-dir <path>` sets the
|
|
59
|
+
settings folder. The token stays in the Keychain, one entry per folder, so
|
|
60
|
+
deleting the folder does not sign out: run `hyperscale auth logout` first.
|
|
60
61
|
|
|
61
62
|
## Work on a product
|
|
62
63
|
|
|
@@ -129,7 +130,9 @@ step that fails:
|
|
|
129
130
|
Each customer is created, given a sandbox account and funded first. `create`
|
|
130
131
|
makes an object, `run` runs an action on it, `fund` adds sandbox money,
|
|
131
132
|
`advance` moves the sandbox clock (`30m`, `4h`, `2d`, `1w` or an ISO time) and
|
|
132
|
-
`expect` checks balances.
|
|
133
|
+
`expect` checks balances. The clock is the Product's, shared by every record in
|
|
134
|
+
it, so `scenario run` names its advances before the first step. The starter
|
|
135
|
+
`init` writes takes one payment and never moves the clock. A plain balance compares to `available`; an object
|
|
133
136
|
can name `available`, `settled` or `pending`. Amounts are major units, as
|
|
134
137
|
`fund` takes them (`"750"` or `"750.50"` in SAR), in money fields and action
|
|
135
138
|
input too; the runner sends the API minor units. Funding and actions need the
|
|
@@ -185,7 +188,7 @@ Use `--on-behalf-of` to act for a customer. Mutations accept
|
|
|
185
188
|
```sh
|
|
186
189
|
hyperscale key create --name Agent
|
|
187
190
|
hyperscale key list
|
|
188
|
-
hyperscale key revoke <api-key-id>
|
|
191
|
+
hyperscale key revoke <api-key-id> --yes
|
|
189
192
|
hyperscale activity list --limit 20
|
|
190
193
|
hyperscale activity tail --follow
|
|
191
194
|
hyperscale api list --catalog
|
|
@@ -254,15 +257,16 @@ run `npm install -g @hyperscale0/cli@latest`.
|
|
|
254
257
|
scopes and operations; `help --all` adds the advanced operations.
|
|
255
258
|
Use `hyperscale <group> <command> --help` for one command.
|
|
256
259
|
|
|
257
|
-
| Exit | Meaning
|
|
258
|
-
| ---- |
|
|
259
|
-
| 0 | Success.
|
|
260
|
-
| 1 | The server refused the request or could not finish it.
|
|
261
|
-
| 2 | Usage: an unknown command or option, an argument, flag or input refused before any request, or an HSX check failure.
|
|
262
|
-
| 3 | A live action is waiting for a person to approve it.
|
|
263
|
-
| 4 |
|
|
264
|
-
| 5 | The thing named does not exist (HTTP 404).
|
|
265
|
-
| 6 | The request conflicts with the current state (HTTP 409).
|
|
260
|
+
| Exit | Meaning |
|
|
261
|
+
| ---- | --------------------------------------------------------------------------------------------------------------------- |
|
|
262
|
+
| 0 | Success. |
|
|
263
|
+
| 1 | The server refused the request or could not finish it. |
|
|
264
|
+
| 2 | Usage: an unknown command or option, an argument, flag or input refused before any request, or an HSX check failure. |
|
|
265
|
+
| 3 | A live action is waiting for a person to approve it. |
|
|
266
|
+
| 4 | Sign in: no login, or the login or key was not accepted (HTTP 401). Code `auth_required` when the CLI finds no login. |
|
|
267
|
+
| 5 | The thing named does not exist (HTTP 404). |
|
|
268
|
+
| 6 | The request conflicts with the current state (HTTP 409). |
|
|
269
|
+
| 7 | Signed in, but this login, its role or the key may not do that (HTTP 403). The Code names the missing permission. |
|
|
266
270
|
|
|
267
271
|
`help --json` lists the same table under `exitCodes`. A mistyped command or
|
|
268
272
|
option suggests the nearest one, and every refusal carries a runnable `fix`.
|