@camstack/types 1.2.397 → 1.2.399
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/dist/addon.js +17 -2
- package/dist/addon.mjs +15 -3
- package/dist/capabilities/dishwasher.cap.d.ts +9 -0
- package/dist/capabilities/index.d.ts +2 -2
- package/dist/capabilities/notification-rules.cap.d.ts +92 -0
- package/dist/capabilities/osd-manager.cap.d.ts +24 -0
- package/dist/capabilities/pipeline-orchestrator.cap.d.ts +0 -16
- package/dist/capabilities/records.cap.d.ts +67 -3
- package/dist/capabilities/storage-admin.cap.d.ts +0 -2
- package/dist/capabilities/user-management.cap.d.ts +2 -28
- package/dist/client.js +88 -9
- package/dist/client.mjs +88 -9
- package/dist/enums/event-category.d.ts +9 -0
- package/dist/enums.js +1 -1
- package/dist/enums.mjs +1 -1
- package/dist/{event-category-kpu1bZMs.js → event-category-7AwNbPjm.js} +9 -0
- package/dist/{event-category-7pZEBmVg.mjs → event-category-BfJwUd2S.mjs} +9 -0
- package/dist/generated/addon-api.d.ts +7 -14
- package/dist/generated/addon-cap-facts.d.ts +1 -1
- package/dist/generated/method-access-map.d.ts +1 -1
- package/dist/generated/system-proxy.d.ts +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +305 -135
- package/dist/index.mjs +300 -134
- package/dist/interfaces/auth.d.ts +1 -1
- package/dist/interfaces/event-bus.d.ts +24 -5
- package/dist/notification/alert-episode.d.ts +7 -0
- package/dist/pipeline/auto-tune/detector-performance.d.ts +2 -1
- package/dist/pipeline/auto-tune/plan-schemas.d.ts +0 -28
- package/dist/pipeline/auto-tune/recommend.d.ts +9 -1
- package/dist/pipeline/load-balancing/share-election.d.ts +7 -0
- package/dist/records/errors.d.ts +9 -1
- package/dist/records/index.d.ts +1 -0
- package/dist/records/record-kind.d.ts +62 -2
- package/dist/records/records-access.d.ts +36 -1
- package/dist/records/transact-rules.d.ts +7 -0
- package/dist/schemas/auth-records.d.ts +0 -12
- package/dist/{sleep-Bo7fq491.js → sleep-CD18m9HF.js} +478 -311
- package/dist/{sleep-CueztlR1.mjs → sleep-DJFUfKvA.mjs} +461 -312
- package/package.json +1 -1
|
@@ -231,6 +231,8 @@ export declare const OsdSlotBindingSchema: z.ZodObject<{
|
|
|
231
231
|
"camera-offline": "camera-offline";
|
|
232
232
|
"camera-online": "camera-online";
|
|
233
233
|
"detection-blind": "detection-blind";
|
|
234
|
+
"device-attention-required": "device-attention-required";
|
|
235
|
+
"device-attention-resolved": "device-attention-resolved";
|
|
234
236
|
"device-battery-low": "device-battery-low";
|
|
235
237
|
"device-battery-normal": "device-battery-normal";
|
|
236
238
|
"device-consumable-low": "device-consumable-low";
|
|
@@ -243,6 +245,8 @@ export declare const OsdSlotBindingSchema: z.ZodObject<{
|
|
|
243
245
|
"device-tank-low": "device-tank-low";
|
|
244
246
|
"device-tank-normal": "device-tank-normal";
|
|
245
247
|
"export-completed": "export-completed";
|
|
248
|
+
"motion-calm": "motion-calm";
|
|
249
|
+
"motion-noisy": "motion-noisy";
|
|
246
250
|
"node-inference-unavailable": "node-inference-unavailable";
|
|
247
251
|
"node-offline": "node-offline";
|
|
248
252
|
"node-online": "node-online";
|
|
@@ -432,6 +436,8 @@ export declare const OsdSlotViewSchema: z.ZodObject<{
|
|
|
432
436
|
"camera-offline": "camera-offline";
|
|
433
437
|
"camera-online": "camera-online";
|
|
434
438
|
"detection-blind": "detection-blind";
|
|
439
|
+
"device-attention-required": "device-attention-required";
|
|
440
|
+
"device-attention-resolved": "device-attention-resolved";
|
|
435
441
|
"device-battery-low": "device-battery-low";
|
|
436
442
|
"device-battery-normal": "device-battery-normal";
|
|
437
443
|
"device-consumable-low": "device-consumable-low";
|
|
@@ -444,6 +450,8 @@ export declare const OsdSlotViewSchema: z.ZodObject<{
|
|
|
444
450
|
"device-tank-low": "device-tank-low";
|
|
445
451
|
"device-tank-normal": "device-tank-normal";
|
|
446
452
|
"export-completed": "export-completed";
|
|
453
|
+
"motion-calm": "motion-calm";
|
|
454
|
+
"motion-noisy": "motion-noisy";
|
|
447
455
|
"node-inference-unavailable": "node-inference-unavailable";
|
|
448
456
|
"node-offline": "node-offline";
|
|
449
457
|
"node-online": "node-online";
|
|
@@ -705,6 +713,8 @@ export declare const osdManagerCapability: {
|
|
|
705
713
|
"camera-offline": "camera-offline";
|
|
706
714
|
"camera-online": "camera-online";
|
|
707
715
|
"detection-blind": "detection-blind";
|
|
716
|
+
"device-attention-required": "device-attention-required";
|
|
717
|
+
"device-attention-resolved": "device-attention-resolved";
|
|
708
718
|
"device-battery-low": "device-battery-low";
|
|
709
719
|
"device-battery-normal": "device-battery-normal";
|
|
710
720
|
"device-consumable-low": "device-consumable-low";
|
|
@@ -717,6 +727,8 @@ export declare const osdManagerCapability: {
|
|
|
717
727
|
"device-tank-low": "device-tank-low";
|
|
718
728
|
"device-tank-normal": "device-tank-normal";
|
|
719
729
|
"export-completed": "export-completed";
|
|
730
|
+
"motion-calm": "motion-calm";
|
|
731
|
+
"motion-noisy": "motion-noisy";
|
|
720
732
|
"node-inference-unavailable": "node-inference-unavailable";
|
|
721
733
|
"node-offline": "node-offline";
|
|
722
734
|
"node-online": "node-online";
|
|
@@ -997,6 +1009,8 @@ export declare const osdManagerCapability: {
|
|
|
997
1009
|
"camera-offline": "camera-offline";
|
|
998
1010
|
"camera-online": "camera-online";
|
|
999
1011
|
"detection-blind": "detection-blind";
|
|
1012
|
+
"device-attention-required": "device-attention-required";
|
|
1013
|
+
"device-attention-resolved": "device-attention-resolved";
|
|
1000
1014
|
"device-battery-low": "device-battery-low";
|
|
1001
1015
|
"device-battery-normal": "device-battery-normal";
|
|
1002
1016
|
"device-consumable-low": "device-consumable-low";
|
|
@@ -1009,6 +1023,8 @@ export declare const osdManagerCapability: {
|
|
|
1009
1023
|
"device-tank-low": "device-tank-low";
|
|
1010
1024
|
"device-tank-normal": "device-tank-normal";
|
|
1011
1025
|
"export-completed": "export-completed";
|
|
1026
|
+
"motion-calm": "motion-calm";
|
|
1027
|
+
"motion-noisy": "motion-noisy";
|
|
1012
1028
|
"node-inference-unavailable": "node-inference-unavailable";
|
|
1013
1029
|
"node-offline": "node-offline";
|
|
1014
1030
|
"node-online": "node-online";
|
|
@@ -1197,6 +1213,8 @@ export declare const osdManagerCapability: {
|
|
|
1197
1213
|
"camera-offline": "camera-offline";
|
|
1198
1214
|
"camera-online": "camera-online";
|
|
1199
1215
|
"detection-blind": "detection-blind";
|
|
1216
|
+
"device-attention-required": "device-attention-required";
|
|
1217
|
+
"device-attention-resolved": "device-attention-resolved";
|
|
1200
1218
|
"device-battery-low": "device-battery-low";
|
|
1201
1219
|
"device-battery-normal": "device-battery-normal";
|
|
1202
1220
|
"device-consumable-low": "device-consumable-low";
|
|
@@ -1209,6 +1227,8 @@ export declare const osdManagerCapability: {
|
|
|
1209
1227
|
"device-tank-low": "device-tank-low";
|
|
1210
1228
|
"device-tank-normal": "device-tank-normal";
|
|
1211
1229
|
"export-completed": "export-completed";
|
|
1230
|
+
"motion-calm": "motion-calm";
|
|
1231
|
+
"motion-noisy": "motion-noisy";
|
|
1212
1232
|
"node-inference-unavailable": "node-inference-unavailable";
|
|
1213
1233
|
"node-offline": "node-offline";
|
|
1214
1234
|
"node-online": "node-online";
|
|
@@ -1441,6 +1461,8 @@ export declare const osdManagerCapability: {
|
|
|
1441
1461
|
"camera-offline": "camera-offline";
|
|
1442
1462
|
"camera-online": "camera-online";
|
|
1443
1463
|
"detection-blind": "detection-blind";
|
|
1464
|
+
"device-attention-required": "device-attention-required";
|
|
1465
|
+
"device-attention-resolved": "device-attention-resolved";
|
|
1444
1466
|
"device-battery-low": "device-battery-low";
|
|
1445
1467
|
"device-battery-normal": "device-battery-normal";
|
|
1446
1468
|
"device-consumable-low": "device-consumable-low";
|
|
@@ -1453,6 +1475,8 @@ export declare const osdManagerCapability: {
|
|
|
1453
1475
|
"device-tank-low": "device-tank-low";
|
|
1454
1476
|
"device-tank-normal": "device-tank-normal";
|
|
1455
1477
|
"export-completed": "export-completed";
|
|
1478
|
+
"motion-calm": "motion-calm";
|
|
1479
|
+
"motion-noisy": "motion-noisy";
|
|
1456
1480
|
"node-inference-unavailable": "node-inference-unavailable";
|
|
1457
1481
|
"node-offline": "node-offline";
|
|
1458
1482
|
"node-online": "node-online";
|
|
@@ -1401,8 +1401,6 @@ export declare const pipelineOrchestratorCapability: {
|
|
|
1401
1401
|
modelId: z.ZodString;
|
|
1402
1402
|
}, z.core.$strip>, z.ZodObject<{
|
|
1403
1403
|
kind: z.ZodLiteral<"cpu-device">;
|
|
1404
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1405
|
-
kind: z.ZodLiteral<"coral-untouched">;
|
|
1406
1404
|
}, z.core.$strip>, z.ZodObject<{
|
|
1407
1405
|
kind: z.ZodLiteral<"device-disabled">;
|
|
1408
1406
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -1459,8 +1457,6 @@ export declare const pipelineOrchestratorCapability: {
|
|
|
1459
1457
|
modelId: z.ZodString;
|
|
1460
1458
|
}, z.core.$strip>, z.ZodObject<{
|
|
1461
1459
|
kind: z.ZodLiteral<"cpu-device">;
|
|
1462
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1463
|
-
kind: z.ZodLiteral<"coral-untouched">;
|
|
1464
1460
|
}, z.core.$strip>, z.ZodObject<{
|
|
1465
1461
|
kind: z.ZodLiteral<"device-disabled">;
|
|
1466
1462
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -1531,10 +1527,6 @@ export declare const pipelineOrchestratorCapability: {
|
|
|
1531
1527
|
}, z.core.$strip>, z.ZodObject<{
|
|
1532
1528
|
kind: z.ZodLiteral<"detector-store-unreadable">;
|
|
1533
1529
|
error: z.ZodString;
|
|
1534
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1535
|
-
kind: z.ZodLiteral<"coral-enabled">;
|
|
1536
|
-
nodeId: z.ZodString;
|
|
1537
|
-
deviceKey: z.ZodString;
|
|
1538
1530
|
}, z.core.$strip>, z.ZodObject<{
|
|
1539
1531
|
kind: z.ZodLiteral<"custom-pin-kept">;
|
|
1540
1532
|
nodeId: z.ZodString;
|
|
@@ -1660,8 +1652,6 @@ export declare const pipelineOrchestratorCapability: {
|
|
|
1660
1652
|
modelId: z.ZodString;
|
|
1661
1653
|
}, z.core.$strip>, z.ZodObject<{
|
|
1662
1654
|
kind: z.ZodLiteral<"cpu-device">;
|
|
1663
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1664
|
-
kind: z.ZodLiteral<"coral-untouched">;
|
|
1665
1655
|
}, z.core.$strip>, z.ZodObject<{
|
|
1666
1656
|
kind: z.ZodLiteral<"device-disabled">;
|
|
1667
1657
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -1718,8 +1708,6 @@ export declare const pipelineOrchestratorCapability: {
|
|
|
1718
1708
|
modelId: z.ZodString;
|
|
1719
1709
|
}, z.core.$strip>, z.ZodObject<{
|
|
1720
1710
|
kind: z.ZodLiteral<"cpu-device">;
|
|
1721
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1722
|
-
kind: z.ZodLiteral<"coral-untouched">;
|
|
1723
1711
|
}, z.core.$strip>, z.ZodObject<{
|
|
1724
1712
|
kind: z.ZodLiteral<"device-disabled">;
|
|
1725
1713
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -1790,10 +1778,6 @@ export declare const pipelineOrchestratorCapability: {
|
|
|
1790
1778
|
}, z.core.$strip>, z.ZodObject<{
|
|
1791
1779
|
kind: z.ZodLiteral<"detector-store-unreadable">;
|
|
1792
1780
|
error: z.ZodString;
|
|
1793
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
1794
|
-
kind: z.ZodLiteral<"coral-enabled">;
|
|
1795
|
-
nodeId: z.ZodString;
|
|
1796
|
-
deviceKey: z.ZodString;
|
|
1797
1781
|
}, z.core.$strip>, z.ZodObject<{
|
|
1798
1782
|
kind: z.ZodLiteral<"custom-pin-kept">;
|
|
1799
1783
|
nodeId: z.ZodString;
|
|
@@ -109,9 +109,37 @@ export declare const DeclareKindResultSchema: z.ZodObject<{
|
|
|
109
109
|
updated: "updated";
|
|
110
110
|
}>;
|
|
111
111
|
createdIndexes: z.ZodArray<z.ZodString>;
|
|
112
|
-
adoptionPending: z.ZodNull;
|
|
113
112
|
}, z.core.$strip>;
|
|
114
113
|
export type DeclareKindResult = z.infer<typeof DeclareKindResultSchema>;
|
|
114
|
+
/**
|
|
115
|
+
* One op of a `transact`: the single-row writes, each on a kind of the caller.
|
|
116
|
+
* All ops of one call share ONE database file and ONE `transactFamily`.
|
|
117
|
+
*/
|
|
118
|
+
export declare const RecordTransactOpSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
119
|
+
op: z.ZodLiteral<"put">;
|
|
120
|
+
kind: z.ZodString;
|
|
121
|
+
record: z.ZodObject<{
|
|
122
|
+
id: z.ZodString;
|
|
123
|
+
deviceId: z.ZodOptional<z.ZodNumber>;
|
|
124
|
+
at: z.ZodOptional<z.ZodNumber>;
|
|
125
|
+
expiresAt: z.ZodOptional<z.ZodNumber>;
|
|
126
|
+
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
127
|
+
}, z.core.$strip>;
|
|
128
|
+
ifRev: z.ZodOptional<z.ZodNumber>;
|
|
129
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
130
|
+
op: z.ZodLiteral<"patch">;
|
|
131
|
+
kind: z.ZodString;
|
|
132
|
+
id: z.ZodString;
|
|
133
|
+
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
134
|
+
at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
135
|
+
expiresAt: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
136
|
+
ifRev: z.ZodOptional<z.ZodNumber>;
|
|
137
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
138
|
+
op: z.ZodLiteral<"delete">;
|
|
139
|
+
kind: z.ZodString;
|
|
140
|
+
id: z.ZodString;
|
|
141
|
+
}, z.core.$strip>], "op">;
|
|
142
|
+
export type RecordTransactOp = z.infer<typeof RecordTransactOpSchema>;
|
|
115
143
|
export declare const RecordSecretRefsSchema: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
116
144
|
export declare const recordsCapability: {
|
|
117
145
|
readonly name: 'records';
|
|
@@ -170,7 +198,6 @@ export declare const recordsCapability: {
|
|
|
170
198
|
maxDataBytes: z.ZodDefault<z.ZodNumber>;
|
|
171
199
|
secretPaths: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
172
200
|
secretArrayKeys: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
173
|
-
adoptsFrom: z.ZodOptional<z.ZodString>;
|
|
174
201
|
transactFamily: z.ZodOptional<z.ZodString>;
|
|
175
202
|
entry: z.ZodOptional<z.ZodObject<{
|
|
176
203
|
title: z.ZodString;
|
|
@@ -187,7 +214,6 @@ export declare const recordsCapability: {
|
|
|
187
214
|
updated: "updated";
|
|
188
215
|
}>;
|
|
189
216
|
createdIndexes: z.ZodArray<z.ZodString>;
|
|
190
|
-
adoptionPending: z.ZodNull;
|
|
191
217
|
}, z.core.$strip>>;
|
|
192
218
|
}, z.core.$strip>, "mutation">;
|
|
193
219
|
readonly get: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
|
|
@@ -374,6 +400,44 @@ export declare const recordsCapability: {
|
|
|
374
400
|
deleted: z.ZodNumber;
|
|
375
401
|
secretRefs: z.ZodArray<z.ZodString>;
|
|
376
402
|
}, z.core.$strip>, "mutation">;
|
|
403
|
+
/**
|
|
404
|
+
* Several single-row writes (put / patch / delete) in ONE SQLite transaction:
|
|
405
|
+
* all land or none does. Every op's kind must sit in one file and share one
|
|
406
|
+
* `transactFamily` (`records/transact-refused` otherwise). Results are in op order.
|
|
407
|
+
*/
|
|
408
|
+
readonly transact: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
|
|
409
|
+
ops: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
410
|
+
op: z.ZodLiteral<"put">;
|
|
411
|
+
kind: z.ZodString;
|
|
412
|
+
record: z.ZodObject<{
|
|
413
|
+
id: z.ZodString;
|
|
414
|
+
deviceId: z.ZodOptional<z.ZodNumber>;
|
|
415
|
+
at: z.ZodOptional<z.ZodNumber>;
|
|
416
|
+
expiresAt: z.ZodOptional<z.ZodNumber>;
|
|
417
|
+
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
418
|
+
}, z.core.$strip>;
|
|
419
|
+
ifRev: z.ZodOptional<z.ZodNumber>;
|
|
420
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
421
|
+
op: z.ZodLiteral<"patch">;
|
|
422
|
+
kind: z.ZodString;
|
|
423
|
+
id: z.ZodString;
|
|
424
|
+
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
425
|
+
at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
426
|
+
expiresAt: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
427
|
+
ifRev: z.ZodOptional<z.ZodNumber>;
|
|
428
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
429
|
+
op: z.ZodLiteral<"delete">;
|
|
430
|
+
kind: z.ZodString;
|
|
431
|
+
id: z.ZodString;
|
|
432
|
+
}, z.core.$strip>], "op">>;
|
|
433
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
434
|
+
results: z.ZodArray<z.ZodObject<{
|
|
435
|
+
rev: z.ZodNullable<z.ZodNumber>;
|
|
436
|
+
deleted: z.ZodBoolean;
|
|
437
|
+
}, z.core.$strip>>;
|
|
438
|
+
releasedRefs: z.ZodArray<z.ZodString>;
|
|
439
|
+
secretRefs: z.ZodArray<z.ZodString>;
|
|
440
|
+
}, z.core.$strip>, "mutation">;
|
|
377
441
|
/** The D865 hook body: every kind of this addon declared `deviceRemoval: 'delete'`. */
|
|
378
442
|
readonly deleteDevice: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
|
|
379
443
|
deviceId: z.ZodNumber;
|
|
@@ -91,7 +91,6 @@ export declare const StorageKindSchema: z.ZodObject<{
|
|
|
91
91
|
maxDataBytes: z.ZodDefault<z.ZodNumber>;
|
|
92
92
|
secretPaths: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
93
93
|
secretArrayKeys: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
94
|
-
adoptsFrom: z.ZodOptional<z.ZodString>;
|
|
95
94
|
transactFamily: z.ZodOptional<z.ZodString>;
|
|
96
95
|
entry: z.ZodOptional<z.ZodObject<{
|
|
97
96
|
title: z.ZodString;
|
|
@@ -220,7 +219,6 @@ export declare const storageAdminCapability: {
|
|
|
220
219
|
maxDataBytes: z.ZodDefault<z.ZodNumber>;
|
|
221
220
|
secretPaths: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
222
221
|
secretArrayKeys: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
223
|
-
adoptsFrom: z.ZodOptional<z.ZodString>;
|
|
224
222
|
transactFamily: z.ZodOptional<z.ZodString>;
|
|
225
223
|
entry: z.ZodOptional<z.ZodObject<{
|
|
226
224
|
title: z.ZodString;
|
|
@@ -167,16 +167,6 @@ declare const UpdateUserInputSchema: z.ZodObject<{
|
|
|
167
167
|
includeLinked: z.ZodOptional<z.ZodBoolean>;
|
|
168
168
|
}, z.core.$strip>], "type">>>>;
|
|
169
169
|
}, z.core.$strip>;
|
|
170
|
-
declare const ApiKeySummarySchema: z.ZodObject<{
|
|
171
|
-
id: z.ZodString;
|
|
172
|
-
label: z.ZodString;
|
|
173
|
-
isAdmin: z.ZodDefault<z.ZodBoolean>;
|
|
174
|
-
allowedProviders: z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodLiteral<"*">]>>;
|
|
175
|
-
allowedDevices: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodLiteral<"*">]>>>;
|
|
176
|
-
tokenPrefix: z.ZodString;
|
|
177
|
-
createdAt: z.ZodNumber;
|
|
178
|
-
lastUsedAt: z.ZodOptional<z.ZodNumber>;
|
|
179
|
-
}, z.core.$strip>;
|
|
180
170
|
declare const OauthSessionSummarySchema: z.ZodObject<{
|
|
181
171
|
id: z.ZodString;
|
|
182
172
|
userId: z.ZodString;
|
|
@@ -235,8 +225,7 @@ declare const OauthSessionSummarySchema: z.ZodObject<{
|
|
|
235
225
|
revokedAt: z.ZodNullable<z.ZodNumber>;
|
|
236
226
|
}, z.core.$strip>;
|
|
237
227
|
/**
|
|
238
|
-
* user-management — singleton capability for user accounts
|
|
239
|
-
* legacy API-key rows.
|
|
228
|
+
* user-management — singleton capability for user accounts.
|
|
240
229
|
*
|
|
241
230
|
* v2 model: every method gated by `auth: 'admin'`. Admin-only delegation
|
|
242
231
|
* — the subset check on `setUserScopes` is moot
|
|
@@ -613,21 +602,6 @@ export declare const userManagementCapability: {
|
|
|
613
602
|
updatedAt: z.ZodNumber;
|
|
614
603
|
passwordHash: z.ZodString;
|
|
615
604
|
}, z.core.$strip>>, "mutation">;
|
|
616
|
-
readonly listApiKeys: import("./capability-definition.js").CapabilityMethodSchema<z.ZodVoid, z.ZodArray<z.ZodObject<{
|
|
617
|
-
id: z.ZodString;
|
|
618
|
-
label: z.ZodString;
|
|
619
|
-
isAdmin: z.ZodDefault<z.ZodBoolean>;
|
|
620
|
-
allowedProviders: z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodLiteral<"*">]>>;
|
|
621
|
-
allowedDevices: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodLiteral<"*">]>>>;
|
|
622
|
-
tokenPrefix: z.ZodString;
|
|
623
|
-
createdAt: z.ZodNumber;
|
|
624
|
-
lastUsedAt: z.ZodOptional<z.ZodNumber>;
|
|
625
|
-
}, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
|
|
626
|
-
readonly revokeApiKey: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
|
|
627
|
-
id: z.ZodString;
|
|
628
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
629
|
-
success: z.ZodLiteral<true>;
|
|
630
|
-
}, z.core.$strip>, "mutation">;
|
|
631
605
|
readonly setupTotp: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
|
|
632
606
|
userId: z.ZodString;
|
|
633
607
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -896,4 +870,4 @@ export declare const userManagementCapability: {
|
|
|
896
870
|
};
|
|
897
871
|
};
|
|
898
872
|
export type IUserManagementProvider = InferProvider<typeof userManagementCapability>;
|
|
899
|
-
export {
|
|
873
|
+
export { CreateUserInputSchema, ExternalIdentityKeySchema, ExternalIdentitySchema, OauthSessionSummarySchema, UpdateUserInputSchema, UserSummarySchema, };
|
package/dist/client.js
CHANGED
|
@@ -22265,9 +22265,13 @@ var NcSystemEventKindSchema = zod.z.enum([
|
|
|
22265
22265
|
"node-updating",
|
|
22266
22266
|
"node-inference-unavailable",
|
|
22267
22267
|
"detection-blind",
|
|
22268
|
+
"motion-noisy",
|
|
22269
|
+
"motion-calm",
|
|
22268
22270
|
"recording-stalled",
|
|
22269
22271
|
"recording-healthy",
|
|
22270
22272
|
"recording-degraded",
|
|
22273
|
+
"device-attention-required",
|
|
22274
|
+
"device-attention-resolved",
|
|
22271
22275
|
"storage-location-low",
|
|
22272
22276
|
"storage-location-critical",
|
|
22273
22277
|
"storage-location-ok",
|
|
@@ -28391,8 +28395,6 @@ function createSystemProxy(api) {
|
|
|
28391
28395
|
resetPassword: (input) => dispatch("userManagement", "resetPassword", "mutation", input),
|
|
28392
28396
|
setUserScopes: (input) => dispatch("userManagement", "setUserScopes", "mutation", input),
|
|
28393
28397
|
validateCredentials: (input) => dispatch("userManagement", "validateCredentials", "mutation", input),
|
|
28394
|
-
listApiKeys: (input) => dispatch("userManagement", "listApiKeys", "query", input),
|
|
28395
|
-
revokeApiKey: (input) => dispatch("userManagement", "revokeApiKey", "mutation", input),
|
|
28396
28398
|
setupTotp: (input) => dispatch("userManagement", "setupTotp", "mutation", input),
|
|
28397
28399
|
confirmTotp: (input) => dispatch("userManagement", "confirmTotp", "mutation", input),
|
|
28398
28400
|
disableTotp: (input) => dispatch("userManagement", "disableTotp", "mutation", input),
|
|
@@ -28743,8 +28745,8 @@ var NC_SYSTEM_EVENT_FILTER_KEYS = [
|
|
|
28743
28745
|
*/
|
|
28744
28746
|
function systemEventFilterApplies(kind, filter) {
|
|
28745
28747
|
switch (filter) {
|
|
28746
|
-
case "deviceIds": return kind.startsWith("device-") || kind.startsWith("stream-") || kind === "detection-blind" || kind.startsWith("recording-") || kind === "alarm-triggered";
|
|
28747
|
-
case "deviceTypes": return kind.startsWith("device-") || kind === "detection-blind";
|
|
28748
|
+
case "deviceIds": return kind.startsWith("device-") || kind.startsWith("stream-") || kind === "detection-blind" || kind.startsWith("motion-") || kind.startsWith("recording-") || kind === "alarm-triggered";
|
|
28749
|
+
case "deviceTypes": return kind.startsWith("device-") || kind === "detection-blind" || kind.startsWith("motion-");
|
|
28748
28750
|
case "nodeIds": return kind.startsWith("node-") || kind === "addon-crash-loop" || kind === "addon-update-available" || kind === "addon-updated" || kind === "server-update-available" || kind === "wrapper-update-available" || kind === "server-updated" || kind.startsWith("storage-location-") || kind.startsWith("alert-");
|
|
28749
28751
|
case "packageNames": return kind.endsWith("update-available") || kind === "addon-updated" || kind === "node-updating" || kind === "server-updated";
|
|
28750
28752
|
case "consumableLowPercent": return NC_CONSUMABLE_SYSTEM_EVENT_KINDS.includes(kind);
|
|
@@ -28802,9 +28804,13 @@ var NC_SYSTEM_EVENT_FAMILY = {
|
|
|
28802
28804
|
"stream-online": "device-events",
|
|
28803
28805
|
"stream-offline": "device-events",
|
|
28804
28806
|
"detection-blind": "device-events",
|
|
28807
|
+
"motion-noisy": "device-events",
|
|
28808
|
+
"motion-calm": "device-events",
|
|
28805
28809
|
"recording-stalled": "device-events",
|
|
28806
28810
|
"recording-healthy": "device-events",
|
|
28807
28811
|
"recording-degraded": "device-events",
|
|
28812
|
+
"device-attention-required": "device-events",
|
|
28813
|
+
"device-attention-resolved": "device-events",
|
|
28808
28814
|
"node-online": "system",
|
|
28809
28815
|
"node-offline": "system",
|
|
28810
28816
|
"node-restarting": "system",
|
|
@@ -28905,6 +28911,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
|
|
|
28905
28911
|
label: "Detecting nothing",
|
|
28906
28912
|
kinds: ["detection-blind"]
|
|
28907
28913
|
},
|
|
28914
|
+
{
|
|
28915
|
+
id: "motion-noise",
|
|
28916
|
+
family: "device-events",
|
|
28917
|
+
label: "Motion without a subject",
|
|
28918
|
+
kinds: ["motion-noisy", "motion-calm"]
|
|
28919
|
+
},
|
|
28908
28920
|
{
|
|
28909
28921
|
id: "recording",
|
|
28910
28922
|
family: "device-events",
|
|
@@ -28915,6 +28927,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
|
|
|
28915
28927
|
"recording-degraded"
|
|
28916
28928
|
]
|
|
28917
28929
|
},
|
|
28930
|
+
{
|
|
28931
|
+
id: "device-attention",
|
|
28932
|
+
family: "device-events",
|
|
28933
|
+
label: "Needs attention",
|
|
28934
|
+
kinds: ["device-attention-required", "device-attention-resolved"]
|
|
28935
|
+
},
|
|
28918
28936
|
{
|
|
28919
28937
|
id: "nodes",
|
|
28920
28938
|
family: "system",
|
|
@@ -29870,6 +29888,7 @@ var ALERT_EPISODE = [
|
|
|
29870
29888
|
"alert-error",
|
|
29871
29889
|
"alert-critical-resolved"
|
|
29872
29890
|
];
|
|
29891
|
+
var DEVICE_ATTENTION = ["device-attention-required", "device-attention-resolved"];
|
|
29873
29892
|
var UPDATES = [
|
|
29874
29893
|
"addon-update-available",
|
|
29875
29894
|
"server-update-available",
|
|
@@ -29899,9 +29918,12 @@ var DEVICE_EVENTS = [
|
|
|
29899
29918
|
"stream-online",
|
|
29900
29919
|
"stream-offline",
|
|
29901
29920
|
"detection-blind",
|
|
29921
|
+
"motion-noisy",
|
|
29922
|
+
"motion-calm",
|
|
29902
29923
|
"recording-stalled",
|
|
29903
29924
|
"recording-healthy",
|
|
29904
29925
|
"recording-degraded",
|
|
29926
|
+
...DEVICE_ATTENTION,
|
|
29905
29927
|
...ALARM
|
|
29906
29928
|
];
|
|
29907
29929
|
/** Every kind a summary may speak about — the two summarisable families. */
|
|
@@ -30475,7 +30497,36 @@ var NC_TEMPLATE_VARS = [
|
|
|
30475
30497
|
families: ["rule"],
|
|
30476
30498
|
fields: [...RULE_TEXT],
|
|
30477
30499
|
kinds: ["system"],
|
|
30478
|
-
systemEventKinds: [
|
|
30500
|
+
systemEventKinds: [
|
|
30501
|
+
"detection-blind",
|
|
30502
|
+
"motion-noisy",
|
|
30503
|
+
"motion-calm",
|
|
30504
|
+
"recording-stalled"
|
|
30505
|
+
]
|
|
30506
|
+
},
|
|
30507
|
+
{
|
|
30508
|
+
name: "duty",
|
|
30509
|
+
label: "Motion share (%)",
|
|
30510
|
+
example: "55",
|
|
30511
|
+
group: "system",
|
|
30512
|
+
families: ["rule"],
|
|
30513
|
+
fields: [...RULE_TEXT],
|
|
30514
|
+
kinds: ["system"],
|
|
30515
|
+
systemEventKinds: ["motion-noisy", "motion-calm"]
|
|
30516
|
+
},
|
|
30517
|
+
{
|
|
30518
|
+
name: "sessions",
|
|
30519
|
+
label: "Detection sessions",
|
|
30520
|
+
example: "96",
|
|
30521
|
+
group: "system",
|
|
30522
|
+
families: ["rule"],
|
|
30523
|
+
fields: [...RULE_TEXT],
|
|
30524
|
+
kinds: ["system"],
|
|
30525
|
+
systemEventKinds: [
|
|
30526
|
+
"detection-blind",
|
|
30527
|
+
"motion-noisy",
|
|
30528
|
+
"motion-calm"
|
|
30529
|
+
]
|
|
30479
30530
|
},
|
|
30480
30531
|
{
|
|
30481
30532
|
name: "message",
|
|
@@ -30485,7 +30536,11 @@ var NC_TEMPLATE_VARS = [
|
|
|
30485
30536
|
families: ["rule"],
|
|
30486
30537
|
fields: [...RULE_TEXT],
|
|
30487
30538
|
kinds: ["system"],
|
|
30488
|
-
systemEventKinds: [
|
|
30539
|
+
systemEventKinds: [
|
|
30540
|
+
"recording-degraded",
|
|
30541
|
+
...DEVICE_ATTENTION,
|
|
30542
|
+
...ALERT_EPISODE
|
|
30543
|
+
]
|
|
30489
30544
|
},
|
|
30490
30545
|
{
|
|
30491
30546
|
name: "ruleName",
|
|
@@ -30729,7 +30784,11 @@ var NC_TEMPLATE_VARS = [
|
|
|
30729
30784
|
families: ["rule"],
|
|
30730
30785
|
fields: [...RULE_TEXT],
|
|
30731
30786
|
kinds: ["system"],
|
|
30732
|
-
systemEventKinds: [
|
|
30787
|
+
systemEventKinds: [
|
|
30788
|
+
"export-completed",
|
|
30789
|
+
...DEVICE_ATTENTION,
|
|
30790
|
+
...ALERT_EPISODE
|
|
30791
|
+
]
|
|
30733
30792
|
},
|
|
30734
30793
|
{
|
|
30735
30794
|
name: "severity",
|
|
@@ -30749,7 +30808,7 @@ var NC_TEMPLATE_VARS = [
|
|
|
30749
30808
|
families: ["rule"],
|
|
30750
30809
|
fields: [...RULE_TEXT],
|
|
30751
30810
|
kinds: ["system"],
|
|
30752
|
-
systemEventKinds: [...ALERT_EPISODE]
|
|
30811
|
+
systemEventKinds: [...DEVICE_ATTENTION, ...ALERT_EPISODE]
|
|
30753
30812
|
},
|
|
30754
30813
|
{
|
|
30755
30814
|
name: "source",
|
|
@@ -30769,7 +30828,7 @@ var NC_TEMPLATE_VARS = [
|
|
|
30769
30828
|
families: ["rule"],
|
|
30770
30829
|
fields: [...RULE_TEXT],
|
|
30771
30830
|
kinds: ["system"],
|
|
30772
|
-
systemEventKinds: [...ALERT_EPISODE]
|
|
30831
|
+
systemEventKinds: [...DEVICE_ATTENTION, ...ALERT_EPISODE]
|
|
30773
30832
|
},
|
|
30774
30833
|
{
|
|
30775
30834
|
name: "exportId",
|
|
@@ -30984,6 +31043,8 @@ var NC_TEMPLATE_HELD_BACK_SYSTEM_EVENT_KINDS = [
|
|
|
30984
31043
|
"alert-critical",
|
|
30985
31044
|
"alert-error",
|
|
30986
31045
|
"alert-critical-resolved",
|
|
31046
|
+
"device-attention-required",
|
|
31047
|
+
"device-attention-resolved",
|
|
30987
31048
|
"rule-broken",
|
|
30988
31049
|
"rule-repaired"
|
|
30989
31050
|
];
|
|
@@ -31098,6 +31159,15 @@ var NC_SYSTEM_EVENT_CLASS_SPECS = [
|
|
|
31098
31159
|
snapshotLabel: "Tanks low or full now",
|
|
31099
31160
|
snapshotSection: "tanks"
|
|
31100
31161
|
},
|
|
31162
|
+
{
|
|
31163
|
+
id: "motion-noise",
|
|
31164
|
+
family: "device-events",
|
|
31165
|
+
label: "Motion without a subject (constant / calm again)",
|
|
31166
|
+
bad: ["motion-noisy"],
|
|
31167
|
+
recovery: ["motion-calm"],
|
|
31168
|
+
snapshotLabel: "Cameras with constant motion now",
|
|
31169
|
+
snapshotSection: null
|
|
31170
|
+
},
|
|
31101
31171
|
{
|
|
31102
31172
|
id: "recording-health",
|
|
31103
31173
|
family: "device-events",
|
|
@@ -31107,6 +31177,15 @@ var NC_SYSTEM_EVENT_CLASS_SPECS = [
|
|
|
31107
31177
|
snapshotLabel: "Recordings stalled now",
|
|
31108
31178
|
snapshotSection: null
|
|
31109
31179
|
},
|
|
31180
|
+
{
|
|
31181
|
+
id: "device-attention",
|
|
31182
|
+
family: "device-events",
|
|
31183
|
+
label: "Device needs attention (raised / resolved)",
|
|
31184
|
+
bad: ["device-attention-required"],
|
|
31185
|
+
recovery: ["device-attention-resolved"],
|
|
31186
|
+
snapshotLabel: "Devices needing attention now",
|
|
31187
|
+
snapshotSection: null
|
|
31188
|
+
},
|
|
31110
31189
|
{
|
|
31111
31190
|
id: "node-connectivity",
|
|
31112
31191
|
family: "system",
|