@camstack/addon-provider-rtsp 1.2.128 → 1.2.130
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 +493 -240
- package/dist/addon.mjs +493 -240
- package/package.json +1 -1
package/dist/addon.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import net from "node:net";
|
|
2
|
-
//#region ../types/dist/event-category-
|
|
2
|
+
//#region ../types/dist/event-category-DOl51-Ij.mjs
|
|
3
3
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
4
4
|
EventCategory["SystemBoot"] = "system.boot";
|
|
5
5
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -78,9 +78,18 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
78
78
|
/**
|
|
79
79
|
* The node's one-shot runner boot check (D877): planned runners against the
|
|
80
80
|
* process service, `degraded` when any is failed, refused or missing. The
|
|
81
|
-
* alert centre turns it into one
|
|
81
|
+
* alert centre turns it into one critical alert.
|
|
82
82
|
*/
|
|
83
83
|
EventCategory["SystemRunnerCheck"] = "system.runner-check";
|
|
84
|
+
/**
|
|
85
|
+
* An alert EPISODE opened or closed, emitted by the alert centre for alerts
|
|
86
|
+
* of severity `critical` or `error` (`AlertEpisodePayload`). The alert
|
|
87
|
+
* centre sends no notification of its own: Notification Center turns this
|
|
88
|
+
* into the `alert-critical` / `alert-error` / `alert-critical-resolved`
|
|
89
|
+
* system-event kinds, and reconciles from the alerts store because a bus
|
|
90
|
+
* event may be dropped (D8, D11).
|
|
91
|
+
*/
|
|
92
|
+
EventCategory["AlertEpisode"] = "alert.episode";
|
|
84
93
|
EventCategory["AddonError"] = "addon.error";
|
|
85
94
|
EventCategory["AddonPageReady"] = "addon.page-ready";
|
|
86
95
|
EventCategory["AddonWidgetReady"] = "addon.widget-ready";
|
|
@@ -5405,7 +5414,7 @@ var ZodIssueCode = {
|
|
|
5405
5414
|
var ZodFirstPartyTypeKind;
|
|
5406
5415
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5407
5416
|
//#endregion
|
|
5408
|
-
//#region ../types/dist/sleep-
|
|
5417
|
+
//#region ../types/dist/sleep-BxjU_fJM.mjs
|
|
5409
5418
|
/**
|
|
5410
5419
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5411
5420
|
* window to float samples (D455).
|
|
@@ -7787,6 +7796,12 @@ function normalizeAddonInitResult(result) {
|
|
|
7787
7796
|
if (Array.isArray(result)) return { providers: result };
|
|
7788
7797
|
return result;
|
|
7789
7798
|
}
|
|
7799
|
+
/**
|
|
7800
|
+
* The share-view scope kinds a `csv_*` share token can carry. The hub mints
|
|
7801
|
+
* and validates them (`share-token.service.ts` builds its enum from this
|
|
7802
|
+
* list); a data plane names the kinds it ACCEPTS in `share`.
|
|
7803
|
+
*/
|
|
7804
|
+
var SHARE_VIEW_KINDS = ["grid-view", "events-view"];
|
|
7790
7805
|
/** The wire shape of {@link PeerBytesTicket} — see the type for what it is. */
|
|
7791
7806
|
var PeerBytesTicketSchema = object({
|
|
7792
7807
|
/** `http://127.0.0.1:<port>/<token>`. One `GET` takes it. */
|
|
@@ -12573,6 +12588,229 @@ var ConvertResultSchema = object({
|
|
|
12573
12588
|
files: array(string()).readonly()
|
|
12574
12589
|
})).readonly()
|
|
12575
12590
|
});
|
|
12591
|
+
/**
|
|
12592
|
+
* Zod schemas for persisted record types.
|
|
12593
|
+
*
|
|
12594
|
+
* These schemas serve as the single source of truth for types that are
|
|
12595
|
+
* stored in the settings-store backend and retrieved via tRPC. They
|
|
12596
|
+
* replace the manual TypeScript interfaces with schema-derived types,
|
|
12597
|
+
* enabling runtime validation when reading from the backend.
|
|
12598
|
+
*
|
|
12599
|
+
* Convention: each schema is named `<Type>Schema`, the inferred TS type
|
|
12600
|
+
* keeps the original name for backward compatibility.
|
|
12601
|
+
*/
|
|
12602
|
+
/**
|
|
12603
|
+
* Auth model (v2 — 2026-05-12 caps-only):
|
|
12604
|
+
*
|
|
12605
|
+
* Two principals:
|
|
12606
|
+
* - `isAdmin: true` — full bypass. Admin scope set is ignored.
|
|
12607
|
+
* - `isAdmin: false` — every call gated by `scopes` (see TokenScope).
|
|
12608
|
+
*
|
|
12609
|
+
* No role enum. There used to be `viewer / agent / scoped` and earlier
|
|
12610
|
+
* `super_admin` — collapsed onto the single boolean because every
|
|
12611
|
+
* non-admin caller is governed by the same scope-check rules; the
|
|
12612
|
+
* distinction was only ever used to route role-specific procedures
|
|
12613
|
+
* which we no longer have. CLI / webhook integrations are `cst_*` tokens
|
|
12614
|
+
* with `isAdmin: false` + an explicit scope list.
|
|
12615
|
+
*/
|
|
12616
|
+
/** Per-method access flavour. Materialised on every cap method via codegen. */
|
|
12617
|
+
var MethodAccessSchema = _enum([
|
|
12618
|
+
"view",
|
|
12619
|
+
"create",
|
|
12620
|
+
"delete"
|
|
12621
|
+
]);
|
|
12622
|
+
/**
|
|
12623
|
+
* A single scope grant. Three forms — checked in matcher with OR
|
|
12624
|
+
* semantics; the first match decides whether the call passes:
|
|
12625
|
+
*
|
|
12626
|
+
* - `category` — broadest. `target: 'device' | 'system'` selects every
|
|
12627
|
+
* cap with the matching `scope` declaration. New caps inherit grants
|
|
12628
|
+
* automatically — adding a device cap to the codebase makes it
|
|
12629
|
+
* reachable to every user with `category:device [...]` without a
|
|
12630
|
+
* re-grant. Use this for "family viewer" / "operator" tiers.
|
|
12631
|
+
*
|
|
12632
|
+
* - `addon` — every cap that ships inside a given addon id. Niche;
|
|
12633
|
+
* useful when an integration needs to interact with one specific
|
|
12634
|
+
* addon's surface regardless of how many caps it exports.
|
|
12635
|
+
*
|
|
12636
|
+
* - `capability` — the most precise form. Single cap name. Use for
|
|
12637
|
+
* integration tokens where you want to grant `addons.installPackage`
|
|
12638
|
+
* and nothing else.
|
|
12639
|
+
*
|
|
12640
|
+
* `access` is REQUIRED with min 1 element. `admin` bypass is the
|
|
12641
|
+
* "give me everything" escape; there is no wildcard scope.
|
|
12642
|
+
*/
|
|
12643
|
+
var AllowedProviderSchema = union([literal("*"), array(string())]);
|
|
12644
|
+
var AllowedDevicesSchema = record(string(), union([literal("*"), array(string())]));
|
|
12645
|
+
var CapScopeSchema = _enum(["device", "system"]);
|
|
12646
|
+
/**
|
|
12647
|
+
* DeviceSelector (scope model v3 — 2026-08-12).
|
|
12648
|
+
*
|
|
12649
|
+
* A `device` grant no longer carries a frozen list of deviceIds. It carries
|
|
12650
|
+
* a SELECTOR the matcher resolves against the live fleet, so the grant can be
|
|
12651
|
+
* DYNAMIC: a `types:['camera']` selector automatically covers a camera added
|
|
12652
|
+
* AFTER the grant was minted — no re-grant, no re-login.
|
|
12653
|
+
*
|
|
12654
|
+
* - `all` — every device in the deployment. The broad viewer/operator
|
|
12655
|
+
* lever without a `category` grant (a `category` grant also covers device
|
|
12656
|
+
* caps that carry no deviceId; `all` is specifically the device set).
|
|
12657
|
+
* - `ids` — an explicit deviceId list. This is what a v2 `device:[…]`
|
|
12658
|
+
* grant migrates to (see {@link TokenScopeSchema}); STATIC — a new camera
|
|
12659
|
+
* is NOT covered until the grant is edited.
|
|
12660
|
+
* - `types` — every device of a `DeviceType` (e.g. every `camera`).
|
|
12661
|
+
* DYNAMIC. A device that changes type, or a new device of the type,
|
|
12662
|
+
* re-resolves on the next request.
|
|
12663
|
+
* - `locations` — every device whose operator-assigned `location` label is
|
|
12664
|
+
* in the set (e.g. "Garden", "Front door"). DYNAMIC. A device with a
|
|
12665
|
+
* null/unset location matches NO `locations` selector.
|
|
12666
|
+
*/
|
|
12667
|
+
var DeviceSelectorSchema = discriminatedUnion("kind", [
|
|
12668
|
+
object({ kind: literal("all") }),
|
|
12669
|
+
object({
|
|
12670
|
+
kind: literal("ids"),
|
|
12671
|
+
ids: array(number().int()).min(1)
|
|
12672
|
+
}),
|
|
12673
|
+
object({
|
|
12674
|
+
kind: literal("types"),
|
|
12675
|
+
types: array(_enum(DeviceType)).min(1)
|
|
12676
|
+
}),
|
|
12677
|
+
object({
|
|
12678
|
+
kind: literal("locations"),
|
|
12679
|
+
locations: array(string().min(1)).min(1)
|
|
12680
|
+
})
|
|
12681
|
+
]);
|
|
12682
|
+
var DeviceTokenScopeSchema = object({
|
|
12683
|
+
type: literal("device"),
|
|
12684
|
+
/** The device SET this grant covers — resolved against the live fleet. */
|
|
12685
|
+
selector: DeviceSelectorSchema,
|
|
12686
|
+
access: array(MethodAccessSchema).min(1),
|
|
12687
|
+
/**
|
|
12688
|
+
* Whether a grant on a PARENT device transparently covers its accessory
|
|
12689
|
+
* CHILDREN (siren / floodlight / PIR) via the persisted-parentage walk.
|
|
12690
|
+
* Direction is parent → children ONLY.
|
|
12691
|
+
*
|
|
12692
|
+
* Absent → the matcher DERIVES it from the access flavour: `view`
|
|
12693
|
+
* inherits (a camera viewer sees the camera's accessories), `create` /
|
|
12694
|
+
* `delete` do NOT (actuating/removing a child is an explicit act the
|
|
12695
|
+
* operator must grant on the child, not inherit from the parent). Set it
|
|
12696
|
+
* explicitly to override that default per grant.
|
|
12697
|
+
*/
|
|
12698
|
+
includeLinked: boolean().optional()
|
|
12699
|
+
});
|
|
12700
|
+
/**
|
|
12701
|
+
* v2 → v3 lazy migration. A pre-v3 `device` grant carried
|
|
12702
|
+
* `targets: string[]` (stringified deviceIds); it rewrites to the equivalent
|
|
12703
|
+
* `selector: {kind:'ids', ids}`. Applied as a `preprocess` so it runs on
|
|
12704
|
+
* EVERY parse path — stored records AND the JWT-carried scope arrays
|
|
12705
|
+
* normalised at the request boundary ({@link normalizeTokenScopes} in
|
|
12706
|
+
* `device-selector.ts`). Chosen over a one-time DB migration because a
|
|
12707
|
+
* migration cannot reach a JWT already in a client's hands; parse-time
|
|
12708
|
+
* migration covers both without a flag day. No cast — the raw object is read
|
|
12709
|
+
* through `Reflect.get` (its static type is `unknown`).
|
|
12710
|
+
*/
|
|
12711
|
+
function migrateLegacyTokenScope(raw) {
|
|
12712
|
+
if (raw === null || typeof raw !== "object" || Array.isArray(raw)) return raw;
|
|
12713
|
+
if (Reflect.get(raw, "type") !== "device") return raw;
|
|
12714
|
+
if (Reflect.get(raw, "selector") !== void 0) return raw;
|
|
12715
|
+
const targets = Reflect.get(raw, "targets");
|
|
12716
|
+
if (!Array.isArray(targets)) return raw;
|
|
12717
|
+
return {
|
|
12718
|
+
type: "device",
|
|
12719
|
+
selector: {
|
|
12720
|
+
kind: "ids",
|
|
12721
|
+
ids: targets.map((t) => typeof t === "string" ? Number(t) : t).filter((n) => typeof n === "number" && Number.isInteger(n))
|
|
12722
|
+
},
|
|
12723
|
+
access: Reflect.get(raw, "access")
|
|
12724
|
+
};
|
|
12725
|
+
}
|
|
12726
|
+
var TokenScopeSchema = preprocess(migrateLegacyTokenScope, discriminatedUnion("type", [
|
|
12727
|
+
object({
|
|
12728
|
+
type: literal("category"),
|
|
12729
|
+
target: CapScopeSchema,
|
|
12730
|
+
access: array(MethodAccessSchema).min(1)
|
|
12731
|
+
}),
|
|
12732
|
+
object({
|
|
12733
|
+
type: literal("capability"),
|
|
12734
|
+
target: string(),
|
|
12735
|
+
access: array(MethodAccessSchema).min(1)
|
|
12736
|
+
}),
|
|
12737
|
+
object({
|
|
12738
|
+
type: literal("addon"),
|
|
12739
|
+
target: string(),
|
|
12740
|
+
access: array(MethodAccessSchema).min(1)
|
|
12741
|
+
}),
|
|
12742
|
+
DeviceTokenScopeSchema
|
|
12743
|
+
]));
|
|
12744
|
+
object({
|
|
12745
|
+
id: string(),
|
|
12746
|
+
username: string(),
|
|
12747
|
+
passwordHash: string(),
|
|
12748
|
+
/**
|
|
12749
|
+
* Admin bypass. When true, the middleware skips the scope-access
|
|
12750
|
+
* check entirely. There is no other axis of privilege; the legacy
|
|
12751
|
+
* role enum collapsed onto this boolean in v2.
|
|
12752
|
+
*/
|
|
12753
|
+
isAdmin: boolean().default(false),
|
|
12754
|
+
allowedProviders: AllowedProviderSchema,
|
|
12755
|
+
allowedDevices: AllowedDevicesSchema,
|
|
12756
|
+
/**
|
|
12757
|
+
* Scopes granted to this user. Admins bypass; their `scopes` is
|
|
12758
|
+
* ignored. Non-admins without scopes are locked out of every
|
|
12759
|
+
* protected call.
|
|
12760
|
+
*/
|
|
12761
|
+
scopes: array(TokenScopeSchema).default([]),
|
|
12762
|
+
createdAt: number(),
|
|
12763
|
+
updatedAt: number()
|
|
12764
|
+
});
|
|
12765
|
+
object({
|
|
12766
|
+
id: string(),
|
|
12767
|
+
label: string(),
|
|
12768
|
+
isAdmin: boolean().default(false),
|
|
12769
|
+
allowedProviders: AllowedProviderSchema,
|
|
12770
|
+
allowedDevices: AllowedDevicesSchema,
|
|
12771
|
+
tokenHash: string(),
|
|
12772
|
+
tokenPrefix: string(),
|
|
12773
|
+
createdAt: number(),
|
|
12774
|
+
lastUsedAt: number().optional()
|
|
12775
|
+
});
|
|
12776
|
+
object({
|
|
12777
|
+
id: string(),
|
|
12778
|
+
userId: string(),
|
|
12779
|
+
name: string(),
|
|
12780
|
+
tokenHash: string(),
|
|
12781
|
+
tokenPrefix: string(),
|
|
12782
|
+
scopes: array(TokenScopeSchema),
|
|
12783
|
+
expiresAt: number().nullish(),
|
|
12784
|
+
lastUsedAt: number().nullish(),
|
|
12785
|
+
createdAt: number()
|
|
12786
|
+
});
|
|
12787
|
+
/** What a share-view grant lets its holder see. */
|
|
12788
|
+
var ShareViewGrantSchema = object({
|
|
12789
|
+
kind: _enum(SHARE_VIEW_KINDS),
|
|
12790
|
+
deviceIds: array(number().int().nonnegative()).min(1).max(64),
|
|
12791
|
+
/** Talk-back, opt-in at mint time; absent means off. */
|
|
12792
|
+
talk: boolean().optional()
|
|
12793
|
+
});
|
|
12794
|
+
var ShareViewScopeSchema = object({
|
|
12795
|
+
type: literal("share-view"),
|
|
12796
|
+
grant: ShareViewGrantSchema
|
|
12797
|
+
});
|
|
12798
|
+
var AddonRoutesScopeSchema = object({
|
|
12799
|
+
type: literal("addon-routes"),
|
|
12800
|
+
access: array(MethodAccessSchema).min(1)
|
|
12801
|
+
});
|
|
12802
|
+
var CredentialScopeSchema = union([
|
|
12803
|
+
literal("*"),
|
|
12804
|
+
ShareViewScopeSchema,
|
|
12805
|
+
AddonRoutesScopeSchema,
|
|
12806
|
+
TokenScopeSchema
|
|
12807
|
+
]);
|
|
12808
|
+
object({
|
|
12809
|
+
kind: literal("credential"),
|
|
12810
|
+
sub: string().min(1),
|
|
12811
|
+
jti: string().min(16),
|
|
12812
|
+
scopes: array(CredentialScopeSchema).min(1)
|
|
12813
|
+
});
|
|
12576
12814
|
_enum(["new-session", "step-up"]);
|
|
12577
12815
|
/** The languages the hub's app landing pages are written in (D858). */
|
|
12578
12816
|
var AppPageLangSchema = _enum(["en", "it"]);
|
|
@@ -13289,7 +13527,14 @@ var AlertSeveritySchema = _enum([
|
|
|
13289
13527
|
]);
|
|
13290
13528
|
var AlertActionSchema = object({
|
|
13291
13529
|
label: string(),
|
|
13292
|
-
href: string().optional()
|
|
13530
|
+
href: string().optional(),
|
|
13531
|
+
/**
|
|
13532
|
+
* How `href` is followed. Absent / `app`: an admin-ui route (client-side).
|
|
13533
|
+
* `server`: a route the HUB serves (an addon HTTP route such as an OAuth
|
|
13534
|
+
* start) — the browser must leave the SPA with a full navigation, because
|
|
13535
|
+
* the SPA has no such route and would bounce to the home page.
|
|
13536
|
+
*/
|
|
13537
|
+
navigation: _enum(["app", "server"]).optional()
|
|
13293
13538
|
});
|
|
13294
13539
|
var AlertStatusSchema = _enum([
|
|
13295
13540
|
"active",
|
|
@@ -42005,6 +42250,9 @@ var NcSystemEventKindSchema = _enum([
|
|
|
42005
42250
|
"server-updated",
|
|
42006
42251
|
"export-completed",
|
|
42007
42252
|
"backup-completed",
|
|
42253
|
+
"alert-critical",
|
|
42254
|
+
"alert-error",
|
|
42255
|
+
"alert-critical-resolved",
|
|
42008
42256
|
"camera-online",
|
|
42009
42257
|
"camera-offline",
|
|
42010
42258
|
"camera-disabled",
|
|
@@ -44040,202 +44288,6 @@ method(object({}), object({ rules: array(NcRuleSchema) }), { auth: "admin" }), m
|
|
|
44040
44288
|
auth: "admin"
|
|
44041
44289
|
}), method(NcAlarmSensorsInputSchema, NcAlarmSensorsSchema, { auth: "admin" });
|
|
44042
44290
|
/**
|
|
44043
|
-
* Zod schemas for persisted record types.
|
|
44044
|
-
*
|
|
44045
|
-
* These schemas serve as the single source of truth for types that are
|
|
44046
|
-
* stored in the settings-store backend and retrieved via tRPC. They
|
|
44047
|
-
* replace the manual TypeScript interfaces with schema-derived types,
|
|
44048
|
-
* enabling runtime validation when reading from the backend.
|
|
44049
|
-
*
|
|
44050
|
-
* Convention: each schema is named `<Type>Schema`, the inferred TS type
|
|
44051
|
-
* keeps the original name for backward compatibility.
|
|
44052
|
-
*/
|
|
44053
|
-
/**
|
|
44054
|
-
* Auth model (v2 — 2026-05-12 caps-only):
|
|
44055
|
-
*
|
|
44056
|
-
* Two principals:
|
|
44057
|
-
* - `isAdmin: true` — full bypass. Admin scope set is ignored.
|
|
44058
|
-
* - `isAdmin: false` — every call gated by `scopes` (see TokenScope).
|
|
44059
|
-
*
|
|
44060
|
-
* No role enum. There used to be `viewer / agent / scoped` and earlier
|
|
44061
|
-
* `super_admin` — collapsed onto the single boolean because every
|
|
44062
|
-
* non-admin caller is governed by the same scope-check rules; the
|
|
44063
|
-
* distinction was only ever used to route role-specific procedures
|
|
44064
|
-
* which we no longer have. CLI / webhook integrations are `cst_*` tokens
|
|
44065
|
-
* with `isAdmin: false` + an explicit scope list.
|
|
44066
|
-
*/
|
|
44067
|
-
/** Per-method access flavour. Materialised on every cap method via codegen. */
|
|
44068
|
-
var MethodAccessSchema = _enum([
|
|
44069
|
-
"view",
|
|
44070
|
-
"create",
|
|
44071
|
-
"delete"
|
|
44072
|
-
]);
|
|
44073
|
-
/**
|
|
44074
|
-
* A single scope grant. Three forms — checked in matcher with OR
|
|
44075
|
-
* semantics; the first match decides whether the call passes:
|
|
44076
|
-
*
|
|
44077
|
-
* - `category` — broadest. `target: 'device' | 'system'` selects every
|
|
44078
|
-
* cap with the matching `scope` declaration. New caps inherit grants
|
|
44079
|
-
* automatically — adding a device cap to the codebase makes it
|
|
44080
|
-
* reachable to every user with `category:device [...]` without a
|
|
44081
|
-
* re-grant. Use this for "family viewer" / "operator" tiers.
|
|
44082
|
-
*
|
|
44083
|
-
* - `addon` — every cap that ships inside a given addon id. Niche;
|
|
44084
|
-
* useful when an integration needs to interact with one specific
|
|
44085
|
-
* addon's surface regardless of how many caps it exports.
|
|
44086
|
-
*
|
|
44087
|
-
* - `capability` — the most precise form. Single cap name. Use for
|
|
44088
|
-
* integration tokens where you want to grant `addons.installPackage`
|
|
44089
|
-
* and nothing else.
|
|
44090
|
-
*
|
|
44091
|
-
* `access` is REQUIRED with min 1 element. `admin` bypass is the
|
|
44092
|
-
* "give me everything" escape; there is no wildcard scope.
|
|
44093
|
-
*/
|
|
44094
|
-
var AllowedProviderSchema = union([literal("*"), array(string())]);
|
|
44095
|
-
var AllowedDevicesSchema = record(string(), union([literal("*"), array(string())]));
|
|
44096
|
-
var CapScopeSchema = _enum(["device", "system"]);
|
|
44097
|
-
/**
|
|
44098
|
-
* DeviceSelector (scope model v3 — 2026-08-12).
|
|
44099
|
-
*
|
|
44100
|
-
* A `device` grant no longer carries a frozen list of deviceIds. It carries
|
|
44101
|
-
* a SELECTOR the matcher resolves against the live fleet, so the grant can be
|
|
44102
|
-
* DYNAMIC: a `types:['camera']` selector automatically covers a camera added
|
|
44103
|
-
* AFTER the grant was minted — no re-grant, no re-login.
|
|
44104
|
-
*
|
|
44105
|
-
* - `all` — every device in the deployment. The broad viewer/operator
|
|
44106
|
-
* lever without a `category` grant (a `category` grant also covers device
|
|
44107
|
-
* caps that carry no deviceId; `all` is specifically the device set).
|
|
44108
|
-
* - `ids` — an explicit deviceId list. This is what a v2 `device:[…]`
|
|
44109
|
-
* grant migrates to (see {@link TokenScopeSchema}); STATIC — a new camera
|
|
44110
|
-
* is NOT covered until the grant is edited.
|
|
44111
|
-
* - `types` — every device of a `DeviceType` (e.g. every `camera`).
|
|
44112
|
-
* DYNAMIC. A device that changes type, or a new device of the type,
|
|
44113
|
-
* re-resolves on the next request.
|
|
44114
|
-
* - `locations` — every device whose operator-assigned `location` label is
|
|
44115
|
-
* in the set (e.g. "Garden", "Front door"). DYNAMIC. A device with a
|
|
44116
|
-
* null/unset location matches NO `locations` selector.
|
|
44117
|
-
*/
|
|
44118
|
-
var DeviceSelectorSchema = discriminatedUnion("kind", [
|
|
44119
|
-
object({ kind: literal("all") }),
|
|
44120
|
-
object({
|
|
44121
|
-
kind: literal("ids"),
|
|
44122
|
-
ids: array(number().int()).min(1)
|
|
44123
|
-
}),
|
|
44124
|
-
object({
|
|
44125
|
-
kind: literal("types"),
|
|
44126
|
-
types: array(_enum(DeviceType)).min(1)
|
|
44127
|
-
}),
|
|
44128
|
-
object({
|
|
44129
|
-
kind: literal("locations"),
|
|
44130
|
-
locations: array(string().min(1)).min(1)
|
|
44131
|
-
})
|
|
44132
|
-
]);
|
|
44133
|
-
var DeviceTokenScopeSchema = object({
|
|
44134
|
-
type: literal("device"),
|
|
44135
|
-
/** The device SET this grant covers — resolved against the live fleet. */
|
|
44136
|
-
selector: DeviceSelectorSchema,
|
|
44137
|
-
access: array(MethodAccessSchema).min(1),
|
|
44138
|
-
/**
|
|
44139
|
-
* Whether a grant on a PARENT device transparently covers its accessory
|
|
44140
|
-
* CHILDREN (siren / floodlight / PIR) via the persisted-parentage walk.
|
|
44141
|
-
* Direction is parent → children ONLY.
|
|
44142
|
-
*
|
|
44143
|
-
* Absent → the matcher DERIVES it from the access flavour: `view`
|
|
44144
|
-
* inherits (a camera viewer sees the camera's accessories), `create` /
|
|
44145
|
-
* `delete` do NOT (actuating/removing a child is an explicit act the
|
|
44146
|
-
* operator must grant on the child, not inherit from the parent). Set it
|
|
44147
|
-
* explicitly to override that default per grant.
|
|
44148
|
-
*/
|
|
44149
|
-
includeLinked: boolean().optional()
|
|
44150
|
-
});
|
|
44151
|
-
/**
|
|
44152
|
-
* v2 → v3 lazy migration. A pre-v3 `device` grant carried
|
|
44153
|
-
* `targets: string[]` (stringified deviceIds); it rewrites to the equivalent
|
|
44154
|
-
* `selector: {kind:'ids', ids}`. Applied as a `preprocess` so it runs on
|
|
44155
|
-
* EVERY parse path — stored records AND the JWT-carried scope arrays
|
|
44156
|
-
* normalised at the request boundary ({@link normalizeTokenScopes} in
|
|
44157
|
-
* `device-selector.ts`). Chosen over a one-time DB migration because a
|
|
44158
|
-
* migration cannot reach a JWT already in a client's hands; parse-time
|
|
44159
|
-
* migration covers both without a flag day. No cast — the raw object is read
|
|
44160
|
-
* through `Reflect.get` (its static type is `unknown`).
|
|
44161
|
-
*/
|
|
44162
|
-
function migrateLegacyTokenScope(raw) {
|
|
44163
|
-
if (raw === null || typeof raw !== "object" || Array.isArray(raw)) return raw;
|
|
44164
|
-
if (Reflect.get(raw, "type") !== "device") return raw;
|
|
44165
|
-
if (Reflect.get(raw, "selector") !== void 0) return raw;
|
|
44166
|
-
const targets = Reflect.get(raw, "targets");
|
|
44167
|
-
if (!Array.isArray(targets)) return raw;
|
|
44168
|
-
return {
|
|
44169
|
-
type: "device",
|
|
44170
|
-
selector: {
|
|
44171
|
-
kind: "ids",
|
|
44172
|
-
ids: targets.map((t) => typeof t === "string" ? Number(t) : t).filter((n) => typeof n === "number" && Number.isInteger(n))
|
|
44173
|
-
},
|
|
44174
|
-
access: Reflect.get(raw, "access")
|
|
44175
|
-
};
|
|
44176
|
-
}
|
|
44177
|
-
var TokenScopeSchema = preprocess(migrateLegacyTokenScope, discriminatedUnion("type", [
|
|
44178
|
-
object({
|
|
44179
|
-
type: literal("category"),
|
|
44180
|
-
target: CapScopeSchema,
|
|
44181
|
-
access: array(MethodAccessSchema).min(1)
|
|
44182
|
-
}),
|
|
44183
|
-
object({
|
|
44184
|
-
type: literal("capability"),
|
|
44185
|
-
target: string(),
|
|
44186
|
-
access: array(MethodAccessSchema).min(1)
|
|
44187
|
-
}),
|
|
44188
|
-
object({
|
|
44189
|
-
type: literal("addon"),
|
|
44190
|
-
target: string(),
|
|
44191
|
-
access: array(MethodAccessSchema).min(1)
|
|
44192
|
-
}),
|
|
44193
|
-
DeviceTokenScopeSchema
|
|
44194
|
-
]));
|
|
44195
|
-
object({
|
|
44196
|
-
id: string(),
|
|
44197
|
-
username: string(),
|
|
44198
|
-
passwordHash: string(),
|
|
44199
|
-
/**
|
|
44200
|
-
* Admin bypass. When true, the middleware skips the scope-access
|
|
44201
|
-
* check entirely. There is no other axis of privilege; the legacy
|
|
44202
|
-
* role enum collapsed onto this boolean in v2.
|
|
44203
|
-
*/
|
|
44204
|
-
isAdmin: boolean().default(false),
|
|
44205
|
-
allowedProviders: AllowedProviderSchema,
|
|
44206
|
-
allowedDevices: AllowedDevicesSchema,
|
|
44207
|
-
/**
|
|
44208
|
-
* Scopes granted to this user. Admins bypass; their `scopes` is
|
|
44209
|
-
* ignored. Non-admins without scopes are locked out of every
|
|
44210
|
-
* protected call.
|
|
44211
|
-
*/
|
|
44212
|
-
scopes: array(TokenScopeSchema).default([]),
|
|
44213
|
-
createdAt: number(),
|
|
44214
|
-
updatedAt: number()
|
|
44215
|
-
});
|
|
44216
|
-
object({
|
|
44217
|
-
id: string(),
|
|
44218
|
-
label: string(),
|
|
44219
|
-
isAdmin: boolean().default(false),
|
|
44220
|
-
allowedProviders: AllowedProviderSchema,
|
|
44221
|
-
allowedDevices: AllowedDevicesSchema,
|
|
44222
|
-
tokenHash: string(),
|
|
44223
|
-
tokenPrefix: string(),
|
|
44224
|
-
createdAt: number(),
|
|
44225
|
-
lastUsedAt: number().optional()
|
|
44226
|
-
});
|
|
44227
|
-
object({
|
|
44228
|
-
id: string(),
|
|
44229
|
-
userId: string(),
|
|
44230
|
-
name: string(),
|
|
44231
|
-
tokenHash: string(),
|
|
44232
|
-
tokenPrefix: string(),
|
|
44233
|
-
scopes: array(TokenScopeSchema),
|
|
44234
|
-
expiresAt: number().nullish(),
|
|
44235
|
-
lastUsedAt: number().nullish(),
|
|
44236
|
-
createdAt: number()
|
|
44237
|
-
});
|
|
44238
|
-
/**
|
|
44239
44291
|
* `oauth-integration` — a collection cap by which an addon declares
|
|
44240
44292
|
* itself a linkable OAuth client of the hub's core `/oauth2/*` server.
|
|
44241
44293
|
* Each provider returns a static descriptor; the core enumerates them
|
|
@@ -51185,7 +51237,10 @@ method(StorageMigrationInputSchema, StorageMigrationPlanSchema, { auth: "admin"
|
|
|
51185
51237
|
}), method(object({ jobId: string().optional() }), StorageMigrationJobSchema.nullable(), { auth: "admin" }), method(object({ jobId: string() }), object({ cancelled: boolean() }), {
|
|
51186
51238
|
kind: "mutation",
|
|
51187
51239
|
auth: "admin"
|
|
51188
|
-
}), method(object({}), array(StorageMigrationMoverSchema).readonly(), { auth: "admin" }), method(object({
|
|
51240
|
+
}), method(object({}), array(StorageMigrationMoverSchema).readonly(), { auth: "admin" }), method(object({ locationIds: array(string()).readonly() }), object({
|
|
51241
|
+
clear: boolean(),
|
|
51242
|
+
repointLocationId: string().optional()
|
|
51243
|
+
}), { auth: "admin" }), method(object({}), array(StorageMigrationResidueSchema).readonly(), { auth: "admin" }), method(StorageMigrationDrainInputSchema, object({ jobId: string() }), {
|
|
51189
51244
|
kind: "mutation",
|
|
51190
51245
|
auth: "admin"
|
|
51191
51246
|
}), method(StorageCleanupInputSchema, object({ jobId: string() }), {
|
|
@@ -55449,6 +55504,11 @@ onStatusChanged: { data: object({
|
|
|
55449
55504
|
*
|
|
55450
55505
|
* `kind: 'poll'` — cloud REST APIs typically have no push channel; the
|
|
55451
55506
|
* provider refreshes the slice on an interval and eagerly after commands.
|
|
55507
|
+
*
|
|
55508
|
+
* UNKNOWN IS NOT OFF. Every field the appliance reports separately is
|
|
55509
|
+
* nullable: `null` means "not known right now" (the appliance has not said,
|
|
55510
|
+
* the link is down, or the description does not carry it) and is never
|
|
55511
|
+
* rendered or exported as `false` / `0`. `availability` says why.
|
|
55452
55512
|
*/
|
|
55453
55513
|
var DishwasherStateSchema = _enum([
|
|
55454
55514
|
"idle",
|
|
@@ -55458,43 +55518,155 @@ var DishwasherStateSchema = _enum([
|
|
|
55458
55518
|
"error",
|
|
55459
55519
|
"unavailable"
|
|
55460
55520
|
]);
|
|
55521
|
+
/**
|
|
55522
|
+
* The appliance's own operation state, uncollapsed. `state` above is the coarse
|
|
55523
|
+
* view for compact surfaces; this is what the appliance said.
|
|
55524
|
+
*/
|
|
55525
|
+
var DishwasherOperationStateSchema = _enum([
|
|
55526
|
+
"Inactive",
|
|
55527
|
+
"Ready",
|
|
55528
|
+
"DelayedStart",
|
|
55529
|
+
"Run",
|
|
55530
|
+
"Pause",
|
|
55531
|
+
"ActionRequired",
|
|
55532
|
+
"Finished",
|
|
55533
|
+
"Error",
|
|
55534
|
+
"Aborting"
|
|
55535
|
+
]);
|
|
55536
|
+
/**
|
|
55537
|
+
* Why fields may be `null`:
|
|
55538
|
+
* - `available` — the link is up and the description is loaded;
|
|
55539
|
+
* - `offline` — the local link is down (values are unknown, not last-known);
|
|
55540
|
+
* - `description-missing` — the link is up but the appliance's description could not
|
|
55541
|
+
* be loaded, so its values cannot be decoded.
|
|
55542
|
+
*/
|
|
55543
|
+
var DishwasherAvailabilitySchema = _enum([
|
|
55544
|
+
"available",
|
|
55545
|
+
"offline",
|
|
55546
|
+
"description-missing"
|
|
55547
|
+
]);
|
|
55461
55548
|
var DishwasherConsumableLevelSchema = _enum([
|
|
55462
55549
|
"ok",
|
|
55463
55550
|
"low",
|
|
55464
55551
|
"empty"
|
|
55465
55552
|
]);
|
|
55466
55553
|
var DishwasherStatusSchema = object({
|
|
55554
|
+
availability: DishwasherAvailabilitySchema,
|
|
55555
|
+
/** Coarse state for compact surfaces; `unavailable` whenever the appliance state is not known. */
|
|
55467
55556
|
state: DishwasherStateSchema,
|
|
55468
|
-
/**
|
|
55557
|
+
/** The appliance's operation state as reported; null when not known. */
|
|
55558
|
+
operationState: DishwasherOperationStateSchema.nullable(),
|
|
55559
|
+
/** Feature key of the ACTIVE (running) program, or null when none runs / not known. */
|
|
55469
55560
|
program: string().nullable(),
|
|
55470
|
-
/**
|
|
55561
|
+
/** Feature key of the SELECTED program (what Start would run), or null when none / not known. */
|
|
55562
|
+
selectedProgram: string().nullable(),
|
|
55563
|
+
/** Feature keys of the programs the appliance currently offers — drives the UI selector. */
|
|
55471
55564
|
availablePrograms: array(string()),
|
|
55472
|
-
/**
|
|
55473
|
-
|
|
55565
|
+
/** Seconds remaining on the active cycle, or null when not running / not known. */
|
|
55566
|
+
remainingSeconds: number().int().nonnegative().nullable(),
|
|
55567
|
+
/** Seconds the delayed start is set to (time until the cycle starts), or null. */
|
|
55568
|
+
delayedStartSeconds: number().int().nonnegative().nullable(),
|
|
55474
55569
|
/** Cycle completion 0..100, or null when not applicable. */
|
|
55475
55570
|
progressPercent: number().min(0).max(100).nullable(),
|
|
55476
|
-
/** True when the door is reported open. */
|
|
55477
|
-
doorOpen: boolean(),
|
|
55478
|
-
/** True when
|
|
55479
|
-
|
|
55480
|
-
/**
|
|
55481
|
-
|
|
55571
|
+
/** True when the door is reported open; null when the door state is not known. */
|
|
55572
|
+
doorOpen: boolean().nullable(),
|
|
55573
|
+
/** True when the door is latched (locked) during a cycle; null when not reported. */
|
|
55574
|
+
doorLocked: boolean().nullable(),
|
|
55575
|
+
/** True when remote start is allowed (door closed, power on, etc.); null when not known. */
|
|
55576
|
+
remoteStartAllowed: boolean().nullable(),
|
|
55577
|
+
/** True when the appliance accepts remote control now; null when not known. */
|
|
55578
|
+
remoteControlActive: boolean().nullable(),
|
|
55579
|
+
/** True while somebody operates the appliance at its panel; null when not reported. */
|
|
55580
|
+
localControlActive: boolean().nullable(),
|
|
55581
|
+
/** Main power / switched-on state; null when not known. */
|
|
55582
|
+
powerOn: boolean().nullable(),
|
|
55583
|
+
/** The raw power state (`On`, `Off`, `Standby`, …); null when not known. */
|
|
55584
|
+
powerState: string().nullable(),
|
|
55482
55585
|
saltLevel: DishwasherConsumableLevelSchema.nullable(),
|
|
55483
55586
|
rinseAidLevel: DishwasherConsumableLevelSchema.nullable(),
|
|
55484
|
-
|
|
55485
|
-
|
|
55587
|
+
/** Option states: null when the appliance does not expose the option or has not said. */
|
|
55588
|
+
halfLoad: boolean().nullable(),
|
|
55589
|
+
hygienePlus: boolean().nullable(),
|
|
55486
55590
|
/** Extra dry option when the appliance exposes it. */
|
|
55487
|
-
extraDry: boolean(),
|
|
55591
|
+
extraDry: boolean().nullable(),
|
|
55488
55592
|
/** Intensive zone (lower basket) when the appliance exposes it. */
|
|
55489
|
-
intensiveZone: boolean(),
|
|
55593
|
+
intensiveZone: boolean().nullable(),
|
|
55490
55594
|
/** VarioSpeed / VarioSpeed+ when the appliance exposes it. */
|
|
55491
|
-
varioSpeedPlus: boolean(),
|
|
55492
|
-
/** Child lock (controls disabled on the appliance). */
|
|
55493
|
-
childLock: boolean(),
|
|
55595
|
+
varioSpeedPlus: boolean().nullable(),
|
|
55596
|
+
/** Child lock (controls disabled on the appliance); null when not known. */
|
|
55597
|
+
childLock: boolean().nullable(),
|
|
55598
|
+
/** Feature keys of the events currently raised (salt low, rinse aid low, program finished, …). */
|
|
55599
|
+
activeEvents: array(string()),
|
|
55600
|
+
/** Numeric error code when the appliance reports one; null otherwise. */
|
|
55494
55601
|
errorCode: number().nullable(),
|
|
55602
|
+
/** Name of the raised alert-level event while the appliance is in error; null otherwise. */
|
|
55495
55603
|
errorLabel: string().nullable(),
|
|
55604
|
+
/** Ms epoch of the last value received from the appliance; 0 = never. */
|
|
55496
55605
|
lastFetchedAt: number()
|
|
55497
55606
|
});
|
|
55607
|
+
var DeviceIdSchema = number().int().nonnegative();
|
|
55608
|
+
/** A value a program option or setting can take. */
|
|
55609
|
+
var DishwasherValueSchema = union([
|
|
55610
|
+
boolean(),
|
|
55611
|
+
string(),
|
|
55612
|
+
number()
|
|
55613
|
+
]);
|
|
55614
|
+
var DishwasherAccessSchema = _enum([
|
|
55615
|
+
"none",
|
|
55616
|
+
"read",
|
|
55617
|
+
"readWrite",
|
|
55618
|
+
"writeOnly",
|
|
55619
|
+
"readStatic"
|
|
55620
|
+
]);
|
|
55621
|
+
/**
|
|
55622
|
+
* One option or setting the appliance declares, with the constraints its description
|
|
55623
|
+
* gives. A `readWrite` descriptor that is `available` is what `setOption` accepts.
|
|
55624
|
+
*/
|
|
55625
|
+
var DishwasherOptionDescriptorSchema = object({
|
|
55626
|
+
/** Feature key (`Dishcare.Dishwasher.Option.ExtraDry`). */
|
|
55627
|
+
key: string(),
|
|
55628
|
+
/** Last segment of the key, for display. */
|
|
55629
|
+
name: string(),
|
|
55630
|
+
type: _enum([
|
|
55631
|
+
"boolean",
|
|
55632
|
+
"number",
|
|
55633
|
+
"enum",
|
|
55634
|
+
"string"
|
|
55635
|
+
]),
|
|
55636
|
+
access: DishwasherAccessSchema,
|
|
55637
|
+
/** The appliance reports this entity as currently available. */
|
|
55638
|
+
available: boolean(),
|
|
55639
|
+
/** Unit the description declares for a number; null when it declares none. */
|
|
55640
|
+
unit: string().nullable(),
|
|
55641
|
+
min: number().nullable(),
|
|
55642
|
+
max: number().nullable(),
|
|
55643
|
+
step: number().nullable(),
|
|
55644
|
+
/** Allowed members of an enum; null for other types. */
|
|
55645
|
+
enumValues: array(string()).nullable(),
|
|
55646
|
+
defaultValue: DishwasherValueSchema.nullable()
|
|
55647
|
+
});
|
|
55648
|
+
var DishwasherProgramSchema = object({
|
|
55649
|
+
/** Feature key (`Dishcare.Dishwasher.Program.Eco50`) — what `setProgram` / `start` take. */
|
|
55650
|
+
key: string(),
|
|
55651
|
+
name: string(),
|
|
55652
|
+
/** The appliance currently offers this program. */
|
|
55653
|
+
available: boolean(),
|
|
55654
|
+
/** The options this program lists, with the program-level access / availability / default. */
|
|
55655
|
+
options: array(DishwasherOptionDescriptorSchema)
|
|
55656
|
+
});
|
|
55657
|
+
var DishwasherOptionsSchema = object({
|
|
55658
|
+
availability: DishwasherAvailabilitySchema,
|
|
55659
|
+
/** What the appliance can be told to do, from the commands its description declares. */
|
|
55660
|
+
supportsStart: boolean(),
|
|
55661
|
+
supportsPause: boolean(),
|
|
55662
|
+
supportsResume: boolean(),
|
|
55663
|
+
supportsStop: boolean(),
|
|
55664
|
+
supportsPower: boolean(),
|
|
55665
|
+
/** Every program the description lists, with its options. */
|
|
55666
|
+
programs: array(DishwasherProgramSchema),
|
|
55667
|
+
/** Every option and setting entity the description lists (programs reference these by key). */
|
|
55668
|
+
options: array(DishwasherOptionDescriptorSchema)
|
|
55669
|
+
});
|
|
55498
55670
|
var dishwasherCapability = {
|
|
55499
55671
|
name: "dishwasher",
|
|
55500
55672
|
scope: "device",
|
|
@@ -55502,86 +55674,102 @@ var dishwasherCapability = {
|
|
|
55502
55674
|
mode: "singleton",
|
|
55503
55675
|
deviceTypes: [DeviceType.Dishwasher],
|
|
55504
55676
|
methods: {
|
|
55505
|
-
|
|
55677
|
+
/**
|
|
55678
|
+
* Start a program. Without `program` the selected one starts. `options` are
|
|
55679
|
+
* option feature keys; each is checked against the program's constraints.
|
|
55680
|
+
*/
|
|
55681
|
+
start: method(object({
|
|
55682
|
+
deviceId: DeviceIdSchema,
|
|
55683
|
+
program: string().min(1).optional(),
|
|
55684
|
+
options: record(string(), DishwasherValueSchema).optional()
|
|
55685
|
+
}), _void(), {
|
|
55506
55686
|
kind: "mutation",
|
|
55507
55687
|
auth: "protected"
|
|
55508
55688
|
}),
|
|
55509
|
-
pause: method(object({ deviceId:
|
|
55689
|
+
pause: method(object({ deviceId: DeviceIdSchema }), _void(), {
|
|
55510
55690
|
kind: "mutation",
|
|
55511
55691
|
auth: "protected"
|
|
55512
55692
|
}),
|
|
55513
|
-
|
|
55693
|
+
resume: method(object({ deviceId: DeviceIdSchema }), _void(), {
|
|
55694
|
+
kind: "mutation",
|
|
55695
|
+
auth: "protected"
|
|
55696
|
+
}),
|
|
55697
|
+
stop: method(object({ deviceId: DeviceIdSchema }), _void(), {
|
|
55514
55698
|
kind: "mutation",
|
|
55515
55699
|
auth: "protected"
|
|
55516
55700
|
}),
|
|
55701
|
+
/** Select (not start) a program; refused when the appliance does not offer it. */
|
|
55517
55702
|
setProgram: method(object({
|
|
55518
|
-
deviceId:
|
|
55703
|
+
deviceId: DeviceIdSchema,
|
|
55519
55704
|
program: string().min(1)
|
|
55520
55705
|
}), _void(), {
|
|
55521
55706
|
kind: "mutation",
|
|
55522
55707
|
auth: "protected"
|
|
55523
55708
|
}),
|
|
55524
55709
|
setPower: method(object({
|
|
55525
|
-
deviceId:
|
|
55710
|
+
deviceId: DeviceIdSchema,
|
|
55526
55711
|
on: boolean()
|
|
55527
55712
|
}), _void(), {
|
|
55528
55713
|
kind: "mutation",
|
|
55529
55714
|
auth: "protected"
|
|
55530
55715
|
}),
|
|
55531
55716
|
setHalfLoad: method(object({
|
|
55532
|
-
deviceId:
|
|
55717
|
+
deviceId: DeviceIdSchema,
|
|
55533
55718
|
on: boolean()
|
|
55534
55719
|
}), _void(), {
|
|
55535
55720
|
kind: "mutation",
|
|
55536
55721
|
auth: "protected"
|
|
55537
55722
|
}),
|
|
55538
55723
|
setHygienePlus: method(object({
|
|
55539
|
-
deviceId:
|
|
55724
|
+
deviceId: DeviceIdSchema,
|
|
55540
55725
|
on: boolean()
|
|
55541
55726
|
}), _void(), {
|
|
55542
55727
|
kind: "mutation",
|
|
55543
55728
|
auth: "protected"
|
|
55544
55729
|
}),
|
|
55545
55730
|
setExtraDry: method(object({
|
|
55546
|
-
deviceId:
|
|
55731
|
+
deviceId: DeviceIdSchema,
|
|
55547
55732
|
on: boolean()
|
|
55548
55733
|
}), _void(), {
|
|
55549
55734
|
kind: "mutation",
|
|
55550
55735
|
auth: "protected"
|
|
55551
55736
|
}),
|
|
55552
55737
|
setIntensiveZone: method(object({
|
|
55553
|
-
deviceId:
|
|
55738
|
+
deviceId: DeviceIdSchema,
|
|
55554
55739
|
on: boolean()
|
|
55555
55740
|
}), _void(), {
|
|
55556
55741
|
kind: "mutation",
|
|
55557
55742
|
auth: "protected"
|
|
55558
55743
|
}),
|
|
55559
55744
|
setVarioSpeedPlus: method(object({
|
|
55560
|
-
deviceId:
|
|
55745
|
+
deviceId: DeviceIdSchema,
|
|
55561
55746
|
on: boolean()
|
|
55562
55747
|
}), _void(), {
|
|
55563
55748
|
kind: "mutation",
|
|
55564
55749
|
auth: "protected"
|
|
55565
55750
|
}),
|
|
55566
55751
|
setChildLock: method(object({
|
|
55567
|
-
deviceId:
|
|
55752
|
+
deviceId: DeviceIdSchema,
|
|
55568
55753
|
on: boolean()
|
|
55569
55754
|
}), _void(), {
|
|
55570
55755
|
kind: "mutation",
|
|
55571
55756
|
auth: "protected"
|
|
55572
55757
|
}),
|
|
55758
|
+
/**
|
|
55759
|
+
* Write any option or setting by feature key. Refused when the description does
|
|
55760
|
+
* not list it, it is not writable or not available now, or the value is outside
|
|
55761
|
+
* its declared range / members.
|
|
55762
|
+
*/
|
|
55573
55763
|
setOption: method(object({
|
|
55574
|
-
deviceId:
|
|
55764
|
+
deviceId: DeviceIdSchema,
|
|
55575
55765
|
key: string().min(1),
|
|
55576
|
-
value:
|
|
55577
|
-
boolean(),
|
|
55578
|
-
string(),
|
|
55579
|
-
number()
|
|
55580
|
-
])
|
|
55766
|
+
value: DishwasherValueSchema
|
|
55581
55767
|
}), _void(), {
|
|
55582
55768
|
kind: "mutation",
|
|
55583
55769
|
auth: "protected"
|
|
55584
|
-
})
|
|
55770
|
+
}),
|
|
55771
|
+
/** What this appliance can do, from its own description — the UI is derived from it. */
|
|
55772
|
+
getOptions: method(object({ deviceId: DeviceIdSchema }), DishwasherOptionsSchema, { auth: "protected" })
|
|
55585
55773
|
},
|
|
55586
55774
|
status: {
|
|
55587
55775
|
schema: DishwasherStatusSchema,
|
|
@@ -69530,6 +69718,12 @@ Object.freeze({
|
|
|
69530
69718
|
addonId: null,
|
|
69531
69719
|
access: "view"
|
|
69532
69720
|
},
|
|
69721
|
+
"dishwasher.getOptions": {
|
|
69722
|
+
capName: "dishwasher",
|
|
69723
|
+
capScope: "device",
|
|
69724
|
+
addonId: null,
|
|
69725
|
+
access: "view"
|
|
69726
|
+
},
|
|
69533
69727
|
"dishwasher.getStatus": {
|
|
69534
69728
|
capName: "dishwasher",
|
|
69535
69729
|
capScope: "device",
|
|
@@ -69542,6 +69736,12 @@ Object.freeze({
|
|
|
69542
69736
|
addonId: null,
|
|
69543
69737
|
access: "create"
|
|
69544
69738
|
},
|
|
69739
|
+
"dishwasher.resume": {
|
|
69740
|
+
capName: "dishwasher",
|
|
69741
|
+
capScope: "device",
|
|
69742
|
+
addonId: null,
|
|
69743
|
+
access: "create"
|
|
69744
|
+
},
|
|
69545
69745
|
"dishwasher.setChildLock": {
|
|
69546
69746
|
capName: "dishwasher",
|
|
69547
69747
|
capScope: "device",
|
|
@@ -74042,6 +74242,12 @@ Object.freeze({
|
|
|
74042
74242
|
addonId: null,
|
|
74043
74243
|
access: "view"
|
|
74044
74244
|
},
|
|
74245
|
+
"storageMigration.moverClearance": {
|
|
74246
|
+
capName: "storage-migration",
|
|
74247
|
+
capScope: "system",
|
|
74248
|
+
addonId: null,
|
|
74249
|
+
access: "view"
|
|
74250
|
+
},
|
|
74045
74251
|
"storageMigration.movers": {
|
|
74046
74252
|
capName: "storage-migration",
|
|
74047
74253
|
capScope: "system",
|
|
@@ -76301,6 +76507,11 @@ Object.freeze({
|
|
|
76301
76507
|
form: "single",
|
|
76302
76508
|
optional: false
|
|
76303
76509
|
}],
|
|
76510
|
+
"dishwasher.getOptions": [{
|
|
76511
|
+
name: "deviceId",
|
|
76512
|
+
form: "single",
|
|
76513
|
+
optional: false
|
|
76514
|
+
}],
|
|
76304
76515
|
"dishwasher.getStatus": [{
|
|
76305
76516
|
name: "deviceId",
|
|
76306
76517
|
form: "single",
|
|
@@ -76311,6 +76522,11 @@ Object.freeze({
|
|
|
76311
76522
|
form: "single",
|
|
76312
76523
|
optional: false
|
|
76313
76524
|
}],
|
|
76525
|
+
"dishwasher.resume": [{
|
|
76526
|
+
name: "deviceId",
|
|
76527
|
+
form: "single",
|
|
76528
|
+
optional: false
|
|
76529
|
+
}],
|
|
76314
76530
|
"dishwasher.setChildLock": [{
|
|
76315
76531
|
name: "deviceId",
|
|
76316
76532
|
form: "single",
|
|
@@ -78397,6 +78613,9 @@ new Map(Object.entries({
|
|
|
78397
78613
|
"wrapper-update-available": "system",
|
|
78398
78614
|
"backup-completed": "system",
|
|
78399
78615
|
"export-completed": "system",
|
|
78616
|
+
"alert-critical": "system",
|
|
78617
|
+
"alert-error": "system",
|
|
78618
|
+
"alert-critical-resolved": "system",
|
|
78400
78619
|
"storage-location-low": "system",
|
|
78401
78620
|
"storage-location-critical": "system",
|
|
78402
78621
|
"storage-location-ok": "system",
|
|
@@ -78521,6 +78740,16 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
|
|
|
78521
78740
|
"storage-location-ok"
|
|
78522
78741
|
]
|
|
78523
78742
|
},
|
|
78743
|
+
{
|
|
78744
|
+
id: "alerts",
|
|
78745
|
+
family: "system",
|
|
78746
|
+
label: "Alerts",
|
|
78747
|
+
kinds: [
|
|
78748
|
+
"alert-critical",
|
|
78749
|
+
"alert-error",
|
|
78750
|
+
"alert-critical-resolved"
|
|
78751
|
+
]
|
|
78752
|
+
},
|
|
78524
78753
|
{
|
|
78525
78754
|
id: "alarm",
|
|
78526
78755
|
family: "alarm",
|
|
@@ -78565,6 +78794,21 @@ var NC_SENSOR_RAISED_FIELD_BY_KIND = Object.freeze(Object.fromEntries(Object.ent
|
|
|
78565
78794
|
return [[descriptor.kind, field]];
|
|
78566
78795
|
})));
|
|
78567
78796
|
Object.freeze(Object.keys(NC_SENSOR_RAISED_FIELD_BY_KIND));
|
|
78797
|
+
object({
|
|
78798
|
+
phase: _enum(["raised", "resolved"]),
|
|
78799
|
+
episodeId: string().min(1),
|
|
78800
|
+
alertId: string().min(1),
|
|
78801
|
+
severity: AlertSeveritySchema,
|
|
78802
|
+
category: string(),
|
|
78803
|
+
title: string(),
|
|
78804
|
+
message: string(),
|
|
78805
|
+
sourceType: string().optional(),
|
|
78806
|
+
sourceId: string().optional(),
|
|
78807
|
+
nodeId: string().optional(),
|
|
78808
|
+
/** The alert's own action link (where the operator acts on it), when it has one. */
|
|
78809
|
+
actionUrl: string().optional(),
|
|
78810
|
+
at: number()
|
|
78811
|
+
});
|
|
78568
78812
|
var RULE_BODY_ONLY = ["body"];
|
|
78569
78813
|
var RULE_TEXT = ["title", "body"];
|
|
78570
78814
|
var BATTERY = ["device-battery-low", "device-battery-normal"];
|
|
@@ -78574,6 +78818,11 @@ var TANK = [
|
|
|
78574
78818
|
"device-tank-full",
|
|
78575
78819
|
"device-tank-normal"
|
|
78576
78820
|
];
|
|
78821
|
+
var ALERT_EPISODE = [
|
|
78822
|
+
"alert-critical",
|
|
78823
|
+
"alert-error",
|
|
78824
|
+
"alert-critical-resolved"
|
|
78825
|
+
];
|
|
78577
78826
|
var UPDATES = [
|
|
78578
78827
|
"addon-update-available",
|
|
78579
78828
|
"server-update-available",
|
|
@@ -78766,14 +79015,14 @@ var STATE_SUMMARY_VARS = [
|
|
|
78766
79015
|
([...RULE_TEXT], [...CONSUMABLE]),
|
|
78767
79016
|
([...RULE_TEXT], [...TANK]),
|
|
78768
79017
|
[...RULE_TEXT],
|
|
78769
|
-
([...RULE_TEXT], [...UPDATES]),
|
|
78770
|
-
([...RULE_TEXT], [...UPDATES]),
|
|
78771
|
-
[...RULE_TEXT],
|
|
79018
|
+
([...RULE_TEXT], [...UPDATES, ...ALERT_EPISODE]),
|
|
79019
|
+
([...RULE_TEXT], [...UPDATES, ...ALERT_EPISODE]),
|
|
78772
79020
|
[...RULE_TEXT],
|
|
78773
79021
|
[...RULE_TEXT],
|
|
78774
79022
|
[...RULE_TEXT],
|
|
78775
79023
|
[...RULE_TEXT],
|
|
78776
79024
|
[...RULE_TEXT],
|
|
79025
|
+
([...RULE_TEXT], [...ALERT_EPISODE]),
|
|
78777
79026
|
[...RULE_TEXT],
|
|
78778
79027
|
[...RULE_TEXT],
|
|
78779
79028
|
[...RULE_TEXT],
|
|
@@ -78791,7 +79040,11 @@ var STATE_SUMMARY_VARS = [
|
|
|
78791
79040
|
[...RULE_TEXT],
|
|
78792
79041
|
[...RULE_TEXT],
|
|
78793
79042
|
[...RULE_TEXT],
|
|
78794
|
-
[...RULE_TEXT],
|
|
79043
|
+
([...RULE_TEXT], [...ALERT_EPISODE]),
|
|
79044
|
+
([...RULE_TEXT], [...ALERT_EPISODE]),
|
|
79045
|
+
([...RULE_TEXT], [...ALERT_EPISODE]),
|
|
79046
|
+
([...RULE_TEXT], [...ALERT_EPISODE]),
|
|
79047
|
+
([...RULE_TEXT], [...ALERT_EPISODE]),
|
|
78795
79048
|
[...RULE_TEXT],
|
|
78796
79049
|
[...RULE_TEXT],
|
|
78797
79050
|
[...RULE_TEXT],
|