run402 2.14.0 → 2.15.1
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/cli.mjs +10 -0
- package/lib/doctor.mjs +62 -9
- package/lib/notifications.mjs +174 -0
- package/lib/webhook-secret.mjs +45 -0
- package/package.json +1 -1
- package/sdk/dist/namespaces/admin.d.ts +124 -0
- package/sdk/dist/namespaces/admin.d.ts.map +1 -1
- package/sdk/dist/namespaces/admin.js +58 -0
- package/sdk/dist/namespaces/admin.js.map +1 -1
package/cli.mjs
CHANGED
|
@@ -240,6 +240,16 @@ switch (cmd) {
|
|
|
240
240
|
await run(sub, rest);
|
|
241
241
|
break;
|
|
242
242
|
}
|
|
243
|
+
case "notifications": {
|
|
244
|
+
const { run } = await import("./lib/notifications.mjs");
|
|
245
|
+
await run(sub, rest);
|
|
246
|
+
break;
|
|
247
|
+
}
|
|
248
|
+
case "webhook-secret": {
|
|
249
|
+
const { runWebhookSecret } = await import("./lib/notifications.mjs");
|
|
250
|
+
await runWebhookSecret(sub, rest);
|
|
251
|
+
break;
|
|
252
|
+
}
|
|
243
253
|
case "logs": {
|
|
244
254
|
const { run } = await import("./lib/logs.mjs");
|
|
245
255
|
await run(sub, rest);
|
package/lib/doctor.mjs
CHANGED
|
@@ -96,21 +96,25 @@ export async function run(sub, args = []) {
|
|
|
96
96
|
});
|
|
97
97
|
}
|
|
98
98
|
|
|
99
|
-
// 3.
|
|
99
|
+
// 3. Project keystore. The wallet itself lives in allowance.json (verified
|
|
100
|
+
// by check 2 above); this checks the per-project keys (anon_key /
|
|
101
|
+
// service_key) that `run402 projects provision` writes. An empty store is
|
|
102
|
+
// normal for fresh installs that haven't provisioned a project yet, so
|
|
103
|
+
// report informationally as `ok` rather than warning.
|
|
100
104
|
try {
|
|
101
105
|
const keystore = loadKeyStore();
|
|
102
|
-
const
|
|
106
|
+
const projectCount = Object.keys(keystore?.projects ?? {}).length;
|
|
103
107
|
checks.push({
|
|
104
|
-
name: "
|
|
105
|
-
status:
|
|
106
|
-
value: {
|
|
107
|
-
...(
|
|
108
|
-
hint: "
|
|
108
|
+
name: "projects",
|
|
109
|
+
status: "ok",
|
|
110
|
+
value: { project_count: projectCount },
|
|
111
|
+
...(projectCount === 0 && {
|
|
112
|
+
hint: "No projects yet — run 'run402 projects provision' to create one (wallet is already set up).",
|
|
109
113
|
}),
|
|
110
114
|
});
|
|
111
115
|
} catch (err) {
|
|
112
116
|
checks.push({
|
|
113
|
-
name: "
|
|
117
|
+
name: "projects",
|
|
114
118
|
status: "error",
|
|
115
119
|
message: err instanceof Error ? err.message : String(err),
|
|
116
120
|
});
|
|
@@ -165,7 +169,51 @@ export async function run(sub, args = []) {
|
|
|
165
169
|
});
|
|
166
170
|
}
|
|
167
171
|
|
|
168
|
-
|
|
172
|
+
// 6. Operator health snapshot (v1.55).
|
|
173
|
+
try {
|
|
174
|
+
const sdk = getSdk();
|
|
175
|
+
const status = await sdk.admin.getOperatorStatus();
|
|
176
|
+
const gaps = [];
|
|
177
|
+
if (status.operator_contact.email_status !== "verified") {
|
|
178
|
+
gaps.push(`operator email not verified (${status.operator_contact.email_status}) — run 'run402 agent contact --email ...' then reply to the challenge`);
|
|
179
|
+
}
|
|
180
|
+
if (status.operator_contact.passkey_status !== "verified") {
|
|
181
|
+
gaps.push("operator passkey not bound — run 'run402 agent passkey enroll' after email verification");
|
|
182
|
+
}
|
|
183
|
+
if (Array.isArray(status.skipped_notifications) && status.skipped_notifications.length > 0) {
|
|
184
|
+
gaps.push(`${status.skipped_notifications.length} notification(s) skipped due to missing verified recipient`);
|
|
185
|
+
}
|
|
186
|
+
if (Array.isArray(status.critical_items) && status.critical_items.length > 0) {
|
|
187
|
+
for (const item of status.critical_items) {
|
|
188
|
+
gaps.push(`${item.kind}: ${item.detail}`);
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
if (gaps.length > 0) {
|
|
192
|
+
checks.push({
|
|
193
|
+
name: "operator_health",
|
|
194
|
+
status: "warning",
|
|
195
|
+
value: { gaps },
|
|
196
|
+
hint: "Address the above gaps; they're what 'run402 notifications' is designed to surface.",
|
|
197
|
+
});
|
|
198
|
+
} else {
|
|
199
|
+
checks.push({ name: "operator_health", status: "ok" });
|
|
200
|
+
}
|
|
201
|
+
} catch (err) {
|
|
202
|
+
// Operator status endpoint may not be reachable if the operator-binding
|
|
203
|
+
// substrate isn't deployed yet on the target API. Don't fail the whole
|
|
204
|
+
// doctor over it — emit as a soft warning.
|
|
205
|
+
checks.push({
|
|
206
|
+
name: "operator_health",
|
|
207
|
+
status: "skipped",
|
|
208
|
+
message: err instanceof Error ? err.message : String(err),
|
|
209
|
+
...(verbose && { hint: "GET /agent/v1/operator/status not reachable; requires v1.55+ gateway." }),
|
|
210
|
+
});
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
// 'warning' counts as ok for exit-code purposes — gaps are surfaced in
|
|
214
|
+
// output but don't fail the doctor. Only hard 'error' / 'missing' /
|
|
215
|
+
// 'empty' fail.
|
|
216
|
+
const allOk = checks.every((c) => c.status === "ok" || c.status === "warning" || c.status === "skipped");
|
|
169
217
|
|
|
170
218
|
if (json) {
|
|
171
219
|
console.log(JSON.stringify({ ok: allOk, checks }, null, 2));
|
|
@@ -175,12 +223,17 @@ export async function run(sub, args = []) {
|
|
|
175
223
|
for (const c of checks) {
|
|
176
224
|
const icon =
|
|
177
225
|
c.status === "ok" ? "✓"
|
|
226
|
+
: c.status === "warning" ? "⚠"
|
|
227
|
+
: c.status === "skipped" ? "·"
|
|
178
228
|
: c.status === "missing" || c.status === "empty" ? "⚠"
|
|
179
229
|
: "✗";
|
|
180
230
|
const status = c.status === "ok" ? "ok" : c.status;
|
|
181
231
|
console.log(` ${icon} ${c.name.padEnd(16)} ${status}`);
|
|
182
232
|
if (c.hint) console.log(` → ${c.hint}`);
|
|
183
233
|
if (c.message) console.log(` ${c.message}`);
|
|
234
|
+
if (c.value && c.value.gaps && Array.isArray(c.value.gaps)) {
|
|
235
|
+
for (const gap of c.value.gaps) console.log(` • ${gap}`);
|
|
236
|
+
}
|
|
184
237
|
}
|
|
185
238
|
}
|
|
186
239
|
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* run402 notifications — Operator health notifications.
|
|
3
|
+
*
|
|
4
|
+
* Wraps the v1.55 `add-operator-health-notifications` API surface:
|
|
5
|
+
*
|
|
6
|
+
* - run402 notifications list [--type ...] [--since ...] [--limit N] [--offset N]
|
|
7
|
+
* - run402 notifications get <id>
|
|
8
|
+
* - run402 notifications preferences [get|set ...]
|
|
9
|
+
* - run402 notifications test
|
|
10
|
+
* - run402 webhook-secret rotate
|
|
11
|
+
*
|
|
12
|
+
* All commands use the allowance-wallet auth path (SIWX). The assurance
|
|
13
|
+
* ladder is enforced server-side; CLI surfaces 403 errors with the
|
|
14
|
+
* required-assurance hint.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import { allowanceAuthHeaders } from "./config.mjs";
|
|
18
|
+
import { getSdk } from "./sdk.mjs";
|
|
19
|
+
import { reportSdkError, fail } from "./sdk-errors.mjs";
|
|
20
|
+
import { assertKnownFlags, flagValue, normalizeArgv, positionalArgs } from "./argparse.mjs";
|
|
21
|
+
|
|
22
|
+
const HELP = `run402 notifications — Operator health notifications
|
|
23
|
+
|
|
24
|
+
Usage:
|
|
25
|
+
run402 notifications list [--type <event_type>] [--since <iso>] [--limit N] [--offset N]
|
|
26
|
+
run402 notifications get <id>
|
|
27
|
+
run402 notifications preferences
|
|
28
|
+
run402 notifications preferences set <key>=<value> [<key>=<value> ...]
|
|
29
|
+
run402 notifications test
|
|
30
|
+
|
|
31
|
+
Examples:
|
|
32
|
+
run402 notifications list --limit 10
|
|
33
|
+
run402 notifications list --type project_past_due --since 2026-05-01T00:00:00Z
|
|
34
|
+
run402 notifications get 9b21fa0a-...
|
|
35
|
+
run402 notifications preferences
|
|
36
|
+
run402 notifications preferences set digest_cadence=weekly digest_day_of_week=1
|
|
37
|
+
run402 notifications preferences set webhook_url=https://my-receiver.example.com/hook
|
|
38
|
+
run402 notifications test
|
|
39
|
+
|
|
40
|
+
Auth ladder (enforced server-side):
|
|
41
|
+
- SIWX wallet: read own notifications + preferences
|
|
42
|
+
- email_verified: cross-wallet rollup reads + multi-wallet preference updates
|
|
43
|
+
- operator_passkey: webhook URL changes, webhook secret rotation
|
|
44
|
+
`;
|
|
45
|
+
|
|
46
|
+
async function list(args) {
|
|
47
|
+
const parsedArgs = normalizeArgv(args);
|
|
48
|
+
const valueFlags = ["--type", "--since", "--limit", "--offset"];
|
|
49
|
+
assertKnownFlags(parsedArgs, [...valueFlags, "--help", "-h"], valueFlags);
|
|
50
|
+
const extra = positionalArgs(parsedArgs, valueFlags);
|
|
51
|
+
if (extra.length > 0) {
|
|
52
|
+
fail({ code: "BAD_USAGE", message: `Unexpected argument for notifications list: ${extra[0]}` });
|
|
53
|
+
}
|
|
54
|
+
allowanceAuthHeaders("/agent/v1/notifications");
|
|
55
|
+
const opts = {};
|
|
56
|
+
const type = flagValue(parsedArgs, "--type");
|
|
57
|
+
const since = flagValue(parsedArgs, "--since");
|
|
58
|
+
const limit = flagValue(parsedArgs, "--limit");
|
|
59
|
+
const offset = flagValue(parsedArgs, "--offset");
|
|
60
|
+
if (type) opts.type = type;
|
|
61
|
+
if (since) opts.since = since;
|
|
62
|
+
if (limit != null) opts.limit = Number(limit);
|
|
63
|
+
if (offset != null) opts.offset = Number(offset);
|
|
64
|
+
try {
|
|
65
|
+
const data = await getSdk().admin.listNotifications(opts);
|
|
66
|
+
console.log(JSON.stringify(data, null, 2));
|
|
67
|
+
} catch (err) {
|
|
68
|
+
reportSdkError(err);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
async function get(args) {
|
|
73
|
+
const parsedArgs = normalizeArgv(args);
|
|
74
|
+
assertKnownFlags(parsedArgs, ["--help", "-h"]);
|
|
75
|
+
const positionals = positionalArgs(parsedArgs);
|
|
76
|
+
if (positionals.length !== 1) {
|
|
77
|
+
fail({ code: "BAD_USAGE", message: "Usage: run402 notifications get <id>" });
|
|
78
|
+
}
|
|
79
|
+
allowanceAuthHeaders("/agent/v1/notifications");
|
|
80
|
+
try {
|
|
81
|
+
const data = await getSdk().admin.getNotification(positionals[0]);
|
|
82
|
+
console.log(JSON.stringify(data, null, 2));
|
|
83
|
+
} catch (err) {
|
|
84
|
+
reportSdkError(err);
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
async function preferences(args) {
|
|
89
|
+
const parsedArgs = normalizeArgv(args);
|
|
90
|
+
assertKnownFlags(parsedArgs, ["--help", "-h"]);
|
|
91
|
+
const positionals = positionalArgs(parsedArgs);
|
|
92
|
+
allowanceAuthHeaders("/agent/v1/notifications/preferences");
|
|
93
|
+
|
|
94
|
+
if (positionals.length === 0) {
|
|
95
|
+
// GET preferences
|
|
96
|
+
try {
|
|
97
|
+
const data = await getSdk().admin.getNotificationPreferences();
|
|
98
|
+
console.log(JSON.stringify(data, null, 2));
|
|
99
|
+
} catch (err) {
|
|
100
|
+
reportSdkError(err);
|
|
101
|
+
}
|
|
102
|
+
return;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
if (positionals[0] !== "set") {
|
|
106
|
+
fail({ code: "BAD_USAGE", message: "Usage: run402 notifications preferences [set <key>=<value> ...]" });
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
// SET — parse remaining positional args as key=value
|
|
110
|
+
const patch = {};
|
|
111
|
+
for (const kv of positionals.slice(1)) {
|
|
112
|
+
const eq = kv.indexOf("=");
|
|
113
|
+
if (eq <= 0) {
|
|
114
|
+
fail({ code: "BAD_USAGE", message: `Expected key=value, got: ${kv}` });
|
|
115
|
+
}
|
|
116
|
+
const key = kv.slice(0, eq);
|
|
117
|
+
const rawValue = kv.slice(eq + 1);
|
|
118
|
+
if (key === "digest_day_of_week" || key === "digest_hour_utc") {
|
|
119
|
+
patch[key] = Number(rawValue);
|
|
120
|
+
} else if (key === "webhook_url" && (rawValue === "null" || rawValue === "")) {
|
|
121
|
+
patch[key] = null;
|
|
122
|
+
} else {
|
|
123
|
+
patch[key] = rawValue;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
try {
|
|
127
|
+
const data = await getSdk().admin.setNotificationPreferences(patch);
|
|
128
|
+
console.log(JSON.stringify(data, null, 2));
|
|
129
|
+
} catch (err) {
|
|
130
|
+
reportSdkError(err);
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
async function test(args) {
|
|
135
|
+
const parsedArgs = normalizeArgv(args);
|
|
136
|
+
assertKnownFlags(parsedArgs, ["--help", "-h"]);
|
|
137
|
+
const extra = positionalArgs(parsedArgs);
|
|
138
|
+
if (extra.length > 0) {
|
|
139
|
+
fail({ code: "BAD_USAGE", message: `Unexpected argument for notifications test: ${extra[0]}` });
|
|
140
|
+
}
|
|
141
|
+
allowanceAuthHeaders("/agent/v1/notifications/test");
|
|
142
|
+
try {
|
|
143
|
+
const data = await getSdk().admin.testNotification();
|
|
144
|
+
console.log(JSON.stringify(data, null, 2));
|
|
145
|
+
} catch (err) {
|
|
146
|
+
reportSdkError(err);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export async function run(sub, args) {
|
|
151
|
+
if (!sub || sub === "--help" || sub === "-h") {
|
|
152
|
+
console.log(HELP);
|
|
153
|
+
process.exit(0);
|
|
154
|
+
}
|
|
155
|
+
switch (sub) {
|
|
156
|
+
case "list":
|
|
157
|
+
await list(args);
|
|
158
|
+
return;
|
|
159
|
+
case "get":
|
|
160
|
+
await get(args);
|
|
161
|
+
return;
|
|
162
|
+
case "preferences":
|
|
163
|
+
await preferences(args);
|
|
164
|
+
return;
|
|
165
|
+
case "test":
|
|
166
|
+
await test(args);
|
|
167
|
+
return;
|
|
168
|
+
default:
|
|
169
|
+
fail({ code: "BAD_USAGE", message: `Unknown notifications subcommand: ${sub}\n\n${HELP}` });
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
// `run402 webhook-secret rotate` lives in cli/lib/webhook-secret.mjs as
|
|
174
|
+
// its own top-level command, separate from this notifications module.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* run402 webhook-secret — Manage the operator webhook signing secret.
|
|
3
|
+
*
|
|
4
|
+
* Split out from notifications.mjs so the SURFACE inventory parser sees
|
|
5
|
+
* `webhook-secret:rotate` as its own command, separate from the
|
|
6
|
+
* `notifications:*` group.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { allowanceAuthHeaders } from "./config.mjs";
|
|
10
|
+
import { getSdk } from "./sdk.mjs";
|
|
11
|
+
import { reportSdkError, fail } from "./sdk-errors.mjs";
|
|
12
|
+
import { assertKnownFlags, normalizeArgv } from "./argparse.mjs";
|
|
13
|
+
|
|
14
|
+
const HELP = `run402 webhook-secret — Manage the operator webhook signing secret
|
|
15
|
+
|
|
16
|
+
Usage:
|
|
17
|
+
run402 webhook-secret rotate
|
|
18
|
+
|
|
19
|
+
Notes:
|
|
20
|
+
- Returns the new plaintext secret EXACTLY once. Store it immediately.
|
|
21
|
+
- Previous secret remains valid for 24 hours after rotation.
|
|
22
|
+
- Requires operator_passkey assurance level.
|
|
23
|
+
`;
|
|
24
|
+
|
|
25
|
+
export async function run(sub, args = []) {
|
|
26
|
+
if (!sub || sub === "--help" || sub === "-h") {
|
|
27
|
+
console.log(HELP);
|
|
28
|
+
process.exit(0);
|
|
29
|
+
}
|
|
30
|
+
if (sub !== "rotate") {
|
|
31
|
+
fail({ code: "BAD_USAGE", message: "Usage: run402 webhook-secret rotate" });
|
|
32
|
+
}
|
|
33
|
+
const parsedArgs = normalizeArgv(args);
|
|
34
|
+
assertKnownFlags(parsedArgs, ["--help", "-h"]);
|
|
35
|
+
allowanceAuthHeaders("/agent/v1/webhook-secret/rotate");
|
|
36
|
+
try {
|
|
37
|
+
const data = await getSdk().admin.rotateWebhookSecret();
|
|
38
|
+
console.log(JSON.stringify(data, null, 2));
|
|
39
|
+
console.error(""); // separator
|
|
40
|
+
console.error("⚠ Store this secret NOW — it will not be shown again.");
|
|
41
|
+
console.error("⚠ Your previous secret remains valid for the next 24 hours.");
|
|
42
|
+
} catch (err) {
|
|
43
|
+
reportSdkError(err);
|
|
44
|
+
}
|
|
45
|
+
}
|
package/package.json
CHANGED
|
@@ -65,6 +65,108 @@ export interface AdminProjectFinanceResult {
|
|
|
65
65
|
}>;
|
|
66
66
|
notes: string;
|
|
67
67
|
}
|
|
68
|
+
export type NotificationKind = "digest" | "lifecycle_event" | "threshold_alert" | "missing_verified_recipient";
|
|
69
|
+
export type NotificationChannel = "email" | "webhook" | "skipped";
|
|
70
|
+
export type NotificationDeliveryStatus = "delivered" | "failed_transient" | "failed_permanent" | "skipped_no_recipient" | "skipped_disabled";
|
|
71
|
+
export interface NotificationRow {
|
|
72
|
+
id: string;
|
|
73
|
+
recipient_email: string | null;
|
|
74
|
+
kind: NotificationKind;
|
|
75
|
+
event_type: string | null;
|
|
76
|
+
channel: NotificationChannel;
|
|
77
|
+
delivery_status: NotificationDeliveryStatus;
|
|
78
|
+
delivery_error: string | null;
|
|
79
|
+
attempt_count: number;
|
|
80
|
+
is_test: boolean;
|
|
81
|
+
related_project_id: string | null;
|
|
82
|
+
related_billing_account_id: string | null;
|
|
83
|
+
related_wallet_address: string | null;
|
|
84
|
+
created_at: string;
|
|
85
|
+
redacted_at: string | null;
|
|
86
|
+
/** Payload JSON, or null when the row has been redacted. */
|
|
87
|
+
payload: Record<string, unknown> | null;
|
|
88
|
+
}
|
|
89
|
+
export interface ListNotificationsOptions {
|
|
90
|
+
type?: string;
|
|
91
|
+
/** ISO timestamp; only notifications created at or after this time. */
|
|
92
|
+
since?: string;
|
|
93
|
+
/** Default 50, max 200. */
|
|
94
|
+
limit?: number;
|
|
95
|
+
offset?: number;
|
|
96
|
+
}
|
|
97
|
+
export interface ListNotificationsResult {
|
|
98
|
+
notifications: NotificationRow[];
|
|
99
|
+
pagination: {
|
|
100
|
+
limit: number;
|
|
101
|
+
offset: number;
|
|
102
|
+
returned: number;
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
export interface NotificationPreferences {
|
|
106
|
+
channels: {
|
|
107
|
+
email: boolean;
|
|
108
|
+
webhook: boolean;
|
|
109
|
+
};
|
|
110
|
+
webhook_url: string | null;
|
|
111
|
+
webhook_signing_secret_configured: boolean;
|
|
112
|
+
digest_cadence: "off" | "daily" | "weekly" | "monthly";
|
|
113
|
+
/** 1=Monday..7=Sunday. */
|
|
114
|
+
digest_day_of_week: number;
|
|
115
|
+
/** 0..23 UTC. */
|
|
116
|
+
digest_hour_utc: number;
|
|
117
|
+
threshold_alerts: "off" | "digest_only" | "immediate";
|
|
118
|
+
lifecycle_events: "off" | "critical_only" | "all";
|
|
119
|
+
/** Schema-enforced; always "always". */
|
|
120
|
+
security_events: "always";
|
|
121
|
+
/** BCP-47 (e.g. "en-US"). */
|
|
122
|
+
locale: string;
|
|
123
|
+
/** IANA timezone (e.g. "UTC"). */
|
|
124
|
+
timezone: string;
|
|
125
|
+
}
|
|
126
|
+
export type NotificationPreferencesPatch = Partial<Omit<NotificationPreferences, "webhook_signing_secret_configured" | "security_events">> & {
|
|
127
|
+
/** Cannot be changed away from "always" — server returns 400. */
|
|
128
|
+
security_events?: "always";
|
|
129
|
+
};
|
|
130
|
+
export interface TestNotificationResult {
|
|
131
|
+
status: "queued";
|
|
132
|
+
source_event_id: string;
|
|
133
|
+
note: string;
|
|
134
|
+
}
|
|
135
|
+
export interface RotateWebhookSecretResult {
|
|
136
|
+
webhook_signing_secret: string;
|
|
137
|
+
rotated_at: string;
|
|
138
|
+
grace_window_hours: number;
|
|
139
|
+
note: string;
|
|
140
|
+
}
|
|
141
|
+
export interface OperatorStatusResult {
|
|
142
|
+
operator_contact: {
|
|
143
|
+
email_status: "none" | "pending" | "verified" | "bouncing";
|
|
144
|
+
passkey_status: "none" | "pending" | "verified";
|
|
145
|
+
recovery_gap: boolean;
|
|
146
|
+
};
|
|
147
|
+
critical_items: Array<{
|
|
148
|
+
kind: string;
|
|
149
|
+
detail: string;
|
|
150
|
+
}>;
|
|
151
|
+
skipped_notifications: Array<{
|
|
152
|
+
id: string;
|
|
153
|
+
event_type: string;
|
|
154
|
+
related_project_id: string | null;
|
|
155
|
+
related_billing_account_id: string | null;
|
|
156
|
+
related_wallet_address: string | null;
|
|
157
|
+
created_at: string;
|
|
158
|
+
}>;
|
|
159
|
+
billing_accounts: Array<Record<string, unknown>>;
|
|
160
|
+
projects: Array<Record<string, unknown>>;
|
|
161
|
+
active_thresholds: Array<{
|
|
162
|
+
resource: string;
|
|
163
|
+
level: "warn" | "critical";
|
|
164
|
+
scope_kind: string;
|
|
165
|
+
scope_id: string;
|
|
166
|
+
crossed_at: string;
|
|
167
|
+
last_observed_value: number | null;
|
|
168
|
+
}>;
|
|
169
|
+
}
|
|
68
170
|
export declare class Admin {
|
|
69
171
|
private readonly client;
|
|
70
172
|
constructor(client: Client);
|
|
@@ -78,6 +180,28 @@ export declare class Admin {
|
|
|
78
180
|
verifyAgentContactEmail(): Promise<AgentContactResult>;
|
|
79
181
|
/** Email a passkey enrollment link to the verified operator email. */
|
|
80
182
|
startOperatorPasskeyEnrollment(): Promise<AgentContactResult>;
|
|
183
|
+
/** List operator notification audit rows (paginated, filterable). */
|
|
184
|
+
listNotifications(opts?: ListNotificationsOptions): Promise<ListNotificationsResult>;
|
|
185
|
+
/** Retrieve a single notification audit row by id. */
|
|
186
|
+
getNotification(id: string): Promise<NotificationRow>;
|
|
187
|
+
/** Read the current operator notification preferences. */
|
|
188
|
+
getNotificationPreferences(): Promise<NotificationPreferences>;
|
|
189
|
+
/** Patch operator notification preferences (assurance ladder applies). */
|
|
190
|
+
setNotificationPreferences(patch: NotificationPreferencesPatch): Promise<NotificationPreferences>;
|
|
191
|
+
/**
|
|
192
|
+
* Trigger a real test notification. Sends a sample `project_past_due`
|
|
193
|
+
* event through the normal worker pipeline; the audit row is marked
|
|
194
|
+
* `is_test: true`. Rate-limited per wallet at 1/min.
|
|
195
|
+
*/
|
|
196
|
+
testNotification(): Promise<TestNotificationResult>;
|
|
197
|
+
/**
|
|
198
|
+
* Rotate the operator's webhook signing secret. The new plaintext secret
|
|
199
|
+
* is returned EXACTLY once. The previous secret remains valid for 24
|
|
200
|
+
* hours (dual-secret grace window). Requires `operator_passkey` assurance.
|
|
201
|
+
*/
|
|
202
|
+
rotateWebhookSecret(): Promise<RotateWebhookSecretResult>;
|
|
203
|
+
/** Compact operator-health snapshot for the authenticated wallet. */
|
|
204
|
+
getOperatorStatus(): Promise<OperatorStatusResult>;
|
|
81
205
|
/**
|
|
82
206
|
* Fetch per-project finance for platform operators.
|
|
83
207
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admin.d.ts","sourceRoot":"","sources":["../../src/namespaces/admin.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAG3C,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,MAAM,4BAA4B,GAAG,MAAM,GAAG,SAAS,GAAG,UAAU,CAAC;AAC3E,MAAM,MAAM,yBAAyB,GAAG,MAAM,GAAG,SAAS,GAAG,UAAU,CAAC;AACxE,MAAM,MAAM,mBAAmB,GAC3B,aAAa,GACb,eAAe,GACf,gBAAgB,GAChB,iBAAiB,GACjB,kBAAkB,CAAC;AAEvB,MAAM,WAAW,kBAAkB;IACjC,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,yBAAyB,EAAE,4BAA4B,CAAC;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;IACG,gBAAgB,IAAI,OAAO,CAAC,sBAAsB,CAAC;IAOzD;;;;OAIG;IACG,mBAAmB,IAAI,OAAO,CAAC,yBAAyB,CAAC;IAO/D,qEAAqE;IAC/D,iBAAiB,IAAI,OAAO,CAAC,oBAAoB,CAAC;IAOxD;;;;;;;;OAQG;IACG,iBAAiB,CACrB,SAAS,EAAE,MAAM,EACjB,IAAI,GAAE,0BAA+B,GACpC,OAAO,CAAC,yBAAyB,CAAC;CAoBtC"}
|
|
@@ -54,6 +54,64 @@ export class Admin {
|
|
|
54
54
|
context: "starting operator passkey enrollment",
|
|
55
55
|
});
|
|
56
56
|
}
|
|
57
|
+
// ---------------------------------------------------------------------------
|
|
58
|
+
// Operator notifications (v1.55, add-operator-health-notifications).
|
|
59
|
+
// ---------------------------------------------------------------------------
|
|
60
|
+
/** List operator notification audit rows (paginated, filterable). */
|
|
61
|
+
async listNotifications(opts = {}) {
|
|
62
|
+
const q = [];
|
|
63
|
+
if (opts.type)
|
|
64
|
+
q.push(`type=${encodeURIComponent(opts.type)}`);
|
|
65
|
+
if (opts.since)
|
|
66
|
+
q.push(`since=${encodeURIComponent(opts.since)}`);
|
|
67
|
+
if (opts.limit != null)
|
|
68
|
+
q.push(`limit=${opts.limit}`);
|
|
69
|
+
if (opts.offset != null)
|
|
70
|
+
q.push(`offset=${opts.offset}`);
|
|
71
|
+
const url = q.length > 0
|
|
72
|
+
? `/agent/v1/notifications?${q.join("&")}`
|
|
73
|
+
: "/agent/v1/notifications";
|
|
74
|
+
return this.client.request(url, {
|
|
75
|
+
method: "GET",
|
|
76
|
+
context: "listing notifications",
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
/** Retrieve a single notification audit row by id. */
|
|
80
|
+
async getNotification(id) {
|
|
81
|
+
return this.client.request(`/agent/v1/notifications/${encodeURIComponent(id)}`, { method: "GET", context: "fetching notification" });
|
|
82
|
+
}
|
|
83
|
+
/** Read the current operator notification preferences. */
|
|
84
|
+
async getNotificationPreferences() {
|
|
85
|
+
return this.client.request("/agent/v1/notifications/preferences", { method: "GET", context: "fetching notification preferences" });
|
|
86
|
+
}
|
|
87
|
+
/** Patch operator notification preferences (assurance ladder applies). */
|
|
88
|
+
async setNotificationPreferences(patch) {
|
|
89
|
+
return this.client.request("/agent/v1/notifications/preferences", {
|
|
90
|
+
method: "PATCH",
|
|
91
|
+
body: patch,
|
|
92
|
+
context: "updating notification preferences",
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Trigger a real test notification. Sends a sample `project_past_due`
|
|
97
|
+
* event through the normal worker pipeline; the audit row is marked
|
|
98
|
+
* `is_test: true`. Rate-limited per wallet at 1/min.
|
|
99
|
+
*/
|
|
100
|
+
async testNotification() {
|
|
101
|
+
return this.client.request("/agent/v1/notifications/test", { method: "POST", context: "triggering test notification" });
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Rotate the operator's webhook signing secret. The new plaintext secret
|
|
105
|
+
* is returned EXACTLY once. The previous secret remains valid for 24
|
|
106
|
+
* hours (dual-secret grace window). Requires `operator_passkey` assurance.
|
|
107
|
+
*/
|
|
108
|
+
async rotateWebhookSecret() {
|
|
109
|
+
return this.client.request("/agent/v1/webhook-secret/rotate", { method: "POST", context: "rotating webhook signing secret" });
|
|
110
|
+
}
|
|
111
|
+
/** Compact operator-health snapshot for the authenticated wallet. */
|
|
112
|
+
async getOperatorStatus() {
|
|
113
|
+
return this.client.request("/agent/v1/operator/status", { method: "GET", context: "fetching operator status" });
|
|
114
|
+
}
|
|
57
115
|
/**
|
|
58
116
|
* Fetch per-project finance for platform operators.
|
|
59
117
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admin.js","sourceRoot":"","sources":["../../src/namespaces/admin.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAsE1C,MAAM,eAAe,GAAG,IAAI,GAAG,CAAqB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