@camstack/addon-export-google 0.1.117 → 0.1.118
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/CHANGELOG.md +6 -0
- package/dist/export-google.addon.js +1823 -724
- package/dist/export-google.addon.mjs +1823 -724
- package/package.json +3 -2
|
@@ -5146,6 +5146,14 @@ function object(shape, params) {
|
|
|
5146
5146
|
...normalizeParams(params)
|
|
5147
5147
|
});
|
|
5148
5148
|
}
|
|
5149
|
+
function strictObject(shape, params) {
|
|
5150
|
+
return new ZodObject({
|
|
5151
|
+
type: "object",
|
|
5152
|
+
shape,
|
|
5153
|
+
catchall: never(),
|
|
5154
|
+
...normalizeParams(params)
|
|
5155
|
+
});
|
|
5156
|
+
}
|
|
5149
5157
|
function looseObject(shape, params) {
|
|
5150
5158
|
return new ZodObject({
|
|
5151
5159
|
type: "object",
|
|
@@ -5525,7 +5533,7 @@ var ZodIssueCode = {
|
|
|
5525
5533
|
var ZodFirstPartyTypeKind;
|
|
5526
5534
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5527
5535
|
//#endregion
|
|
5528
|
-
//#region ../types/dist/sleep-
|
|
5536
|
+
//#region ../types/dist/sleep-6eG9C8Xl.mjs
|
|
5529
5537
|
/**
|
|
5530
5538
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5531
5539
|
* window to float samples (D455).
|
|
@@ -8501,6 +8509,52 @@ function optionalMethod(input, output, options) {
|
|
|
8501
8509
|
providerOptional: true
|
|
8502
8510
|
};
|
|
8503
8511
|
}
|
|
8512
|
+
/**
|
|
8513
|
+
* `addon-pages-source` — collection cap exposing per-provider raw page
|
|
8514
|
+
* declarations. Every addon that contributes a UI page registers a
|
|
8515
|
+
* provider here. The hub-side singleton aggregator (`addon-pages` cap,
|
|
8516
|
+
* see `addon-pages.cap.ts`) walks this collection, stamps versioned
|
|
8517
|
+
* `bundleUrl` values, and returns the enriched `AddonPageInfo[]` list
|
|
8518
|
+
* that admin-ui consumes.
|
|
8519
|
+
*
|
|
8520
|
+
* The split exists because the public listing has a different output
|
|
8521
|
+
* shape than the per-provider raw declarations, and we want both ends
|
|
8522
|
+
* to flow through codegen instead of relying on a hand-written wrapper.
|
|
8523
|
+
*/
|
|
8524
|
+
var AddonPageDeclarationSchema = object({
|
|
8525
|
+
id: string(),
|
|
8526
|
+
label: string(),
|
|
8527
|
+
icon: string(),
|
|
8528
|
+
path: string(),
|
|
8529
|
+
/**
|
|
8530
|
+
* Module Federation remote name — must match the `name` field on the
|
|
8531
|
+
* page addon's `federation()` plugin config. Used by admin-ui's
|
|
8532
|
+
* `<AddonPageLoader>` to call `loadRemote('<remoteName>/page')`.
|
|
8533
|
+
* Conventionally `addon_<id>_page` (snake_case; MF names cannot
|
|
8534
|
+
* contain hyphens).
|
|
8535
|
+
*/
|
|
8536
|
+
remoteName: string(),
|
|
8537
|
+
/**
|
|
8538
|
+
* Bundle filename inside the addon's `dist/` dir served at
|
|
8539
|
+
* `/api/addon-pages/<addonId>/<bundle>`. With Module Federation this
|
|
8540
|
+
* is always `'remoteEntry.js'`; the value is kept on the metadata so
|
|
8541
|
+
* the static-file route can compute an mtime-based cache-buster URL
|
|
8542
|
+
* without a separate filesystem stat.
|
|
8543
|
+
*/
|
|
8544
|
+
bundle: string(),
|
|
8545
|
+
/**
|
|
8546
|
+
* Sidebar section this page docks into. Well-known ids: `'detection'`,
|
|
8547
|
+
* `'cluster'`, `'administration'` — the page renders inside that group.
|
|
8548
|
+
* Any OTHER string creates (or joins) a custom section rendered after
|
|
8549
|
+
* the built-in groups; its label comes from `sectionLabel` (first
|
|
8550
|
+
* declaration wins), falling back to the id. Absent → the legacy
|
|
8551
|
+
* "Addon Pages" group.
|
|
8552
|
+
*/
|
|
8553
|
+
section: string().optional(),
|
|
8554
|
+
/** Display label for a CUSTOM `section` id (ignored for well-known ids). */
|
|
8555
|
+
sectionLabel: string().optional()
|
|
8556
|
+
});
|
|
8557
|
+
method(_void(), array(AddonPageDeclarationSchema).readonly(), { auth: "admin" });
|
|
8504
8558
|
var StaticDirOutputSchema$1 = object({ staticDir: string() });
|
|
8505
8559
|
var VersionOutputSchema$1 = object({ version: string() });
|
|
8506
8560
|
method(_void(), StaticDirOutputSchema$1, { auth: "admin" }), method(_void(), VersionOutputSchema$1, { auth: "admin" });
|
|
@@ -8526,6 +8580,27 @@ function customAction(input, output, options) {
|
|
|
8526
8580
|
...options?.caller ? { caller: "required" } : {}
|
|
8527
8581
|
};
|
|
8528
8582
|
}
|
|
8583
|
+
/**
|
|
8584
|
+
* The pipeline step-input shape and the run-result bridge, in a module that
|
|
8585
|
+
* imports nothing but zod and types.
|
|
8586
|
+
*
|
|
8587
|
+
* WHY A SEPARATE FILE (addon footprint, D28): both were declared in
|
|
8588
|
+
* `pipeline-executor.cap.ts`, whose import evaluates the whole executor schema
|
|
8589
|
+
* graph. An addon that only needs these two (the benchmark's `runPipelineTest`
|
|
8590
|
+
* action) paid ~130 MB of heap at load. `pipeline-executor.cap.ts` re-exports
|
|
8591
|
+
* them, so every existing import keeps working; addon server code takes them
|
|
8592
|
+
* from `@camstack/types/addon`.
|
|
8593
|
+
*/
|
|
8594
|
+
var PipelineStepInputSchema = lazy(() => object({
|
|
8595
|
+
addonId: string(),
|
|
8596
|
+
modelId: string().optional(),
|
|
8597
|
+
enabled: boolean().default(true),
|
|
8598
|
+
children: array(PipelineStepInputSchema).optional(),
|
|
8599
|
+
settings: record(string(), unknown()).optional(),
|
|
8600
|
+
jumpDeviceKey: string().optional()
|
|
8601
|
+
}));
|
|
8602
|
+
/** Typed bridge to the recursive `FrameResult` graph; validation is structural. */
|
|
8603
|
+
var PipelineRunResultBridge = custom();
|
|
8529
8604
|
var StaticDirOutputSchema = object({ staticDir: string() });
|
|
8530
8605
|
var VersionOutputSchema = object({ version: string() });
|
|
8531
8606
|
method(_void(), StaticDirOutputSchema, { auth: "admin" }), method(_void(), VersionOutputSchema, { auth: "admin" });
|
|
@@ -8681,6 +8756,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
8681
8756
|
"image-settings",
|
|
8682
8757
|
"integrations",
|
|
8683
8758
|
"intercom",
|
|
8759
|
+
"ir-transmitter",
|
|
8684
8760
|
"keychain",
|
|
8685
8761
|
"keychain-admin",
|
|
8686
8762
|
"lawn-mower-control",
|
|
@@ -8709,6 +8785,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
8709
8785
|
"network-link",
|
|
8710
8786
|
"network-quality",
|
|
8711
8787
|
"node-certificates",
|
|
8788
|
+
"node-removal-hook",
|
|
8712
8789
|
"nodes",
|
|
8713
8790
|
"notification-output",
|
|
8714
8791
|
"notification-rules",
|
|
@@ -8719,6 +8796,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
8719
8796
|
"osd",
|
|
8720
8797
|
"osd-manager",
|
|
8721
8798
|
"pet-feeder",
|
|
8799
|
+
"pet-fountain",
|
|
8722
8800
|
"pipeline-analytics",
|
|
8723
8801
|
"pipeline-executor",
|
|
8724
8802
|
"pipeline-orchestrator",
|
|
@@ -8739,6 +8817,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
8739
8817
|
"recording-onboard",
|
|
8740
8818
|
"recording-signal",
|
|
8741
8819
|
"records",
|
|
8820
|
+
"remote",
|
|
8742
8821
|
"running-state",
|
|
8743
8822
|
"scene-monitor",
|
|
8744
8823
|
"script-runner",
|
|
@@ -8762,6 +8841,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
8762
8841
|
"system",
|
|
8763
8842
|
"tamper",
|
|
8764
8843
|
"temperature-sensor",
|
|
8844
|
+
"template",
|
|
8765
8845
|
"terminal-session",
|
|
8766
8846
|
"toast",
|
|
8767
8847
|
"training",
|
|
@@ -9702,6 +9782,11 @@ Object.freeze({
|
|
|
9702
9782
|
"standby"
|
|
9703
9783
|
]
|
|
9704
9784
|
},
|
|
9785
|
+
{
|
|
9786
|
+
"path": "stateSource",
|
|
9787
|
+
"valueType": "enum",
|
|
9788
|
+
"enumValues": ["reported", "assumed"]
|
|
9789
|
+
},
|
|
9705
9790
|
{
|
|
9706
9791
|
"path": "volumeLevel",
|
|
9707
9792
|
"valueType": "number"
|
|
@@ -9928,6 +10013,11 @@ Object.freeze({
|
|
|
9928
10013
|
"path": "batteryPower",
|
|
9929
10014
|
"valueType": "number"
|
|
9930
10015
|
},
|
|
10016
|
+
{
|
|
10017
|
+
"path": "powerSource",
|
|
10018
|
+
"valueType": "enum",
|
|
10019
|
+
"enumValues": ["mains", "battery"]
|
|
10020
|
+
},
|
|
9931
10021
|
{
|
|
9932
10022
|
"path": "desiccantLeftDays",
|
|
9933
10023
|
"valueType": "number"
|
|
@@ -9972,6 +10062,68 @@ Object.freeze({
|
|
|
9972
10062
|
{
|
|
9973
10063
|
"path": "volume",
|
|
9974
10064
|
"valueType": "number"
|
|
10065
|
+
},
|
|
10066
|
+
{
|
|
10067
|
+
"path": "lastFeedGrams",
|
|
10068
|
+
"valueType": "number"
|
|
10069
|
+
},
|
|
10070
|
+
{
|
|
10071
|
+
"path": "lastFeedHopper1",
|
|
10072
|
+
"valueType": "number"
|
|
10073
|
+
},
|
|
10074
|
+
{
|
|
10075
|
+
"path": "lastFeedHopper2",
|
|
10076
|
+
"valueType": "number"
|
|
10077
|
+
}
|
|
10078
|
+
],
|
|
10079
|
+
"pet-fountain": [
|
|
10080
|
+
{
|
|
10081
|
+
"path": "waterLevel",
|
|
10082
|
+
"valueType": "number"
|
|
10083
|
+
},
|
|
10084
|
+
{
|
|
10085
|
+
"path": "waterVolume",
|
|
10086
|
+
"valueType": "number"
|
|
10087
|
+
},
|
|
10088
|
+
{
|
|
10089
|
+
"path": "empty",
|
|
10090
|
+
"valueType": "boolean"
|
|
10091
|
+
},
|
|
10092
|
+
{
|
|
10093
|
+
"path": "pumpRunning",
|
|
10094
|
+
"valueType": "boolean"
|
|
10095
|
+
},
|
|
10096
|
+
{
|
|
10097
|
+
"path": "pumpIntervalEnabled",
|
|
10098
|
+
"valueType": "boolean"
|
|
10099
|
+
},
|
|
10100
|
+
{
|
|
10101
|
+
"path": "pumpOnTime",
|
|
10102
|
+
"valueType": "number"
|
|
10103
|
+
},
|
|
10104
|
+
{
|
|
10105
|
+
"path": "pumpOffTime",
|
|
10106
|
+
"valueType": "number"
|
|
10107
|
+
},
|
|
10108
|
+
{
|
|
10109
|
+
"path": "lastDrink",
|
|
10110
|
+
"valueType": "number"
|
|
10111
|
+
},
|
|
10112
|
+
{
|
|
10113
|
+
"path": "currentHourDrink",
|
|
10114
|
+
"valueType": "number"
|
|
10115
|
+
},
|
|
10116
|
+
{
|
|
10117
|
+
"path": "last24hDrink",
|
|
10118
|
+
"valueType": "number"
|
|
10119
|
+
},
|
|
10120
|
+
{
|
|
10121
|
+
"path": "todayDrink",
|
|
10122
|
+
"valueType": "number"
|
|
10123
|
+
},
|
|
10124
|
+
{
|
|
10125
|
+
"path": "error",
|
|
10126
|
+
"valueType": "string"
|
|
9975
10127
|
}
|
|
9976
10128
|
],
|
|
9977
10129
|
"power-meter": [
|
|
@@ -10511,7 +10663,7 @@ object({
|
|
|
10511
10663
|
params: record(string(), union([string(), number()])).optional()
|
|
10512
10664
|
});
|
|
10513
10665
|
//#endregion
|
|
10514
|
-
//#region ../types/dist/err-msg-
|
|
10666
|
+
//#region ../types/dist/err-msg-DWXWc0Di.mjs
|
|
10515
10667
|
var DeviceType = /* @__PURE__ */ function(DeviceType) {
|
|
10516
10668
|
DeviceType["Camera"] = "camera";
|
|
10517
10669
|
DeviceType["Hub"] = "hub";
|
|
@@ -10603,6 +10755,10 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
|
|
|
10603
10755
|
* native PetKit (`nodepetkit` `FeederDevice`), reusable by other feeder
|
|
10604
10756
|
* integrations sharing the same food/desiccant/hopper surface. */
|
|
10605
10757
|
DeviceType["PetFeeder"] = "pet-feeder";
|
|
10758
|
+
/** Pet water fountain — tank level, water drunk, pump and its duty cycle.
|
|
10759
|
+
* Installed with the `pet-fountain` cap. Reaches CamStack as loose entities
|
|
10760
|
+
* of a container and is BUILT as a composed device (D967). */
|
|
10761
|
+
DeviceType["PetFountain"] = "pet-fountain";
|
|
10606
10762
|
/** Built-in dishwasher — program lifecycle, door / remote-start gates,
|
|
10607
10763
|
* salt and rinse-aid levels. Installed with the `dishwasher` cap.
|
|
10608
10764
|
* Sources: native Bosch Home Connect, reusable by similar integrations.
|
|
@@ -10857,6 +11013,9 @@ var DeviceRole = /* @__PURE__ */ function(DeviceRole) {
|
|
|
10857
11013
|
/** Fallback when the notifier service name doesn't match a known
|
|
10858
11014
|
* pattern. */
|
|
10859
11015
|
DeviceRole["GenericNotifier"] = "generic-notifier";
|
|
11016
|
+
/** Emits a pulse train (infrared or RF) on request — the `ir-transmitter`
|
|
11017
|
+
* cap. A `DeviceType.Generic` device. */
|
|
11018
|
+
DeviceRole["IrTransmitter"] = "ir-transmitter";
|
|
10860
11019
|
return DeviceRole;
|
|
10861
11020
|
}({});
|
|
10862
11021
|
/**
|
|
@@ -10870,7 +11029,7 @@ function errMsg(err) {
|
|
|
10870
11029
|
return String(err);
|
|
10871
11030
|
}
|
|
10872
11031
|
//#endregion
|
|
10873
|
-
//#region ../types/dist/composition-
|
|
11032
|
+
//#region ../types/dist/composition-kSuOifuG.mjs
|
|
10874
11033
|
/**
|
|
10875
11034
|
* The ffmpeg build every CamStack node downloads, per platform and arch.
|
|
10876
11035
|
*
|
|
@@ -11955,12 +12114,28 @@ var CompositionFieldSourceSchema = discriminatedUnion("kind", [
|
|
|
11955
12114
|
])
|
|
11956
12115
|
})
|
|
11957
12116
|
]);
|
|
11958
|
-
var
|
|
12117
|
+
var forwardArgUnion = union([
|
|
12118
|
+
string(),
|
|
12119
|
+
number(),
|
|
12120
|
+
boolean(),
|
|
12121
|
+
strictObject({ ["$input"]: string().min(1) }),
|
|
12122
|
+
record(string().min(1), lazy(() => forwardArgUnion))
|
|
12123
|
+
]);
|
|
12124
|
+
var CompositionForwardArgSchema = forwardArgUnion;
|
|
12125
|
+
/**
|
|
12126
|
+
* `forward` (D659, amended by D967): one method of a BUILT capability is one
|
|
12127
|
+
* call of `cap.method` on `source`. Without `args` the built method's input
|
|
12128
|
+
* passes through minus `deviceId`; with `args` the template IS the source's
|
|
12129
|
+
* whole input. `deviceId` is always the source's own, never an argument.
|
|
12130
|
+
*/
|
|
12131
|
+
var CompositionForwardCommandSchema = object({
|
|
11959
12132
|
kind: literal("forward"),
|
|
11960
12133
|
source: CompositionSourceRefSchema,
|
|
11961
12134
|
cap: string().min(1),
|
|
11962
|
-
method: string().min(1)
|
|
11963
|
-
|
|
12135
|
+
method: string().min(1),
|
|
12136
|
+
args: record(string().min(1), CompositionForwardArgSchema).optional()
|
|
12137
|
+
});
|
|
12138
|
+
var CompositionCommandTargetSchema = discriminatedUnion("kind", [CompositionForwardCommandSchema, CompositionCodeSourceSchema]);
|
|
11964
12139
|
/** An item key inside an item-array cap (`consumables.items[<key>]`). */
|
|
11965
12140
|
var COMPOSITION_ITEM_KEY_RE = /^[a-z0-9][a-z0-9-]{0,47}$/;
|
|
11966
12141
|
/**
|
|
@@ -11970,7 +12145,13 @@ var COMPOSITION_ITEM_KEY_RE = /^[a-z0-9][a-z0-9-]{0,47}$/;
|
|
|
11970
12145
|
*/
|
|
11971
12146
|
var CompositionItemEntrySchema = object({
|
|
11972
12147
|
label: string().min(1).max(80),
|
|
11973
|
-
fields: record(string().min(1), CompositionFieldSourceSchema)
|
|
12148
|
+
fields: record(string().min(1), CompositionFieldSourceSchema),
|
|
12149
|
+
/**
|
|
12150
|
+
* What the cap's `reset` does for THIS item (consumables). Present = the item
|
|
12151
|
+
* is resettable and a `reset` call naming its key forwards here. The item key
|
|
12152
|
+
* selects the command, so it is never an argument: there is no pass-through.
|
|
12153
|
+
*/
|
|
12154
|
+
reset: CompositionForwardCommandSchema.optional()
|
|
11974
12155
|
});
|
|
11975
12156
|
var CompositionFeatureSchema = discriminatedUnion("kind", [object({
|
|
11976
12157
|
kind: literal("fields"),
|
|
@@ -11982,7 +12163,7 @@ var CompositionFeatureSchema = discriminatedUnion("kind", [object({
|
|
|
11982
12163
|
* owns the WHOLE array field: the composed value holds exactly these items.
|
|
11983
12164
|
*/
|
|
11984
12165
|
items: record(string().regex(COMPOSITION_ITEM_KEY_RE), CompositionItemEntrySchema).refine((items) => Object.keys(items).length <= 16, { message: `at most 16 items` }).optional(),
|
|
11985
|
-
/**
|
|
12166
|
+
/** Method name → what serves it. Only a BUILT capability takes commands (D967). */
|
|
11986
12167
|
commands: record(string().min(1), CompositionCommandTargetSchema).optional()
|
|
11987
12168
|
}), object({
|
|
11988
12169
|
kind: literal("passthrough"),
|
|
@@ -16046,6 +16227,427 @@ object({
|
|
|
16046
16227
|
lastError: string().nullable()
|
|
16047
16228
|
});
|
|
16048
16229
|
/**
|
|
16230
|
+
* notification-output — canonical, capability-gated notification delivery.
|
|
16231
|
+
*
|
|
16232
|
+
* Apprise-derived model (see
|
|
16233
|
+
* `docs/superpowers/specs/2026-07-03-notification-output-notifier-matrix.md`):
|
|
16234
|
+
* callers emit ONE canonical `Notification`; each provider declares a
|
|
16235
|
+
* per-kind capability descriptor (`TargetKind`), and the pure degrade
|
|
16236
|
+
* engine (`@camstack/types` `prepareNotification`) transcodes / degrades the
|
|
16237
|
+
* message to what the kind supports — callers never special-case a service.
|
|
16238
|
+
*
|
|
16239
|
+
* DESIGN DECISIONS (locked):
|
|
16240
|
+
* - Target CRUD lives on THIS cap (`upsertTarget` / `deleteTarget` /
|
|
16241
|
+
* `setTargetEnabled`), each provider persisting via the `settings-store`
|
|
16242
|
+
* cap. Rationale: the admin UI needs one uniform surface across the
|
|
16243
|
+
* notifiers addon AND the HA addon; the addon-`globalSettingsSchema`-array
|
|
16244
|
+
* alternative would fork the UI per addon and cannot host the
|
|
16245
|
+
* discovery→adopt flow.
|
|
16246
|
+
* - `listTargetKinds` / `listTargets` / `discoverTargets` return arrays →
|
|
16247
|
+
* the generated cap-mount auto-`concatCollection`-fans them across every
|
|
16248
|
+
* registered provider (notifiers addon + HA addon) so one catalog is
|
|
16249
|
+
* routable. `send` / `testTarget` / CRUD route to ONE provider by the
|
|
16250
|
+
* `addonId` the generated collection router extracts from the call input.
|
|
16251
|
+
* - `Attachment.bytes` is `Uint8Array`. Transport-safe: superjson (the tRPC
|
|
16252
|
+
* transformer) + UDS MsgPack both round-trip typed arrays — already used by
|
|
16253
|
+
* `storage` / `storage-provider` / `recording` caps over the same path. No
|
|
16254
|
+
* base64 fallback needed.
|
|
16255
|
+
*
|
|
16256
|
+
* TODO (deferred, closed-set change — separate decision): add
|
|
16257
|
+
* `providerKind: 'notify'` so notification providers surface on the unified
|
|
16258
|
+
* admin "Integrations" page.
|
|
16259
|
+
*/
|
|
16260
|
+
/**
|
|
16261
|
+
* Zentik-derived typed-media enum — the superset across every kind. Each
|
|
16262
|
+
* adapter picks what it supports and the degrade engine filters the rest.
|
|
16263
|
+
*/
|
|
16264
|
+
var AttachmentMediaTypeSchema = _enum([
|
|
16265
|
+
"image",
|
|
16266
|
+
"video",
|
|
16267
|
+
"gif",
|
|
16268
|
+
"audio",
|
|
16269
|
+
"icon"
|
|
16270
|
+
]);
|
|
16271
|
+
/**
|
|
16272
|
+
* A single attachment. Exactly one of `url` (remote source, most adapters
|
|
16273
|
+
* prefer this) or `bytes` (inline source; required for Pushover-style
|
|
16274
|
+
* bytes-only kinds) MUST be present — the degrade engine expresses a
|
|
16275
|
+
* url→bytes fetch as a `needsFetch` directive the adapter executes.
|
|
16276
|
+
*/
|
|
16277
|
+
var AttachmentSchema = object({
|
|
16278
|
+
mediaType: AttachmentMediaTypeSchema,
|
|
16279
|
+
url: string().optional(),
|
|
16280
|
+
bytes: _instanceof(Uint8Array).optional(),
|
|
16281
|
+
mime: string().optional(),
|
|
16282
|
+
name: string().optional()
|
|
16283
|
+
}).refine((a) => a.url !== void 0 || a.bytes !== void 0, { message: "Attachment requires either `url` or `bytes`" });
|
|
16284
|
+
var NotificationFormatSchema = _enum([
|
|
16285
|
+
"text",
|
|
16286
|
+
"markdown",
|
|
16287
|
+
"html"
|
|
16288
|
+
]);
|
|
16289
|
+
/**
|
|
16290
|
+
* The CLOSED icon vocabulary an action button may use.
|
|
16291
|
+
*
|
|
16292
|
+
* A closed set, not a free string, and that is the whole point: an arbitrary
|
|
16293
|
+
* icon name is one that ntfy renders, zentik silently drops, and nobody
|
|
16294
|
+
* notices — the same class of gap as a zone vocabulary nothing produced
|
|
16295
|
+
* ([D35](../../../docs/decisions/adr-0035.md)). Every adapter maps this set or
|
|
16296
|
+
* declares `actionIcons: false` and the degrade engine strips the field.
|
|
16297
|
+
*
|
|
16298
|
+
* Named by INTENT, never by glyph. "check" would tie the vocabulary to one
|
|
16299
|
+
* renderer's icon set; "acknowledge" survives an adapter that draws it
|
|
16300
|
+
* differently.
|
|
16301
|
+
*
|
|
16302
|
+
* ── A TOKEN IS NOT A WIRE VALUE ─────────────────────────────────────
|
|
16303
|
+
*
|
|
16304
|
+
* These names are for US. **No adapter may forward one verbatim.** Each maps
|
|
16305
|
+
* the whole set onto its own renderer's vocabulary through a
|
|
16306
|
+
* `Record<NotificationActionIcon, string>` — a Record, never a lookup with a
|
|
16307
|
+
* fallback, so adding a member here fails every adapter's build until someone
|
|
16308
|
+
* decides its glyph, which is the only place that decision can be made
|
|
16309
|
+
* honestly.
|
|
16310
|
+
*
|
|
16311
|
+
* This paragraph is the bug. Zentik declared `actionIcons: true` and passed
|
|
16312
|
+
* `disarm` straight through; iOS feeds that string to
|
|
16313
|
+
* `UNNotificationActionIcon(systemImageName:)`, `disarm` is not an SF Symbol,
|
|
16314
|
+
* and every snooze and alarm button arrived BLANK. A pass-through is not a
|
|
16315
|
+
* mapping, and "the field is documented" is not "the value renders".
|
|
16316
|
+
*
|
|
16317
|
+
* Adding a member is TRAIN-BOUND. The enum lives in the published
|
|
16318
|
+
* `@camstack/server` closure and the cap seam validates against the HUB's copy,
|
|
16319
|
+
* so an addon that emits a token the running hub does not know does not lose an
|
|
16320
|
+
* icon — its whole `send` fails Zod validation and the notification never
|
|
16321
|
+
* arrives. Never emit a new token from an addon before the train carrying it.
|
|
16322
|
+
*/
|
|
16323
|
+
var NotificationActionIconSchema = _enum([
|
|
16324
|
+
"acknowledge",
|
|
16325
|
+
"dismiss",
|
|
16326
|
+
"silence",
|
|
16327
|
+
"snooze",
|
|
16328
|
+
"view",
|
|
16329
|
+
"play",
|
|
16330
|
+
"open",
|
|
16331
|
+
"close",
|
|
16332
|
+
"lock",
|
|
16333
|
+
"unlock",
|
|
16334
|
+
"arm",
|
|
16335
|
+
"arm-home",
|
|
16336
|
+
"arm-away",
|
|
16337
|
+
"arm-night",
|
|
16338
|
+
"disarm",
|
|
16339
|
+
"light",
|
|
16340
|
+
"alert",
|
|
16341
|
+
"camera"
|
|
16342
|
+
]);
|
|
16343
|
+
/** A single tap-through action button. */
|
|
16344
|
+
var NotificationActionSchema = object({
|
|
16345
|
+
id: string(),
|
|
16346
|
+
label: string(),
|
|
16347
|
+
url: string().optional(),
|
|
16348
|
+
/** Dropped by the degrade engine for a kind with `caps.actionIcons: false`. */
|
|
16349
|
+
icon: NotificationActionIconSchema.optional(),
|
|
16350
|
+
/**
|
|
16351
|
+
* Renders in a warning style where the notifier supports it.
|
|
16352
|
+
*
|
|
16353
|
+
* A HINT, never a gate. The callback's authority is its token and nothing
|
|
16354
|
+
* else — see `notification-center/action-token.ts` for what that does and
|
|
16355
|
+
* does not buy.
|
|
16356
|
+
*/
|
|
16357
|
+
destructive: boolean().optional(),
|
|
16358
|
+
/**
|
|
16359
|
+
* How the tap should REACH the url.
|
|
16360
|
+
*
|
|
16361
|
+
* `navigate` (absent, and every button authored before this field) opens it:
|
|
16362
|
+
* the phone leaves the notification and shows whatever the callback returns.
|
|
16363
|
+
* That is right for a button whose answer the operator wants to read.
|
|
16364
|
+
*
|
|
16365
|
+
* `background` fires it as a POST and stays put. It exists for the buttons
|
|
16366
|
+
* whose whole point is not to interrupt — "silence this for 30 minutes" is
|
|
16367
|
+
* an answer to the notification, and being thrown into a browser tab to
|
|
16368
|
+
* confirm it costs more attention than the notification did. A backend that
|
|
16369
|
+
* cannot do a background call renders it as an ordinary link (the adapters
|
|
16370
|
+
* fall back rather than dropping the button), so this is a preference, never
|
|
16371
|
+
* a requirement.
|
|
16372
|
+
*/
|
|
16373
|
+
mode: _enum(["navigate", "background"]).optional()
|
|
16374
|
+
});
|
|
16375
|
+
/** A delivery parameter value: what a notifier declared it takes. */
|
|
16376
|
+
var DeliveryParamValueSchema = union([
|
|
16377
|
+
string(),
|
|
16378
|
+
number(),
|
|
16379
|
+
boolean()
|
|
16380
|
+
]);
|
|
16381
|
+
/**
|
|
16382
|
+
* One extra delivery parameter a notifier KIND declares (D938). A rule that
|
|
16383
|
+
* addresses a target of that kind may set it; a kind that declares nothing is
|
|
16384
|
+
* never handed one. The admin UI derives its control from this descriptor —
|
|
16385
|
+
* no editor knows a service by name.
|
|
16386
|
+
*
|
|
16387
|
+
* Optional fields are `.optional()`, never `.default()` (a Zod default does not
|
|
16388
|
+
* run on the addon cap path).
|
|
16389
|
+
*/
|
|
16390
|
+
var DeliveryParamSchema = object({
|
|
16391
|
+
key: string().min(1),
|
|
16392
|
+
label: string(),
|
|
16393
|
+
/** i18n key of the label, resolved by the declaring addon's namespace. */
|
|
16394
|
+
labelKey: string().optional(),
|
|
16395
|
+
type: _enum([
|
|
16396
|
+
"enum",
|
|
16397
|
+
"number",
|
|
16398
|
+
"boolean",
|
|
16399
|
+
"string"
|
|
16400
|
+
]),
|
|
16401
|
+
/** `enum` only: the closed set of accepted values. */
|
|
16402
|
+
options: array(object({
|
|
16403
|
+
value: string(),
|
|
16404
|
+
label: string()
|
|
16405
|
+
})).optional(),
|
|
16406
|
+
/** `number` only. */
|
|
16407
|
+
min: number().optional(),
|
|
16408
|
+
max: number().optional(),
|
|
16409
|
+
/** What the notifier does when the rule sets nothing; shown as the placeholder. */
|
|
16410
|
+
default: DeliveryParamValueSchema.optional()
|
|
16411
|
+
});
|
|
16412
|
+
/**
|
|
16413
|
+
* The canonical notification. `body` is the only hard field (Apprise model).
|
|
16414
|
+
* `priority` is a 5-level ORDINAL (1=lowest … 3=normal(default) … 5=urgent),
|
|
16415
|
+
* NOT a fixed severity enum — each kind declares its own `caps.levels` and
|
|
16416
|
+
* the adapter maps this ordinal onto its native level. `level?` is an
|
|
16417
|
+
* optional kind-native level id (`emergency`, `silent`, …) that overrides
|
|
16418
|
+
* `priority` for that one target.
|
|
16419
|
+
*/
|
|
16420
|
+
var NotificationSchema = object({
|
|
16421
|
+
body: string(),
|
|
16422
|
+
title: string().optional(),
|
|
16423
|
+
format: NotificationFormatSchema.default("text"),
|
|
16424
|
+
priority: number().int().min(1).max(5).default(3),
|
|
16425
|
+
level: string().optional(),
|
|
16426
|
+
attachments: array(AttachmentSchema).optional(),
|
|
16427
|
+
clickUrl: string().optional(),
|
|
16428
|
+
actions: array(NotificationActionSchema).optional(),
|
|
16429
|
+
sound: string().optional(),
|
|
16430
|
+
ttl: number().optional(),
|
|
16431
|
+
tag: string().optional(),
|
|
16432
|
+
deviceId: number().optional(),
|
|
16433
|
+
eventId: string().optional(),
|
|
16434
|
+
metadata: record(string(), unknown()).optional(),
|
|
16435
|
+
/**
|
|
16436
|
+
* Values for the parameters the target's kind DECLARES in
|
|
16437
|
+
* {@link TargetKindSchema} `deliveryParams`. Already validated against the
|
|
16438
|
+
* declaration by the sender; a notifier reads only the keys it declared.
|
|
16439
|
+
*/
|
|
16440
|
+
delivery: record(string(), DeliveryParamValueSchema).optional()
|
|
16441
|
+
});
|
|
16442
|
+
/** One declared native severity/priority level for a kind. */
|
|
16443
|
+
var TargetKindLevelSchema = object({
|
|
16444
|
+
id: string(),
|
|
16445
|
+
label: string(),
|
|
16446
|
+
/** Which canonical priority (1..5) this level maps to. `null` = qualitative-only. */
|
|
16447
|
+
ordinal: number().int().min(1).max(5).nullable(),
|
|
16448
|
+
flags: object({
|
|
16449
|
+
critical: boolean().optional(),
|
|
16450
|
+
silent: boolean().optional(),
|
|
16451
|
+
noPush: boolean().optional()
|
|
16452
|
+
}).optional(),
|
|
16453
|
+
/** e.g. Pushover `emergency` requires `retry` / `expire`. */
|
|
16454
|
+
requires: array(string()).optional(),
|
|
16455
|
+
description: string().optional()
|
|
16456
|
+
});
|
|
16457
|
+
/** The full capability block consulted before dispatch. */
|
|
16458
|
+
var TargetKindCapsSchema = object({
|
|
16459
|
+
attachments: object({
|
|
16460
|
+
mediaTypes: array(AttachmentMediaTypeSchema),
|
|
16461
|
+
mode: _enum([
|
|
16462
|
+
"url",
|
|
16463
|
+
"bytes",
|
|
16464
|
+
"both"
|
|
16465
|
+
]),
|
|
16466
|
+
max: number().int().nonnegative(),
|
|
16467
|
+
maxBytes: number().int().positive().optional()
|
|
16468
|
+
}),
|
|
16469
|
+
/** Max action buttons (0 = none). */
|
|
16470
|
+
actions: number().int().nonnegative(),
|
|
16471
|
+
/**
|
|
16472
|
+
* Whether this kind renders a per-action ICON.
|
|
16473
|
+
*
|
|
16474
|
+
* `.optional()`, deliberately NOT `.default(false)`: a Zod default does not
|
|
16475
|
+
* run on the addon cap path — three production failures in one day taught
|
|
16476
|
+
* this repo that once. Absent is read as false by the degrade engine, which
|
|
16477
|
+
* is the safe direction: an icon that is not rendered costs nothing, an icon
|
|
16478
|
+
* assumed and dropped costs the operator's trust in the field.
|
|
16479
|
+
*/
|
|
16480
|
+
actionIcons: boolean().optional(),
|
|
16481
|
+
levels: array(TargetKindLevelSchema),
|
|
16482
|
+
format: array(NotificationFormatSchema),
|
|
16483
|
+
clickUrl: boolean(),
|
|
16484
|
+
sound: boolean(),
|
|
16485
|
+
ttl: boolean(),
|
|
16486
|
+
bodyMaxLen: number().int().positive()
|
|
16487
|
+
});
|
|
16488
|
+
/**
|
|
16489
|
+
* `configSchema` is a `ConfigUISchema` tree passed through to the admin
|
|
16490
|
+
* FormBuilder. Stored as `z.unknown()` at the cap seam (mirrors
|
|
16491
|
+
* `device-provider.getChildCreationSchema` `CreationSchemaOutputSchema`) —
|
|
16492
|
+
* the union is large and not meant for runtime validation here; the exported
|
|
16493
|
+
* `TargetKind` type re-tightens `configSchema` to `ConfigUISchema`.
|
|
16494
|
+
*/
|
|
16495
|
+
var ConfigSchemaPassthrough$3 = unknown();
|
|
16496
|
+
var TargetKindSchema = object({
|
|
16497
|
+
kind: string(),
|
|
16498
|
+
label: string(),
|
|
16499
|
+
icon: string(),
|
|
16500
|
+
/** Stamped by each provider so the concat-fanned catalog stays routable. */
|
|
16501
|
+
addonId: string(),
|
|
16502
|
+
/**
|
|
16503
|
+
* URL of the kind's bundled BRAND icon, served by the providing addon over
|
|
16504
|
+
* its own `addon-routes` surface (`/addon/<addonId>/icons/<kind>`). Absent
|
|
16505
|
+
* when the addon bundles no icon for that kind — the client then falls back
|
|
16506
|
+
* to a neutral glyph rather than rendering the raw `icon` NAME as text.
|
|
16507
|
+
*
|
|
16508
|
+
* Root-relative on purpose: it resolves against whatever origin serves a web
|
|
16509
|
+
* client, and a native client joins it onto its own hub base.
|
|
16510
|
+
*
|
|
16511
|
+
* DECLARED here deliberately. It used to travel as an undeclared passthrough
|
|
16512
|
+
* field that survived only because the runtime cap-router forwards provider
|
|
16513
|
+
* output verbatim — so every consumer had to re-declare it by hand to stop
|
|
16514
|
+
* its own Zod parse from stripping it, and the whole arrangement would have
|
|
16515
|
+
* broken silently the moment output validation was tightened anywhere.
|
|
16516
|
+
*/
|
|
16517
|
+
iconUrl: string().optional(),
|
|
16518
|
+
/**
|
|
16519
|
+
* Media type of {@link iconUrl} (`image/svg+xml`, `image/png`, …).
|
|
16520
|
+
*
|
|
16521
|
+
* The server knows this and therefore says it, because the client cannot
|
|
16522
|
+
* safely guess: a React-Native client renders SVG and raster through two
|
|
16523
|
+
* DIFFERENT components (`react-native-svg` vs `expo-image` — expo-image does
|
|
16524
|
+
* not decode SVG on iOS/Android), so without this it silently fell back to a
|
|
16525
|
+
* placeholder glyph for every vector icon while the web build looked fine.
|
|
16526
|
+
*
|
|
16527
|
+
* Absent when {@link iconUrl} is absent, or for a legacy provider that has
|
|
16528
|
+
* not been updated — a client that cannot determine the type should prefer
|
|
16529
|
+
* its raster path, which is the safe default for an unknown image.
|
|
16530
|
+
*/
|
|
16531
|
+
iconMediaType: string().optional(),
|
|
16532
|
+
configSchema: ConfigSchemaPassthrough$3,
|
|
16533
|
+
/**
|
|
16534
|
+
* The config keys that decide WHERE this kind's secrets are sent (server,
|
|
16535
|
+
* base URL, instance, chat, recipient). A save that changes any of them
|
|
16536
|
+
* while leaving a secret redacted is refused by the provider (D634), so an
|
|
16537
|
+
* editor uses this to ask for the secret on exactly those edits instead of
|
|
16538
|
+
* on every edit.
|
|
16539
|
+
*
|
|
16540
|
+
* Optional: absent from a provider that holds no secret (the Home Assistant
|
|
16541
|
+
* kinds) and from a provider older than this field — an editor that finds
|
|
16542
|
+
* it absent must assume ANY edit may need the secret.
|
|
16543
|
+
*/
|
|
16544
|
+
destinationKeys: array(string()).optional(),
|
|
16545
|
+
supportsDiscovery: boolean(),
|
|
16546
|
+
/**
|
|
16547
|
+
* Extra delivery parameters a rule may set for a target of this kind (D938).
|
|
16548
|
+
* Absent = none; the rule editor then offers nothing.
|
|
16549
|
+
*/
|
|
16550
|
+
deliveryParams: array(DeliveryParamSchema).optional(),
|
|
16551
|
+
caps: TargetKindCapsSchema
|
|
16552
|
+
});
|
|
16553
|
+
/**
|
|
16554
|
+
* A persisted target. `config` holds secrets; providers REDACT secret fields
|
|
16555
|
+
* (return a presence marker only) when serving `listTargets` — never
|
|
16556
|
+
* round-trip a stored secret to the UI.
|
|
16557
|
+
*/
|
|
16558
|
+
var TargetSchema = object({
|
|
16559
|
+
id: string(),
|
|
16560
|
+
name: string(),
|
|
16561
|
+
kind: string(),
|
|
16562
|
+
addonId: string(),
|
|
16563
|
+
enabled: boolean(),
|
|
16564
|
+
config: record(string(), unknown())
|
|
16565
|
+
});
|
|
16566
|
+
/** A discovery-surfaced candidate (config is partial + non-secret). */
|
|
16567
|
+
var DiscoveredTargetSchema = object({
|
|
16568
|
+
kind: string(),
|
|
16569
|
+
suggestedName: string(),
|
|
16570
|
+
config: record(string(), unknown())
|
|
16571
|
+
});
|
|
16572
|
+
/** The degrade engine's report — what was resolved / dropped / degraded. */
|
|
16573
|
+
var RenderedAsSchema = object({
|
|
16574
|
+
level: string(),
|
|
16575
|
+
format: NotificationFormatSchema,
|
|
16576
|
+
attachmentsSent: number().int().nonnegative(),
|
|
16577
|
+
actionsSent: number().int().nonnegative(),
|
|
16578
|
+
truncated: boolean(),
|
|
16579
|
+
dropped: array(string())
|
|
16580
|
+
});
|
|
16581
|
+
var SendResultSchema = object({
|
|
16582
|
+
success: boolean(),
|
|
16583
|
+
error: string().optional(),
|
|
16584
|
+
renderedAs: RenderedAsSchema.optional()
|
|
16585
|
+
});
|
|
16586
|
+
/** Same shape as SendResult — kept as a distinct name for the test panel. */
|
|
16587
|
+
var TestResultSchema = SendResultSchema;
|
|
16588
|
+
/**
|
|
16589
|
+
* Pre-save credential probe against a partial (unsaved) target config.
|
|
16590
|
+
* `resolvedUrl` never includes secrets (token stripped from path).
|
|
16591
|
+
*/
|
|
16592
|
+
var ProbeTargetConfigResultSchema = object({
|
|
16593
|
+
ok: boolean(),
|
|
16594
|
+
resolvedUrl: string(),
|
|
16595
|
+
httpStatus: number().int().optional(),
|
|
16596
|
+
stateInstance: string().optional(),
|
|
16597
|
+
error: string().optional()
|
|
16598
|
+
});
|
|
16599
|
+
method(object({}), array(TargetKindSchema)), method(object({}), array(TargetSchema), { auth: "admin" }), method(object({ targetId: string() }), TargetSchema, { auth: "admin" }), method(object({
|
|
16600
|
+
kind: string(),
|
|
16601
|
+
config: record(string(), unknown()).optional(),
|
|
16602
|
+
/**
|
|
16603
|
+
* When editing / duplicating, the blank password field never round-trips
|
|
16604
|
+
* the stored token. Pass the source target id so the provider can restore
|
|
16605
|
+
* secrets server-side before dialling (same merge as upsert).
|
|
16606
|
+
*/
|
|
16607
|
+
targetId: string().optional()
|
|
16608
|
+
}), array(DiscoveredTargetSchema), { auth: "admin" }), method(object({
|
|
16609
|
+
kind: string(),
|
|
16610
|
+
config: record(string(), unknown()),
|
|
16611
|
+
/** See `discoverTargets.targetId` — restore stored secrets for a blank password. */
|
|
16612
|
+
targetId: string().optional()
|
|
16613
|
+
}), ProbeTargetConfigResultSchema, {
|
|
16614
|
+
kind: "mutation",
|
|
16615
|
+
auth: "admin"
|
|
16616
|
+
}), method(object({
|
|
16617
|
+
targetId: string(),
|
|
16618
|
+
notification: NotificationSchema
|
|
16619
|
+
}), SendResultSchema, {
|
|
16620
|
+
kind: "mutation",
|
|
16621
|
+
auth: "admin"
|
|
16622
|
+
}), method(object({
|
|
16623
|
+
targetId: string(),
|
|
16624
|
+
sample: NotificationSchema.optional()
|
|
16625
|
+
}), TestResultSchema, {
|
|
16626
|
+
kind: "mutation",
|
|
16627
|
+
auth: "admin"
|
|
16628
|
+
}), method(object({
|
|
16629
|
+
target: TargetSchema,
|
|
16630
|
+
/**
|
|
16631
|
+
* Duplicate flow: create a NEW target id while copying secrets from an
|
|
16632
|
+
* existing row. The UI never holds the stored token; blank / redacted
|
|
16633
|
+
* password fields are restored from this source (D634 still applies if
|
|
16634
|
+
* destinations diverge without a re-typed secret).
|
|
16635
|
+
*/
|
|
16636
|
+
cloneSecretsFrom: string().optional()
|
|
16637
|
+
}), TargetSchema, {
|
|
16638
|
+
kind: "mutation",
|
|
16639
|
+
auth: "admin"
|
|
16640
|
+
}), method(object({ targetId: string() }), _void(), {
|
|
16641
|
+
kind: "mutation",
|
|
16642
|
+
auth: "admin"
|
|
16643
|
+
}), method(object({
|
|
16644
|
+
targetId: string(),
|
|
16645
|
+
enabled: boolean()
|
|
16646
|
+
}), _void(), {
|
|
16647
|
+
kind: "mutation",
|
|
16648
|
+
auth: "admin"
|
|
16649
|
+
});
|
|
16650
|
+
/**
|
|
16049
16651
|
* `addon-pages` — system-scoped singleton aggregator cap. Public-facing
|
|
16050
16652
|
* surface that admin-ui consumes through `useAddonPagesListPages()`.
|
|
16051
16653
|
*
|
|
@@ -16077,52 +16679,6 @@ var AddonPageInfoSchema = object({
|
|
|
16077
16679
|
bundleUrl: string()
|
|
16078
16680
|
});
|
|
16079
16681
|
method(_void(), array(AddonPageInfoSchema).readonly());
|
|
16080
|
-
/**
|
|
16081
|
-
* `addon-pages-source` — collection cap exposing per-provider raw page
|
|
16082
|
-
* declarations. Every addon that contributes a UI page registers a
|
|
16083
|
-
* provider here. The hub-side singleton aggregator (`addon-pages` cap,
|
|
16084
|
-
* see `addon-pages.cap.ts`) walks this collection, stamps versioned
|
|
16085
|
-
* `bundleUrl` values, and returns the enriched `AddonPageInfo[]` list
|
|
16086
|
-
* that admin-ui consumes.
|
|
16087
|
-
*
|
|
16088
|
-
* The split exists because the public listing has a different output
|
|
16089
|
-
* shape than the per-provider raw declarations, and we want both ends
|
|
16090
|
-
* to flow through codegen instead of relying on a hand-written wrapper.
|
|
16091
|
-
*/
|
|
16092
|
-
var AddonPageDeclarationSchema = object({
|
|
16093
|
-
id: string(),
|
|
16094
|
-
label: string(),
|
|
16095
|
-
icon: string(),
|
|
16096
|
-
path: string(),
|
|
16097
|
-
/**
|
|
16098
|
-
* Module Federation remote name — must match the `name` field on the
|
|
16099
|
-
* page addon's `federation()` plugin config. Used by admin-ui's
|
|
16100
|
-
* `<AddonPageLoader>` to call `loadRemote('<remoteName>/page')`.
|
|
16101
|
-
* Conventionally `addon_<id>_page` (snake_case; MF names cannot
|
|
16102
|
-
* contain hyphens).
|
|
16103
|
-
*/
|
|
16104
|
-
remoteName: string(),
|
|
16105
|
-
/**
|
|
16106
|
-
* Bundle filename inside the addon's `dist/` dir served at
|
|
16107
|
-
* `/api/addon-pages/<addonId>/<bundle>`. With Module Federation this
|
|
16108
|
-
* is always `'remoteEntry.js'`; the value is kept on the metadata so
|
|
16109
|
-
* the static-file route can compute an mtime-based cache-buster URL
|
|
16110
|
-
* without a separate filesystem stat.
|
|
16111
|
-
*/
|
|
16112
|
-
bundle: string(),
|
|
16113
|
-
/**
|
|
16114
|
-
* Sidebar section this page docks into. Well-known ids: `'detection'`,
|
|
16115
|
-
* `'cluster'`, `'administration'` — the page renders inside that group.
|
|
16116
|
-
* Any OTHER string creates (or joins) a custom section rendered after
|
|
16117
|
-
* the built-in groups; its label comes from `sectionLabel` (first
|
|
16118
|
-
* declaration wins), falling back to the id. Absent → the legacy
|
|
16119
|
-
* "Addon Pages" group.
|
|
16120
|
-
*/
|
|
16121
|
-
section: string().optional(),
|
|
16122
|
-
/** Display label for a CUSTOM `section` id (ignored for well-known ids). */
|
|
16123
|
-
sectionLabel: string().optional()
|
|
16124
|
-
});
|
|
16125
|
-
method(_void(), array(AddonPageDeclarationSchema).readonly(), { auth: "admin" });
|
|
16126
16682
|
var AddonHttpRouteSchema = object({
|
|
16127
16683
|
method: _enum([
|
|
16128
16684
|
"GET",
|
|
@@ -16423,9 +16979,21 @@ var AlertSeveritySchema = _enum([
|
|
|
16423
16979
|
"error",
|
|
16424
16980
|
"critical"
|
|
16425
16981
|
]);
|
|
16982
|
+
/**
|
|
16983
|
+
* An action that RUNS something instead of going somewhere: the admin UI calls
|
|
16984
|
+
* the addon's custom action (`addons.custom`) with exactly these fields. The
|
|
16985
|
+
* producer owns the meaning; the UI knows nothing about the addon or the kind.
|
|
16986
|
+
*/
|
|
16987
|
+
var AlertActionInvokeSchema = object({
|
|
16988
|
+
addonId: string().min(1),
|
|
16989
|
+
action: string().min(1),
|
|
16990
|
+
input: record(string(), unknown()).optional()
|
|
16991
|
+
});
|
|
16992
|
+
/** An action has `href` (a link) OR `invoke` (a button that runs a custom action). */
|
|
16426
16993
|
var AlertActionSchema = object({
|
|
16427
16994
|
label: string(),
|
|
16428
16995
|
href: string().optional(),
|
|
16996
|
+
invoke: AlertActionInvokeSchema.optional(),
|
|
16429
16997
|
/**
|
|
16430
16998
|
* How `href` is followed. Absent / `app`: an admin-ui route (client-side).
|
|
16431
16999
|
* `server`: a route the HUB serves (an addon HTTP route such as an OAuth
|
|
@@ -18672,7 +19240,11 @@ var CompositionProblemSchema = object({
|
|
|
18672
19240
|
"mixed-quantity",
|
|
18673
19241
|
"helper-mismatch",
|
|
18674
19242
|
"member-constraint",
|
|
18675
|
-
"retention"
|
|
19243
|
+
"retention",
|
|
19244
|
+
"command-method-unknown",
|
|
19245
|
+
"command-source-unknown",
|
|
19246
|
+
"command-input-unknown",
|
|
19247
|
+
"command-input-missing"
|
|
18676
19248
|
]),
|
|
18677
19249
|
path: string(),
|
|
18678
19250
|
message: string()
|
|
@@ -18711,7 +19283,9 @@ var CompositionFieldRoleSchema = _enum([
|
|
|
18711
19283
|
var CompositionFieldItemSchema = object({
|
|
18712
19284
|
arrayPath: string(),
|
|
18713
19285
|
key: string(),
|
|
18714
|
-
label: string()
|
|
19286
|
+
label: string(),
|
|
19287
|
+
/** True when the item carries a `reset` forward: the composer writes `resettable` from this (D967). */
|
|
19288
|
+
resettable: boolean().optional()
|
|
18715
19289
|
});
|
|
18716
19290
|
var CompositionFieldPlanSchema = object({
|
|
18717
19291
|
cap: string(),
|
|
@@ -18916,7 +19490,7 @@ Object.freeze({
|
|
|
18916
19490
|
* One catalog row per base reading a group helper can build (D944 §3).
|
|
18917
19491
|
* Data, not a form default written into the block.
|
|
18918
19492
|
*/
|
|
18919
|
-
var NOW$
|
|
19493
|
+
var NOW$3 = {
|
|
18920
19494
|
fieldPath: "lastFetchedAt",
|
|
18921
19495
|
expr: "now"
|
|
18922
19496
|
};
|
|
@@ -18925,12 +19499,13 @@ var CHANGED = {
|
|
|
18925
19499
|
expr: "now"
|
|
18926
19500
|
};
|
|
18927
19501
|
function numeric(input) {
|
|
19502
|
+
const { alsoFrom, ...base } = input;
|
|
18928
19503
|
return {
|
|
18929
|
-
...
|
|
19504
|
+
...base,
|
|
18930
19505
|
family: "numeric",
|
|
18931
19506
|
deviceType: DeviceType.Sensor,
|
|
18932
19507
|
memberDeviceType: DeviceType.Sensor,
|
|
18933
|
-
memberDeviceTypes: [DeviceType.Sensor],
|
|
19508
|
+
memberDeviceTypes: [DeviceType.Sensor, ...alsoFrom?.deviceTypes ?? []],
|
|
18934
19509
|
activeWhen: void 0,
|
|
18935
19510
|
commandCaps: [],
|
|
18936
19511
|
baseUnit: baseUnitOf(input.quantity),
|
|
@@ -18938,9 +19513,10 @@ function numeric(input) {
|
|
|
18938
19513
|
accept: [{
|
|
18939
19514
|
cap: input.outputCap,
|
|
18940
19515
|
fieldPath: input.outputField
|
|
18941
|
-
}]
|
|
19516
|
+
}, ...alsoFrom === void 0 ? [] : [alsoFrom.accept]]
|
|
18942
19517
|
};
|
|
18943
19518
|
}
|
|
19519
|
+
var CLIMATE_DEVICES = [DeviceType.Thermostat, DeviceType.Climate];
|
|
18944
19520
|
function binary(input) {
|
|
18945
19521
|
return {
|
|
18946
19522
|
...input,
|
|
@@ -18966,7 +19542,14 @@ var GROUP_TEMPLATES = [
|
|
|
18966
19542
|
quantity: "temperature",
|
|
18967
19543
|
defaultAggregate: "mean",
|
|
18968
19544
|
empty: "null",
|
|
18969
|
-
companions: [NOW$
|
|
19545
|
+
companions: [NOW$3],
|
|
19546
|
+
alsoFrom: {
|
|
19547
|
+
deviceTypes: CLIMATE_DEVICES,
|
|
19548
|
+
accept: {
|
|
19549
|
+
cap: "climate-control",
|
|
19550
|
+
fieldPath: "currentTemp"
|
|
19551
|
+
}
|
|
19552
|
+
}
|
|
18970
19553
|
}),
|
|
18971
19554
|
numeric({
|
|
18972
19555
|
id: "humidity",
|
|
@@ -18977,7 +19560,14 @@ var GROUP_TEMPLATES = [
|
|
|
18977
19560
|
quantity: "humidity",
|
|
18978
19561
|
defaultAggregate: "mean",
|
|
18979
19562
|
empty: "null",
|
|
18980
|
-
companions: [NOW$
|
|
19563
|
+
companions: [NOW$3],
|
|
19564
|
+
alsoFrom: {
|
|
19565
|
+
deviceTypes: CLIMATE_DEVICES,
|
|
19566
|
+
accept: {
|
|
19567
|
+
cap: "climate-control",
|
|
19568
|
+
fieldPath: "currentHumidity"
|
|
19569
|
+
}
|
|
19570
|
+
}
|
|
18981
19571
|
}),
|
|
18982
19572
|
numeric({
|
|
18983
19573
|
id: "pressure",
|
|
@@ -18988,7 +19578,7 @@ var GROUP_TEMPLATES = [
|
|
|
18988
19578
|
quantity: "pressure",
|
|
18989
19579
|
defaultAggregate: "mean",
|
|
18990
19580
|
empty: "null",
|
|
18991
|
-
companions: [NOW$
|
|
19581
|
+
companions: [NOW$3]
|
|
18992
19582
|
}),
|
|
18993
19583
|
numeric({
|
|
18994
19584
|
id: "illuminance",
|
|
@@ -18999,7 +19589,7 @@ var GROUP_TEMPLATES = [
|
|
|
18999
19589
|
quantity: "illuminance",
|
|
19000
19590
|
defaultAggregate: "mean",
|
|
19001
19591
|
empty: "null",
|
|
19002
|
-
companions: [NOW$
|
|
19592
|
+
companions: [NOW$3]
|
|
19003
19593
|
}),
|
|
19004
19594
|
numeric({
|
|
19005
19595
|
id: "power",
|
|
@@ -19010,7 +19600,7 @@ var GROUP_TEMPLATES = [
|
|
|
19010
19600
|
quantity: "power",
|
|
19011
19601
|
defaultAggregate: "sum",
|
|
19012
19602
|
empty: "omit",
|
|
19013
|
-
companions: [NOW$
|
|
19603
|
+
companions: [NOW$3]
|
|
19014
19604
|
}),
|
|
19015
19605
|
numeric({
|
|
19016
19606
|
id: "energy",
|
|
@@ -19021,7 +19611,7 @@ var GROUP_TEMPLATES = [
|
|
|
19021
19611
|
quantity: "energy",
|
|
19022
19612
|
defaultAggregate: "sum",
|
|
19023
19613
|
empty: "omit",
|
|
19024
|
-
companions: [NOW$
|
|
19614
|
+
companions: [NOW$3]
|
|
19025
19615
|
}),
|
|
19026
19616
|
numeric({
|
|
19027
19617
|
id: "battery",
|
|
@@ -19056,7 +19646,7 @@ var GROUP_TEMPLATES = [
|
|
|
19056
19646
|
quantity: "device",
|
|
19057
19647
|
defaultAggregate: "mean",
|
|
19058
19648
|
empty: "null",
|
|
19059
|
-
companions: [NOW$
|
|
19649
|
+
companions: [NOW$3]
|
|
19060
19650
|
}),
|
|
19061
19651
|
binary({
|
|
19062
19652
|
id: "motion",
|
|
@@ -21402,6 +21992,36 @@ var ExposeInputSchema = object({
|
|
|
21402
21992
|
capabilities: array(string()).optional()
|
|
21403
21993
|
});
|
|
21404
21994
|
var UnexposeInputSchema = object({ deviceId: string() });
|
|
21995
|
+
/**
|
|
21996
|
+
* What an exporter may expose besides devices (D968). An action and a
|
|
21997
|
+
* notification target are LIST ENTRIES, never devices (D954): they enter an
|
|
21998
|
+
* exporter's own selection, not the device registry.
|
|
21999
|
+
*/
|
|
22000
|
+
var ExportEntityKindSchema = _enum([
|
|
22001
|
+
"device",
|
|
22002
|
+
"action",
|
|
22003
|
+
"notifier"
|
|
22004
|
+
]);
|
|
22005
|
+
var ExportEntityRefSchema = discriminatedUnion("kind", [
|
|
22006
|
+
object({
|
|
22007
|
+
kind: literal("device"),
|
|
22008
|
+
deviceId: string()
|
|
22009
|
+
}),
|
|
22010
|
+
object({
|
|
22011
|
+
kind: literal("action"),
|
|
22012
|
+
actionId: string().min(1)
|
|
22013
|
+
}),
|
|
22014
|
+
object({
|
|
22015
|
+
kind: literal("notifier"),
|
|
22016
|
+
targetId: string().min(1)
|
|
22017
|
+
})
|
|
22018
|
+
]);
|
|
22019
|
+
var ExposedEntitySchema = object({
|
|
22020
|
+
entity: ExportEntityRefSchema,
|
|
22021
|
+
exposedAs: string().optional()
|
|
22022
|
+
});
|
|
22023
|
+
var ExposeEntityInputSchema = object({ entity: ExportEntityRefSchema });
|
|
22024
|
+
var UnexposeEntityInputSchema = object({ entity: ExportEntityRefSchema });
|
|
21405
22025
|
var deviceExportCapability = {
|
|
21406
22026
|
name: "device-export",
|
|
21407
22027
|
scope: "system",
|
|
@@ -21431,6 +22051,16 @@ var deviceExportCapability = {
|
|
|
21431
22051
|
unexposeDevice: method(UnexposeInputSchema, _void(), {
|
|
21432
22052
|
kind: "mutation",
|
|
21433
22053
|
auth: "admin"
|
|
22054
|
+
}),
|
|
22055
|
+
listSupportedEntityKinds: optionalMethod(_void(), array(ExportEntityKindSchema)),
|
|
22056
|
+
listExposedEntities: optionalMethod(_void(), array(ExposedEntitySchema)),
|
|
22057
|
+
exposeEntity: optionalMethod(ExposeEntityInputSchema, _void(), {
|
|
22058
|
+
kind: "mutation",
|
|
22059
|
+
auth: "admin"
|
|
22060
|
+
}),
|
|
22061
|
+
unexposeEntity: optionalMethod(UnexposeEntityInputSchema, _void(), {
|
|
22062
|
+
kind: "mutation",
|
|
22063
|
+
auth: "admin"
|
|
21434
22064
|
})
|
|
21435
22065
|
}
|
|
21436
22066
|
};
|
|
@@ -42573,6 +43203,14 @@ method(object({
|
|
|
42573
43203
|
kind: "mutation",
|
|
42574
43204
|
auth: "admin"
|
|
42575
43205
|
});
|
|
43206
|
+
method(object({
|
|
43207
|
+
nodeId: string().min(1),
|
|
43208
|
+
/** Epoch ms the node was forgotten (the tombstone's `removedAt`). */
|
|
43209
|
+
removedAt: number()
|
|
43210
|
+
}), object({ counts: record(string(), number().int().nonnegative()) }), {
|
|
43211
|
+
kind: "mutation",
|
|
43212
|
+
auth: "admin"
|
|
43213
|
+
});
|
|
42576
43214
|
/**
|
|
42577
43215
|
* `device-removal-hook` — the reliable way an addon learns a device was DELETED,
|
|
42578
43216
|
* so it can delete what it keeps for that device (D865).
|
|
@@ -43220,6 +43858,17 @@ var LlmProfileSchema = object({
|
|
|
43220
43858
|
* field in its editor only when its descriptor lists it in `profileFields`. */
|
|
43221
43859
|
topK: number().int().positive().optional(),
|
|
43222
43860
|
maxTokens: number().int().positive().optional(),
|
|
43861
|
+
/** How hard the model "thinks" before it answers. Omitted = the model's own
|
|
43862
|
+
* default. `off` matters for structured output: a thinking model can spend
|
|
43863
|
+
* the whole completion on reasoning and return an empty `content`. Carried
|
|
43864
|
+
* only by the wires that have it — a kind offers the field in its editor
|
|
43865
|
+
* only when its descriptor lists it in `profileFields`. */
|
|
43866
|
+
reasoningEffort: _enum([
|
|
43867
|
+
"off",
|
|
43868
|
+
"low",
|
|
43869
|
+
"medium",
|
|
43870
|
+
"high"
|
|
43871
|
+
]).optional(),
|
|
43223
43872
|
/** Prompt context window. Advisory for cloud kinds (they enforce their own). */
|
|
43224
43873
|
contextLength: number().int().positive().optional(),
|
|
43225
43874
|
/** Default system prompt. A caller's `system` REPLACES it (never appends —
|
|
@@ -43258,6 +43907,7 @@ var LlmProfileFieldSchema = _enum([
|
|
|
43258
43907
|
"topP",
|
|
43259
43908
|
"topK",
|
|
43260
43909
|
"maxTokens",
|
|
43910
|
+
"reasoningEffort",
|
|
43261
43911
|
"contextLength",
|
|
43262
43912
|
"systemPrompt",
|
|
43263
43913
|
"timeoutMs",
|
|
@@ -43281,7 +43931,7 @@ var LlmProviderWidgetSchema = object({
|
|
|
43281
43931
|
/** ConfigUISchema tree passed through untyped on the wire (the
|
|
43282
43932
|
* notification-output `ConfigSchemaPassthrough` precedent at
|
|
43283
43933
|
* notification-output.cap.ts:151); the exported TS type re-tightens it. */
|
|
43284
|
-
var ConfigSchemaPassthrough$
|
|
43934
|
+
var ConfigSchemaPassthrough$2 = unknown();
|
|
43285
43935
|
var LlmProfileKindDescriptorSchema = object({
|
|
43286
43936
|
kind: LlmProfileKindSchema,
|
|
43287
43937
|
label: string(),
|
|
@@ -43290,9 +43940,9 @@ var LlmProfileKindDescriptorSchema = object({
|
|
|
43290
43940
|
/** Stamped by each provider so the concat-fanned catalog stays routable. */
|
|
43291
43941
|
addonId: string(),
|
|
43292
43942
|
/** The provider's own fields (`providerConfig`); `password` fields are keychain-held. */
|
|
43293
|
-
connectionSchema: ConfigSchemaPassthrough$
|
|
43943
|
+
connectionSchema: ConfigSchemaPassthrough$2,
|
|
43294
43944
|
/** Provider fields that belong under "Advanced" (extra headers, runtime tuning). */
|
|
43295
|
-
advancedSchema: ConfigSchemaPassthrough$
|
|
43945
|
+
advancedSchema: ConfigSchemaPassthrough$2.optional(),
|
|
43296
43946
|
/** The kind's defaults; a model from `listModels` may override any of them. */
|
|
43297
43947
|
features: LlmModelFeaturesSchema,
|
|
43298
43948
|
/** `false` = the provider stamps `supportsVision` itself (from what a node reports). */
|
|
@@ -43818,10 +44468,10 @@ var CpuBreakdownSchema = object({
|
|
|
43818
44468
|
cores: number()
|
|
43819
44469
|
});
|
|
43820
44470
|
var MemoryInfoSchema = object({
|
|
43821
|
-
percent: number(),
|
|
44471
|
+
percent: number().nullable(),
|
|
43822
44472
|
totalBytes: number(),
|
|
43823
|
-
usedBytes: number(),
|
|
43824
|
-
availableBytes: number(),
|
|
44473
|
+
usedBytes: number().nullable(),
|
|
44474
|
+
availableBytes: number().nullable(),
|
|
43825
44475
|
swapUsedBytes: number(),
|
|
43826
44476
|
swapTotalBytes: number()
|
|
43827
44477
|
});
|
|
@@ -44089,652 +44739,280 @@ var NodeLoadSeriesSchema = object({
|
|
|
44089
44739
|
/** The fixed sampling cadence in force on the cluster, in ms. */
|
|
44090
44740
|
cadenceMs: number(),
|
|
44091
44741
|
/**
|
|
44092
|
-
* Did the DURABLE tier contribute? `false` means the answer is the hot ring
|
|
44093
|
-
* alone — an agent (which holds no table), or a store that refused.
|
|
44094
|
-
* Reported because "the last hour" and "the last six hours" are different
|
|
44095
|
-
* questions and an operator must not have to guess which was answered.
|
|
44096
|
-
*/
|
|
44097
|
-
durable: boolean()
|
|
44098
|
-
});
|
|
44099
|
-
var GetLoadSeriesInputSchema = object({
|
|
44100
|
-
/**
|
|
44101
|
-
* The node whose series is wanted.
|
|
44102
|
-
*
|
|
44103
|
-
* NOT named `nodeId`: the generated cap router strips a top-level
|
|
44104
|
-
* `nodeId` from every method input and uses it to ROUTE the call to
|
|
44105
|
-
* that node's provider (`generated-cap-routers.ts`). A series target
|
|
44106
|
-
* called `nodeId` would silently become a routing pin and never reach
|
|
44107
|
-
* the provider. The hub holds every node it hears from, so the
|
|
44108
|
-
* ordinary call is unpinned — answered by the hub, for any node.
|
|
44109
|
-
*/
|
|
44110
|
-
forNodeId: string(),
|
|
44111
|
-
/**
|
|
44112
|
-
* EXCLUSIVE lower bound. A caller passes the newest `atMs` it already
|
|
44113
|
-
* holds and receives only what it is missing, so seeding a live chart
|
|
44114
|
-
* from this method cannot double a point already drawn.
|
|
44115
|
-
*/
|
|
44116
|
-
sinceMs: number().optional(),
|
|
44117
|
-
/**
|
|
44118
|
-
* Most points the caller wants PER FUNCTION. The window is reduced to fit,
|
|
44119
|
-
* preserving min and max per bucket.
|
|
44120
|
-
*
|
|
44121
|
-
* Absent means NO reduction — legitimate for a short window and a trap for a
|
|
44122
|
-
* long one, which is why a chart passes its own pixel width.
|
|
44123
|
-
*/
|
|
44124
|
-
maxPoints: number().int().positive().optional()
|
|
44125
|
-
});
|
|
44126
|
-
var SystemMetricsSchema = object({
|
|
44127
|
-
cpuPercent: number(),
|
|
44128
|
-
memoryPercent: number(),
|
|
44129
|
-
memoryUsedMB: number(),
|
|
44130
|
-
memoryTotalMB: number(),
|
|
44131
|
-
diskPercent: number().optional(),
|
|
44132
|
-
temperature: number().optional(),
|
|
44133
|
-
gpuPercent: number().optional(),
|
|
44134
|
-
gpuMemoryPercent: number().optional()
|
|
44135
|
-
});
|
|
44136
|
-
method(_void(), SystemResourceSnapshotSchema), method(_void(), SystemResourceSnapshotSchema.nullable()), method(_void(), SystemMetricsSchema), method(object({ dirPath: string() }), DiskSpaceInfoSchema), method(_void(), MetricsGpuInfoSchema.nullable()), method(_void(), number().nullable()), method(object({ pids: array(number()) }), array(PidResourceStatsSchema)), method(_void(), array(AddonInstanceSchema).readonly()), method(object({ addonId: string() }), PidResourceStatsSchema.nullable()), method(_void(), array(NodeProcessSchema).readonly()), method(GetLoadSeriesInputSchema, NodeLoadSeriesSchema);
|
|
44137
|
-
method(object({
|
|
44138
|
-
sourceUrl: string(),
|
|
44139
|
-
metadata: ModelConvertMetadataSchema,
|
|
44140
|
-
targets: array(ConvertTargetSchema).min(1).readonly(),
|
|
44141
|
-
calibrationRef: string().optional(),
|
|
44142
|
-
sessionId: string().optional()
|
|
44143
|
-
}), ConvertResultSchema, {
|
|
44144
|
-
kind: "mutation",
|
|
44145
|
-
auth: "admin",
|
|
44146
|
-
timeoutMs: 6e5
|
|
44147
|
-
});
|
|
44148
|
-
method(object({
|
|
44149
|
-
targetNodeId: string(),
|
|
44150
|
-
modelId: string(),
|
|
44151
|
-
format: _enum(MODEL_FORMATS),
|
|
44152
|
-
entry: ModelCatalogEntrySchema
|
|
44153
|
-
}), object({
|
|
44154
|
-
ok: boolean(),
|
|
44155
|
-
/** sha256 of the staged tarball (empty for a hub-local no-op). */
|
|
44156
|
-
sha256: string(),
|
|
44157
|
-
bytes: number(),
|
|
44158
|
-
/** The target node's modelsDir the artifact landed in. */
|
|
44159
|
-
path: string()
|
|
44160
|
-
}), {
|
|
44161
|
-
kind: "mutation",
|
|
44162
|
-
auth: "admin"
|
|
44163
|
-
});
|
|
44164
|
-
var MotionRegionSchema = object({
|
|
44165
|
-
bbox: BoundingBoxSchema,
|
|
44166
|
-
pixelCount: number(),
|
|
44167
|
-
intensity: number()
|
|
44168
|
-
});
|
|
44169
|
-
var MotionAnalysisResultSchema = object({
|
|
44170
|
-
detected: boolean(),
|
|
44171
|
-
regionCount: number(),
|
|
44172
|
-
/** Regions passing minArea filter — used for pipeline triggering. */
|
|
44173
|
-
regions: array(MotionRegionSchema).readonly(),
|
|
44174
|
-
/** All raw regions from CCL before minArea filter — used for UI debug overlay. */
|
|
44175
|
-
rawRegions: array(MotionRegionSchema).readonly(),
|
|
44176
|
-
frameWidth: number(),
|
|
44177
|
-
frameHeight: number(),
|
|
44178
|
-
analysisMs: number()
|
|
44179
|
-
});
|
|
44180
|
-
DeviceType.Camera, method(object({
|
|
44181
|
-
deviceId: number(),
|
|
44182
|
-
frame: FrameInputSchema.optional(),
|
|
44183
|
-
frameHandle: FrameHandleSchema.optional()
|
|
44184
|
-
}), MotionAnalysisResultSchema, {
|
|
44185
|
-
role: "admin",
|
|
44186
|
-
kind: "mutation"
|
|
44187
|
-
}), method(object({ deviceId: number() }), _void(), {
|
|
44188
|
-
role: "admin",
|
|
44189
|
-
kind: "mutation"
|
|
44190
|
-
}), method(_void(), _void(), {
|
|
44191
|
-
role: "admin",
|
|
44192
|
-
kind: "mutation"
|
|
44193
|
-
}), object({
|
|
44194
|
-
deviceId: number(),
|
|
44195
|
-
detected: boolean(),
|
|
44196
|
-
regionCount: number()
|
|
44197
|
-
});
|
|
44198
|
-
/**
|
|
44199
|
-
* `mqtt-broker` — broker-registry cap.
|
|
44200
|
-
*
|
|
44201
|
-
* NOT a pub/sub proxy. The cap exposes (a) a registry of configured
|
|
44202
|
-
* MQTT brokers (external + optionally an embedded `aedes`-backed one)
|
|
44203
|
-
* and (b) the connection details a consumer addon needs to spin up
|
|
44204
|
-
* its OWN `mqtt.js` client.
|
|
44205
|
-
*
|
|
44206
|
-
* Why: pub/sub routing over the system event-bus loses fidelity
|
|
44207
|
-
* (callback shape, QoS guarantees, will/retain semantics) and adds
|
|
44208
|
-
* refcount bookkeeping that addons would rather own themselves. The
|
|
44209
|
-
* canonical consumer needs raw `mqtt.js`
|
|
44210
|
-
* features anyway — give it the connection config, get out of the way.
|
|
44211
|
-
*
|
|
44212
|
-
* Consumer flow:
|
|
44213
|
-
* const cfg = await ctx.api.mqttBroker.getBrokerConfig({ id })
|
|
44214
|
-
* const client = mqtt.connect(cfg.url, { username: cfg.username, … })
|
|
44215
|
-
* client.subscribe('zigbee2mqtt/+')
|
|
44216
|
-
*
|
|
44217
|
-
* Collection mode: multiple brokers (e.g. one local mosquitto + one
|
|
44218
|
-
* cloud bridge). The "embedded" entry (when present) is just another
|
|
44219
|
-
* broker in the registry — its lifecycle is owned by the addon that
|
|
44220
|
-
* spawned it.
|
|
44221
|
-
*/
|
|
44222
|
-
var BrokerKindSchema = _enum(["external", "embedded"]);
|
|
44223
|
-
/**
|
|
44224
|
-
* Broker live-probe status.
|
|
44225
|
-
*
|
|
44226
|
-
* - `connected` — last probe completed a clean CONNACK
|
|
44227
|
-
* - `disconnected` — no probe has run yet (cold cache)
|
|
44228
|
-
* - `auth-failed` — CONNACK refused with auth error (RC 4 / 5)
|
|
44229
|
-
* - `unreachable` — TCP connect timed out / refused
|
|
44230
|
-
* - `tls-error` — TLS handshake failed (cert / SNI / cipher)
|
|
44231
|
-
*/
|
|
44232
|
-
var BrokerStatusSchema$1 = _enum([
|
|
44233
|
-
"connected",
|
|
44234
|
-
"disconnected",
|
|
44235
|
-
"auth-failed",
|
|
44236
|
-
"unreachable",
|
|
44237
|
-
"tls-error"
|
|
44238
|
-
]);
|
|
44239
|
-
var BrokerInfoSchema$1 = object({
|
|
44240
|
-
id: string(),
|
|
44241
|
-
name: string(),
|
|
44242
|
-
url: string(),
|
|
44243
|
-
kind: BrokerKindSchema,
|
|
44244
|
-
status: BrokerStatusSchema$1,
|
|
44245
|
-
latencyMs: number().nullable(),
|
|
44246
|
-
error: string().optional(),
|
|
44247
|
-
/** Embedded brokers only: number of MQTT clients currently connected. */
|
|
44248
|
-
connectedClients: number().int().nonnegative().optional(),
|
|
44249
|
-
/** Epoch ms of the last live probe (external) or aedes snapshot (embedded). */
|
|
44250
|
-
lastCheckedAt: number().optional()
|
|
44251
|
-
});
|
|
44252
|
-
/**
|
|
44253
|
-
* Connection details — what a consumer needs to call
|
|
44254
|
-
* `mqtt.connect(url, options)`. We split URL + credentials so the
|
|
44255
|
-
* consumer can pass them as `mqtt.connect(url, { username, password })`
|
|
44256
|
-
* instead of stuffing creds into the URL (which leaks them into logs).
|
|
44257
|
-
*/
|
|
44258
|
-
var BrokerConnectionDetailsSchema = object({
|
|
44259
|
-
url: string(),
|
|
44260
|
-
username: string().optional(),
|
|
44261
|
-
password: string().optional(),
|
|
44262
|
-
/**
|
|
44263
|
-
* Suggested prefix for `clientId`. Each consumer should suffix this
|
|
44264
|
-
* with its own discriminator (addon id, instance id) so reconnects
|
|
44265
|
-
* don't kick each other off (MQTT spec: clientId must be unique per
|
|
44266
|
-
* broker).
|
|
44267
|
-
*/
|
|
44268
|
-
clientIdPrefix: string().optional()
|
|
44269
|
-
});
|
|
44270
|
-
var AddBrokerInputSchema = object({
|
|
44271
|
-
name: string().min(1),
|
|
44272
|
-
url: string().regex(/^(mqtt|mqtts|ws|wss):\/\//, "URL must start with mqtt(s):// or ws(s)://"),
|
|
44273
|
-
username: string().optional(),
|
|
44274
|
-
password: string().optional(),
|
|
44275
|
-
clientIdPrefix: string().optional()
|
|
44276
|
-
});
|
|
44277
|
-
var AddBrokerResultSchema = object({ id: string() });
|
|
44278
|
-
var IdInputSchema = object({ id: string() });
|
|
44279
|
-
var TestResultSchema$1 = discriminatedUnion("ok", [object({
|
|
44280
|
-
ok: literal(true),
|
|
44281
|
-
latencyMs: number()
|
|
44282
|
-
}), object({
|
|
44283
|
-
ok: literal(false),
|
|
44284
|
-
error: string()
|
|
44285
|
-
})]);
|
|
44286
|
-
var StartEmbeddedInputSchema = object({
|
|
44287
|
-
port: number().int().min(1).max(65535).default(1883),
|
|
44288
|
-
/** Allow anonymous connect (no username/password). Default: false. */
|
|
44289
|
-
allowAnonymous: boolean().default(false),
|
|
44290
|
-
/** Optional shared username/password for clients. */
|
|
44291
|
-
username: string().optional(),
|
|
44292
|
-
password: string().optional()
|
|
44293
|
-
});
|
|
44294
|
-
var StartEmbeddedResultSchema = object({
|
|
44295
|
-
id: string(),
|
|
44296
|
-
url: string()
|
|
44297
|
-
});
|
|
44298
|
-
var StatusSchema = object({
|
|
44299
|
-
brokerCount: number(),
|
|
44300
|
-
embeddedRunning: boolean()
|
|
44301
|
-
});
|
|
44302
|
-
method(_void(), array(BrokerInfoSchema$1)), method(IdInputSchema, BrokerConnectionDetailsSchema, { auth: "admin" }), method(AddBrokerInputSchema, AddBrokerResultSchema, {
|
|
44303
|
-
kind: "mutation",
|
|
44304
|
-
auth: "admin"
|
|
44305
|
-
}), method(IdInputSchema, _void(), {
|
|
44306
|
-
kind: "mutation",
|
|
44307
|
-
auth: "admin"
|
|
44308
|
-
}), method(IdInputSchema, TestResultSchema$1, {
|
|
44309
|
-
kind: "mutation",
|
|
44310
|
-
auth: "admin"
|
|
44311
|
-
}), method(StartEmbeddedInputSchema, StartEmbeddedResultSchema, {
|
|
44312
|
-
kind: "mutation",
|
|
44313
|
-
auth: "admin"
|
|
44314
|
-
}), method(IdInputSchema, _void(), {
|
|
44315
|
-
kind: "mutation",
|
|
44316
|
-
auth: "admin"
|
|
44317
|
-
}), method(_void(), StatusSchema);
|
|
44318
|
-
var NetworkEndpointSchema = object({
|
|
44319
|
-
url: string(),
|
|
44320
|
-
hostname: string(),
|
|
44321
|
-
port: number(),
|
|
44322
|
-
protocol: _enum(["http", "https"]),
|
|
44323
|
-
/**
|
|
44324
|
-
* Whether this address survives a restart of its provider. `false` = it is
|
|
44325
|
-
* re-issued every time (a Quick tunnel's random `*.trycloudflare.com`); the
|
|
44326
|
-
* hub never selects such an address AUTOMATICALLY for a role (D860), though
|
|
44327
|
-
* it stays visible and an operator may still flag it. Absent = stable: every
|
|
44328
|
-
* provider except a Quick tunnel owns a name that does not change.
|
|
44329
|
-
*/
|
|
44330
|
-
stable: boolean().optional()
|
|
44331
|
-
});
|
|
44332
|
-
object({
|
|
44333
|
-
url: string(),
|
|
44334
|
-
/** Mirrors {@link NetworkEndpointSchema} `stable`; absent = stable. */
|
|
44335
|
-
stable: boolean().optional(),
|
|
44336
|
-
updated: boolean().optional()
|
|
44337
|
-
});
|
|
44338
|
-
var NetworkAccessStatusSchema = object({
|
|
44339
|
-
connected: boolean(),
|
|
44340
|
-
endpoint: NetworkEndpointSchema.nullable(),
|
|
44341
|
-
error: string().optional()
|
|
44342
|
-
});
|
|
44343
|
-
/**
|
|
44344
|
-
* Optional, richer endpoint shape returned by providers that expose
|
|
44345
|
-
* MORE than one ingress concurrently (Tailscale Funnel with mixed
|
|
44346
|
-
* serve+funnel rules, future ngrok multi-tunnel, …). Each entry carries
|
|
44347
|
-
* the originating provider config (mode + sourcePort) so the
|
|
44348
|
-
* orchestrator UI can label rows distinctly. Providers that expose only
|
|
44349
|
-
* one endpoint just omit `listEndpoints` from their provider impl.
|
|
44350
|
-
*/
|
|
44351
|
-
var NetworkEndpointEntrySchema = NetworkEndpointSchema.extend({
|
|
44352
|
-
/**
|
|
44353
|
-
* Stable id within the provider — typically `<mode>-<sourcePort>` so
|
|
44354
|
-
* the orchestrator can dedupe across `listEndpoints` polls.
|
|
44355
|
-
*/
|
|
44356
|
-
id: string(),
|
|
44357
|
-
/** Operator-facing label (mirrors `MeshEndpoint.label`). */
|
|
44358
|
-
label: string(),
|
|
44359
|
-
/** Optional provider-specific mode tag, used for icon/colour in admin UI. */
|
|
44360
|
-
mode: string().optional(),
|
|
44361
|
-
/** Originating local port the ingress fronts (informational). */
|
|
44362
|
-
sourcePort: number().optional()
|
|
44363
|
-
});
|
|
44364
|
-
method(_void(), NetworkEndpointSchema, { kind: "mutation" }), method(_void(), _void(), { kind: "mutation" }), method(_void(), NetworkEndpointSchema.nullable()), method(_void(), NetworkAccessStatusSchema), method(_void(), array(NetworkEndpointEntrySchema).readonly());
|
|
44365
|
-
/**
|
|
44366
|
-
* notification-output — canonical, capability-gated notification delivery.
|
|
44367
|
-
*
|
|
44368
|
-
* Apprise-derived model (see
|
|
44369
|
-
* `docs/superpowers/specs/2026-07-03-notification-output-notifier-matrix.md`):
|
|
44370
|
-
* callers emit ONE canonical `Notification`; each provider declares a
|
|
44371
|
-
* per-kind capability descriptor (`TargetKind`), and the pure degrade
|
|
44372
|
-
* engine (`@camstack/types` `prepareNotification`) transcodes / degrades the
|
|
44373
|
-
* message to what the kind supports — callers never special-case a service.
|
|
44374
|
-
*
|
|
44375
|
-
* DESIGN DECISIONS (locked):
|
|
44376
|
-
* - Target CRUD lives on THIS cap (`upsertTarget` / `deleteTarget` /
|
|
44377
|
-
* `setTargetEnabled`), each provider persisting via the `settings-store`
|
|
44378
|
-
* cap. Rationale: the admin UI needs one uniform surface across the
|
|
44379
|
-
* notifiers addon AND the HA addon; the addon-`globalSettingsSchema`-array
|
|
44380
|
-
* alternative would fork the UI per addon and cannot host the
|
|
44381
|
-
* discovery→adopt flow.
|
|
44382
|
-
* - `listTargetKinds` / `listTargets` / `discoverTargets` return arrays →
|
|
44383
|
-
* the generated cap-mount auto-`concatCollection`-fans them across every
|
|
44384
|
-
* registered provider (notifiers addon + HA addon) so one catalog is
|
|
44385
|
-
* routable. `send` / `testTarget` / CRUD route to ONE provider by the
|
|
44386
|
-
* `addonId` the generated collection router extracts from the call input.
|
|
44387
|
-
* - `Attachment.bytes` is `Uint8Array`. Transport-safe: superjson (the tRPC
|
|
44388
|
-
* transformer) + UDS MsgPack both round-trip typed arrays — already used by
|
|
44389
|
-
* `storage` / `storage-provider` / `recording` caps over the same path. No
|
|
44390
|
-
* base64 fallback needed.
|
|
44391
|
-
*
|
|
44392
|
-
* TODO (deferred, closed-set change — separate decision): add
|
|
44393
|
-
* `providerKind: 'notify'` so notification providers surface on the unified
|
|
44394
|
-
* admin "Integrations" page.
|
|
44395
|
-
*/
|
|
44396
|
-
/**
|
|
44397
|
-
* Zentik-derived typed-media enum — the superset across every kind. Each
|
|
44398
|
-
* adapter picks what it supports and the degrade engine filters the rest.
|
|
44399
|
-
*/
|
|
44400
|
-
var AttachmentMediaTypeSchema = _enum([
|
|
44401
|
-
"image",
|
|
44402
|
-
"video",
|
|
44403
|
-
"gif",
|
|
44404
|
-
"audio",
|
|
44405
|
-
"icon"
|
|
44406
|
-
]);
|
|
44407
|
-
/**
|
|
44408
|
-
* A single attachment. Exactly one of `url` (remote source, most adapters
|
|
44409
|
-
* prefer this) or `bytes` (inline source; required for Pushover-style
|
|
44410
|
-
* bytes-only kinds) MUST be present — the degrade engine expresses a
|
|
44411
|
-
* url→bytes fetch as a `needsFetch` directive the adapter executes.
|
|
44412
|
-
*/
|
|
44413
|
-
var AttachmentSchema = object({
|
|
44414
|
-
mediaType: AttachmentMediaTypeSchema,
|
|
44415
|
-
url: string().optional(),
|
|
44416
|
-
bytes: _instanceof(Uint8Array).optional(),
|
|
44417
|
-
mime: string().optional(),
|
|
44418
|
-
name: string().optional()
|
|
44419
|
-
}).refine((a) => a.url !== void 0 || a.bytes !== void 0, { message: "Attachment requires either `url` or `bytes`" });
|
|
44420
|
-
var NotificationFormatSchema = _enum([
|
|
44421
|
-
"text",
|
|
44422
|
-
"markdown",
|
|
44423
|
-
"html"
|
|
44424
|
-
]);
|
|
44425
|
-
/**
|
|
44426
|
-
* The CLOSED icon vocabulary an action button may use.
|
|
44427
|
-
*
|
|
44428
|
-
* A closed set, not a free string, and that is the whole point: an arbitrary
|
|
44429
|
-
* icon name is one that ntfy renders, zentik silently drops, and nobody
|
|
44430
|
-
* notices — the same class of gap as a zone vocabulary nothing produced
|
|
44431
|
-
* ([D35](../../../docs/decisions/adr-0035.md)). Every adapter maps this set or
|
|
44432
|
-
* declares `actionIcons: false` and the degrade engine strips the field.
|
|
44433
|
-
*
|
|
44434
|
-
* Named by INTENT, never by glyph. "check" would tie the vocabulary to one
|
|
44435
|
-
* renderer's icon set; "acknowledge" survives an adapter that draws it
|
|
44436
|
-
* differently.
|
|
44437
|
-
*
|
|
44438
|
-
* ── A TOKEN IS NOT A WIRE VALUE ─────────────────────────────────────
|
|
44439
|
-
*
|
|
44440
|
-
* These names are for US. **No adapter may forward one verbatim.** Each maps
|
|
44441
|
-
* the whole set onto its own renderer's vocabulary through a
|
|
44442
|
-
* `Record<NotificationActionIcon, string>` — a Record, never a lookup with a
|
|
44443
|
-
* fallback, so adding a member here fails every adapter's build until someone
|
|
44444
|
-
* decides its glyph, which is the only place that decision can be made
|
|
44445
|
-
* honestly.
|
|
44446
|
-
*
|
|
44447
|
-
* This paragraph is the bug. Zentik declared `actionIcons: true` and passed
|
|
44448
|
-
* `disarm` straight through; iOS feeds that string to
|
|
44449
|
-
* `UNNotificationActionIcon(systemImageName:)`, `disarm` is not an SF Symbol,
|
|
44450
|
-
* and every snooze and alarm button arrived BLANK. A pass-through is not a
|
|
44451
|
-
* mapping, and "the field is documented" is not "the value renders".
|
|
44452
|
-
*
|
|
44453
|
-
* Adding a member is TRAIN-BOUND. The enum lives in the published
|
|
44454
|
-
* `@camstack/server` closure and the cap seam validates against the HUB's copy,
|
|
44455
|
-
* so an addon that emits a token the running hub does not know does not lose an
|
|
44456
|
-
* icon — its whole `send` fails Zod validation and the notification never
|
|
44457
|
-
* arrives. Never emit a new token from an addon before the train carrying it.
|
|
44458
|
-
*/
|
|
44459
|
-
var NotificationActionIconSchema = _enum([
|
|
44460
|
-
"acknowledge",
|
|
44461
|
-
"dismiss",
|
|
44462
|
-
"silence",
|
|
44463
|
-
"snooze",
|
|
44464
|
-
"view",
|
|
44465
|
-
"play",
|
|
44466
|
-
"open",
|
|
44467
|
-
"close",
|
|
44468
|
-
"lock",
|
|
44469
|
-
"unlock",
|
|
44470
|
-
"arm",
|
|
44471
|
-
"arm-home",
|
|
44472
|
-
"arm-away",
|
|
44473
|
-
"arm-night",
|
|
44474
|
-
"disarm",
|
|
44475
|
-
"light",
|
|
44476
|
-
"alert",
|
|
44477
|
-
"camera"
|
|
44478
|
-
]);
|
|
44479
|
-
/** A single tap-through action button. */
|
|
44480
|
-
var NotificationActionSchema = object({
|
|
44481
|
-
id: string(),
|
|
44482
|
-
label: string(),
|
|
44483
|
-
url: string().optional(),
|
|
44484
|
-
/** Dropped by the degrade engine for a kind with `caps.actionIcons: false`. */
|
|
44485
|
-
icon: NotificationActionIconSchema.optional(),
|
|
44486
|
-
/**
|
|
44487
|
-
* Renders in a warning style where the notifier supports it.
|
|
44488
|
-
*
|
|
44489
|
-
* A HINT, never a gate. The callback's authority is its token and nothing
|
|
44490
|
-
* else — see `notification-center/action-token.ts` for what that does and
|
|
44491
|
-
* does not buy.
|
|
44492
|
-
*/
|
|
44493
|
-
destructive: boolean().optional(),
|
|
44494
|
-
/**
|
|
44495
|
-
* How the tap should REACH the url.
|
|
44496
|
-
*
|
|
44497
|
-
* `navigate` (absent, and every button authored before this field) opens it:
|
|
44498
|
-
* the phone leaves the notification and shows whatever the callback returns.
|
|
44499
|
-
* That is right for a button whose answer the operator wants to read.
|
|
44500
|
-
*
|
|
44501
|
-
* `background` fires it as a POST and stays put. It exists for the buttons
|
|
44502
|
-
* whose whole point is not to interrupt — "silence this for 30 minutes" is
|
|
44503
|
-
* an answer to the notification, and being thrown into a browser tab to
|
|
44504
|
-
* confirm it costs more attention than the notification did. A backend that
|
|
44505
|
-
* cannot do a background call renders it as an ordinary link (the adapters
|
|
44506
|
-
* fall back rather than dropping the button), so this is a preference, never
|
|
44507
|
-
* a requirement.
|
|
44508
|
-
*/
|
|
44509
|
-
mode: _enum(["navigate", "background"]).optional()
|
|
44510
|
-
});
|
|
44511
|
-
/**
|
|
44512
|
-
* The canonical notification. `body` is the only hard field (Apprise model).
|
|
44513
|
-
* `priority` is a 5-level ORDINAL (1=lowest … 3=normal(default) … 5=urgent),
|
|
44514
|
-
* NOT a fixed severity enum — each kind declares its own `caps.levels` and
|
|
44515
|
-
* the adapter maps this ordinal onto its native level. `level?` is an
|
|
44516
|
-
* optional kind-native level id (`emergency`, `silent`, …) that overrides
|
|
44517
|
-
* `priority` for that one target.
|
|
44518
|
-
*/
|
|
44519
|
-
var NotificationSchema = object({
|
|
44520
|
-
body: string(),
|
|
44521
|
-
title: string().optional(),
|
|
44522
|
-
format: NotificationFormatSchema.default("text"),
|
|
44523
|
-
priority: number().int().min(1).max(5).default(3),
|
|
44524
|
-
level: string().optional(),
|
|
44525
|
-
attachments: array(AttachmentSchema).optional(),
|
|
44526
|
-
clickUrl: string().optional(),
|
|
44527
|
-
actions: array(NotificationActionSchema).optional(),
|
|
44528
|
-
sound: string().optional(),
|
|
44529
|
-
ttl: number().optional(),
|
|
44530
|
-
tag: string().optional(),
|
|
44531
|
-
deviceId: number().optional(),
|
|
44532
|
-
eventId: string().optional(),
|
|
44533
|
-
metadata: record(string(), unknown()).optional()
|
|
44534
|
-
});
|
|
44535
|
-
/** One declared native severity/priority level for a kind. */
|
|
44536
|
-
var TargetKindLevelSchema = object({
|
|
44537
|
-
id: string(),
|
|
44538
|
-
label: string(),
|
|
44539
|
-
/** Which canonical priority (1..5) this level maps to. `null` = qualitative-only. */
|
|
44540
|
-
ordinal: number().int().min(1).max(5).nullable(),
|
|
44541
|
-
flags: object({
|
|
44542
|
-
critical: boolean().optional(),
|
|
44543
|
-
silent: boolean().optional(),
|
|
44544
|
-
noPush: boolean().optional()
|
|
44545
|
-
}).optional(),
|
|
44546
|
-
/** e.g. Pushover `emergency` requires `retry` / `expire`. */
|
|
44547
|
-
requires: array(string()).optional(),
|
|
44548
|
-
description: string().optional()
|
|
44549
|
-
});
|
|
44550
|
-
/** The full capability block consulted before dispatch. */
|
|
44551
|
-
var TargetKindCapsSchema = object({
|
|
44552
|
-
attachments: object({
|
|
44553
|
-
mediaTypes: array(AttachmentMediaTypeSchema),
|
|
44554
|
-
mode: _enum([
|
|
44555
|
-
"url",
|
|
44556
|
-
"bytes",
|
|
44557
|
-
"both"
|
|
44558
|
-
]),
|
|
44559
|
-
max: number().int().nonnegative(),
|
|
44560
|
-
maxBytes: number().int().positive().optional()
|
|
44561
|
-
}),
|
|
44562
|
-
/** Max action buttons (0 = none). */
|
|
44563
|
-
actions: number().int().nonnegative(),
|
|
44564
|
-
/**
|
|
44565
|
-
* Whether this kind renders a per-action ICON.
|
|
44566
|
-
*
|
|
44567
|
-
* `.optional()`, deliberately NOT `.default(false)`: a Zod default does not
|
|
44568
|
-
* run on the addon cap path — three production failures in one day taught
|
|
44569
|
-
* this repo that once. Absent is read as false by the degrade engine, which
|
|
44570
|
-
* is the safe direction: an icon that is not rendered costs nothing, an icon
|
|
44571
|
-
* assumed and dropped costs the operator's trust in the field.
|
|
44572
|
-
*/
|
|
44573
|
-
actionIcons: boolean().optional(),
|
|
44574
|
-
levels: array(TargetKindLevelSchema),
|
|
44575
|
-
format: array(NotificationFormatSchema),
|
|
44576
|
-
clickUrl: boolean(),
|
|
44577
|
-
sound: boolean(),
|
|
44578
|
-
ttl: boolean(),
|
|
44579
|
-
bodyMaxLen: number().int().positive()
|
|
44580
|
-
});
|
|
44581
|
-
/**
|
|
44582
|
-
* `configSchema` is a `ConfigUISchema` tree passed through to the admin
|
|
44583
|
-
* FormBuilder. Stored as `z.unknown()` at the cap seam (mirrors
|
|
44584
|
-
* `device-provider.getChildCreationSchema` `CreationSchemaOutputSchema`) —
|
|
44585
|
-
* the union is large and not meant for runtime validation here; the exported
|
|
44586
|
-
* `TargetKind` type re-tightens `configSchema` to `ConfigUISchema`.
|
|
44587
|
-
*/
|
|
44588
|
-
var ConfigSchemaPassthrough$2 = unknown();
|
|
44589
|
-
var TargetKindSchema = object({
|
|
44590
|
-
kind: string(),
|
|
44591
|
-
label: string(),
|
|
44592
|
-
icon: string(),
|
|
44593
|
-
/** Stamped by each provider so the concat-fanned catalog stays routable. */
|
|
44594
|
-
addonId: string(),
|
|
44595
|
-
/**
|
|
44596
|
-
* URL of the kind's bundled BRAND icon, served by the providing addon over
|
|
44597
|
-
* its own `addon-routes` surface (`/addon/<addonId>/icons/<kind>`). Absent
|
|
44598
|
-
* when the addon bundles no icon for that kind — the client then falls back
|
|
44599
|
-
* to a neutral glyph rather than rendering the raw `icon` NAME as text.
|
|
44600
|
-
*
|
|
44601
|
-
* Root-relative on purpose: it resolves against whatever origin serves a web
|
|
44602
|
-
* client, and a native client joins it onto its own hub base.
|
|
44603
|
-
*
|
|
44604
|
-
* DECLARED here deliberately. It used to travel as an undeclared passthrough
|
|
44605
|
-
* field that survived only because the runtime cap-router forwards provider
|
|
44606
|
-
* output verbatim — so every consumer had to re-declare it by hand to stop
|
|
44607
|
-
* its own Zod parse from stripping it, and the whole arrangement would have
|
|
44608
|
-
* broken silently the moment output validation was tightened anywhere.
|
|
44742
|
+
* Did the DURABLE tier contribute? `false` means the answer is the hot ring
|
|
44743
|
+
* alone — an agent (which holds no table), or a store that refused.
|
|
44744
|
+
* Reported because "the last hour" and "the last six hours" are different
|
|
44745
|
+
* questions and an operator must not have to guess which was answered.
|
|
44609
44746
|
*/
|
|
44610
|
-
|
|
44747
|
+
durable: boolean()
|
|
44748
|
+
});
|
|
44749
|
+
var GetLoadSeriesInputSchema = object({
|
|
44611
44750
|
/**
|
|
44612
|
-
*
|
|
44613
|
-
*
|
|
44614
|
-
* The server knows this and therefore says it, because the client cannot
|
|
44615
|
-
* safely guess: a React-Native client renders SVG and raster through two
|
|
44616
|
-
* DIFFERENT components (`react-native-svg` vs `expo-image` — expo-image does
|
|
44617
|
-
* not decode SVG on iOS/Android), so without this it silently fell back to a
|
|
44618
|
-
* placeholder glyph for every vector icon while the web build looked fine.
|
|
44751
|
+
* The node whose series is wanted.
|
|
44619
44752
|
*
|
|
44620
|
-
*
|
|
44621
|
-
*
|
|
44622
|
-
*
|
|
44753
|
+
* NOT named `nodeId`: the generated cap router strips a top-level
|
|
44754
|
+
* `nodeId` from every method input and uses it to ROUTE the call to
|
|
44755
|
+
* that node's provider (`generated-cap-routers.ts`). A series target
|
|
44756
|
+
* called `nodeId` would silently become a routing pin and never reach
|
|
44757
|
+
* the provider. The hub holds every node it hears from, so the
|
|
44758
|
+
* ordinary call is unpinned — answered by the hub, for any node.
|
|
44623
44759
|
*/
|
|
44624
|
-
|
|
44625
|
-
configSchema: ConfigSchemaPassthrough$2,
|
|
44760
|
+
forNodeId: string(),
|
|
44626
44761
|
/**
|
|
44627
|
-
*
|
|
44628
|
-
*
|
|
44629
|
-
*
|
|
44630
|
-
|
|
44631
|
-
|
|
44762
|
+
* EXCLUSIVE lower bound. A caller passes the newest `atMs` it already
|
|
44763
|
+
* holds and receives only what it is missing, so seeding a live chart
|
|
44764
|
+
* from this method cannot double a point already drawn.
|
|
44765
|
+
*/
|
|
44766
|
+
sinceMs: number().optional(),
|
|
44767
|
+
/**
|
|
44768
|
+
* Most points the caller wants PER FUNCTION. The window is reduced to fit,
|
|
44769
|
+
* preserving min and max per bucket.
|
|
44632
44770
|
*
|
|
44633
|
-
*
|
|
44634
|
-
*
|
|
44635
|
-
* it absent must assume ANY edit may need the secret.
|
|
44771
|
+
* Absent means NO reduction — legitimate for a short window and a trap for a
|
|
44772
|
+
* long one, which is why a chart passes its own pixel width.
|
|
44636
44773
|
*/
|
|
44637
|
-
|
|
44638
|
-
|
|
44639
|
-
|
|
44774
|
+
maxPoints: number().int().positive().optional()
|
|
44775
|
+
});
|
|
44776
|
+
var SystemMetricsSchema = object({
|
|
44777
|
+
cpuPercent: number(),
|
|
44778
|
+
/** `null` when the memory sample failed or was not taken yet (D393). */
|
|
44779
|
+
memoryPercent: number().nullable(),
|
|
44780
|
+
memoryUsedMB: number().nullable(),
|
|
44781
|
+
memoryTotalMB: number(),
|
|
44782
|
+
diskPercent: number().optional(),
|
|
44783
|
+
temperature: number().optional(),
|
|
44784
|
+
gpuPercent: number().optional(),
|
|
44785
|
+
gpuMemoryPercent: number().optional()
|
|
44786
|
+
});
|
|
44787
|
+
method(_void(), SystemResourceSnapshotSchema), method(_void(), SystemResourceSnapshotSchema.nullable()), method(_void(), SystemMetricsSchema), method(object({ dirPath: string() }), DiskSpaceInfoSchema), method(_void(), MetricsGpuInfoSchema.nullable()), method(_void(), number().nullable()), method(object({ pids: array(number()) }), array(PidResourceStatsSchema)), method(_void(), array(AddonInstanceSchema).readonly()), method(object({ addonId: string() }), PidResourceStatsSchema.nullable()), method(_void(), array(NodeProcessSchema).readonly()), method(GetLoadSeriesInputSchema, NodeLoadSeriesSchema);
|
|
44788
|
+
method(object({
|
|
44789
|
+
sourceUrl: string(),
|
|
44790
|
+
metadata: ModelConvertMetadataSchema,
|
|
44791
|
+
targets: array(ConvertTargetSchema).min(1).readonly(),
|
|
44792
|
+
calibrationRef: string().optional(),
|
|
44793
|
+
sessionId: string().optional()
|
|
44794
|
+
}), ConvertResultSchema, {
|
|
44795
|
+
kind: "mutation",
|
|
44796
|
+
auth: "admin",
|
|
44797
|
+
timeoutMs: 6e5
|
|
44798
|
+
});
|
|
44799
|
+
method(object({
|
|
44800
|
+
targetNodeId: string(),
|
|
44801
|
+
modelId: string(),
|
|
44802
|
+
format: _enum(MODEL_FORMATS),
|
|
44803
|
+
entry: ModelCatalogEntrySchema
|
|
44804
|
+
}), object({
|
|
44805
|
+
ok: boolean(),
|
|
44806
|
+
/** sha256 of the staged tarball (empty for a hub-local no-op). */
|
|
44807
|
+
sha256: string(),
|
|
44808
|
+
bytes: number(),
|
|
44809
|
+
/** The target node's modelsDir the artifact landed in. */
|
|
44810
|
+
path: string()
|
|
44811
|
+
}), {
|
|
44812
|
+
kind: "mutation",
|
|
44813
|
+
auth: "admin"
|
|
44814
|
+
});
|
|
44815
|
+
var MotionRegionSchema = object({
|
|
44816
|
+
bbox: BoundingBoxSchema,
|
|
44817
|
+
pixelCount: number(),
|
|
44818
|
+
intensity: number()
|
|
44819
|
+
});
|
|
44820
|
+
var MotionAnalysisResultSchema = object({
|
|
44821
|
+
detected: boolean(),
|
|
44822
|
+
regionCount: number(),
|
|
44823
|
+
/** Regions passing minArea filter — used for pipeline triggering. */
|
|
44824
|
+
regions: array(MotionRegionSchema).readonly(),
|
|
44825
|
+
/** All raw regions from CCL before minArea filter — used for UI debug overlay. */
|
|
44826
|
+
rawRegions: array(MotionRegionSchema).readonly(),
|
|
44827
|
+
frameWidth: number(),
|
|
44828
|
+
frameHeight: number(),
|
|
44829
|
+
analysisMs: number()
|
|
44830
|
+
});
|
|
44831
|
+
DeviceType.Camera, method(object({
|
|
44832
|
+
deviceId: number(),
|
|
44833
|
+
frame: FrameInputSchema.optional(),
|
|
44834
|
+
frameHandle: FrameHandleSchema.optional()
|
|
44835
|
+
}), MotionAnalysisResultSchema, {
|
|
44836
|
+
role: "admin",
|
|
44837
|
+
kind: "mutation"
|
|
44838
|
+
}), method(object({ deviceId: number() }), _void(), {
|
|
44839
|
+
role: "admin",
|
|
44840
|
+
kind: "mutation"
|
|
44841
|
+
}), method(_void(), _void(), {
|
|
44842
|
+
role: "admin",
|
|
44843
|
+
kind: "mutation"
|
|
44844
|
+
}), object({
|
|
44845
|
+
deviceId: number(),
|
|
44846
|
+
detected: boolean(),
|
|
44847
|
+
regionCount: number()
|
|
44640
44848
|
});
|
|
44641
44849
|
/**
|
|
44642
|
-
*
|
|
44643
|
-
*
|
|
44644
|
-
*
|
|
44850
|
+
* `mqtt-broker` — broker-registry cap.
|
|
44851
|
+
*
|
|
44852
|
+
* NOT a pub/sub proxy. The cap exposes (a) a registry of configured
|
|
44853
|
+
* MQTT brokers (external + optionally an embedded `aedes`-backed one)
|
|
44854
|
+
* and (b) the connection details a consumer addon needs to spin up
|
|
44855
|
+
* its OWN `mqtt.js` client.
|
|
44856
|
+
*
|
|
44857
|
+
* Why: pub/sub routing over the system event-bus loses fidelity
|
|
44858
|
+
* (callback shape, QoS guarantees, will/retain semantics) and adds
|
|
44859
|
+
* refcount bookkeeping that addons would rather own themselves. The
|
|
44860
|
+
* canonical consumer needs raw `mqtt.js`
|
|
44861
|
+
* features anyway — give it the connection config, get out of the way.
|
|
44862
|
+
*
|
|
44863
|
+
* Consumer flow:
|
|
44864
|
+
* const cfg = await ctx.api.mqttBroker.getBrokerConfig({ id })
|
|
44865
|
+
* const client = mqtt.connect(cfg.url, { username: cfg.username, … })
|
|
44866
|
+
* client.subscribe('zigbee2mqtt/+')
|
|
44867
|
+
*
|
|
44868
|
+
* Collection mode: multiple brokers (e.g. one local mosquitto + one
|
|
44869
|
+
* cloud bridge). The "embedded" entry (when present) is just another
|
|
44870
|
+
* broker in the registry — its lifecycle is owned by the addon that
|
|
44871
|
+
* spawned it.
|
|
44645
44872
|
*/
|
|
44646
|
-
var
|
|
44873
|
+
var BrokerKindSchema = _enum(["external", "embedded"]);
|
|
44874
|
+
/**
|
|
44875
|
+
* Broker live-probe status.
|
|
44876
|
+
*
|
|
44877
|
+
* - `connected` — last probe completed a clean CONNACK
|
|
44878
|
+
* - `disconnected` — no probe has run yet (cold cache)
|
|
44879
|
+
* - `auth-failed` — CONNACK refused with auth error (RC 4 / 5)
|
|
44880
|
+
* - `unreachable` — TCP connect timed out / refused
|
|
44881
|
+
* - `tls-error` — TLS handshake failed (cert / SNI / cipher)
|
|
44882
|
+
*/
|
|
44883
|
+
var BrokerStatusSchema$1 = _enum([
|
|
44884
|
+
"connected",
|
|
44885
|
+
"disconnected",
|
|
44886
|
+
"auth-failed",
|
|
44887
|
+
"unreachable",
|
|
44888
|
+
"tls-error"
|
|
44889
|
+
]);
|
|
44890
|
+
var BrokerInfoSchema$1 = object({
|
|
44647
44891
|
id: string(),
|
|
44648
44892
|
name: string(),
|
|
44649
|
-
|
|
44650
|
-
|
|
44651
|
-
|
|
44652
|
-
|
|
44653
|
-
});
|
|
44654
|
-
/** A discovery-surfaced candidate (config is partial + non-secret). */
|
|
44655
|
-
var DiscoveredTargetSchema = object({
|
|
44656
|
-
kind: string(),
|
|
44657
|
-
suggestedName: string(),
|
|
44658
|
-
config: record(string(), unknown())
|
|
44659
|
-
});
|
|
44660
|
-
/** The degrade engine's report — what was resolved / dropped / degraded. */
|
|
44661
|
-
var RenderedAsSchema = object({
|
|
44662
|
-
level: string(),
|
|
44663
|
-
format: NotificationFormatSchema,
|
|
44664
|
-
attachmentsSent: number().int().nonnegative(),
|
|
44665
|
-
actionsSent: number().int().nonnegative(),
|
|
44666
|
-
truncated: boolean(),
|
|
44667
|
-
dropped: array(string())
|
|
44668
|
-
});
|
|
44669
|
-
var SendResultSchema = object({
|
|
44670
|
-
success: boolean(),
|
|
44893
|
+
url: string(),
|
|
44894
|
+
kind: BrokerKindSchema,
|
|
44895
|
+
status: BrokerStatusSchema$1,
|
|
44896
|
+
latencyMs: number().nullable(),
|
|
44671
44897
|
error: string().optional(),
|
|
44672
|
-
|
|
44898
|
+
/** Embedded brokers only: number of MQTT clients currently connected. */
|
|
44899
|
+
connectedClients: number().int().nonnegative().optional(),
|
|
44900
|
+
/** Epoch ms of the last live probe (external) or aedes snapshot (embedded). */
|
|
44901
|
+
lastCheckedAt: number().optional()
|
|
44673
44902
|
});
|
|
44674
|
-
/** Same shape as SendResult — kept as a distinct name for the test panel. */
|
|
44675
|
-
var TestResultSchema = SendResultSchema;
|
|
44676
44903
|
/**
|
|
44677
|
-
*
|
|
44678
|
-
* `
|
|
44904
|
+
* Connection details — what a consumer needs to call
|
|
44905
|
+
* `mqtt.connect(url, options)`. We split URL + credentials so the
|
|
44906
|
+
* consumer can pass them as `mqtt.connect(url, { username, password })`
|
|
44907
|
+
* instead of stuffing creds into the URL (which leaks them into logs).
|
|
44679
44908
|
*/
|
|
44680
|
-
var
|
|
44681
|
-
|
|
44682
|
-
|
|
44683
|
-
|
|
44684
|
-
stateInstance: string().optional(),
|
|
44685
|
-
error: string().optional()
|
|
44686
|
-
});
|
|
44687
|
-
method(object({}), array(TargetKindSchema)), method(object({}), array(TargetSchema), { auth: "admin" }), method(object({ targetId: string() }), TargetSchema, { auth: "admin" }), method(object({
|
|
44688
|
-
kind: string(),
|
|
44689
|
-
config: record(string(), unknown()).optional(),
|
|
44909
|
+
var BrokerConnectionDetailsSchema = object({
|
|
44910
|
+
url: string(),
|
|
44911
|
+
username: string().optional(),
|
|
44912
|
+
password: string().optional(),
|
|
44690
44913
|
/**
|
|
44691
|
-
*
|
|
44692
|
-
*
|
|
44693
|
-
*
|
|
44914
|
+
* Suggested prefix for `clientId`. Each consumer should suffix this
|
|
44915
|
+
* with its own discriminator (addon id, instance id) so reconnects
|
|
44916
|
+
* don't kick each other off (MQTT spec: clientId must be unique per
|
|
44917
|
+
* broker).
|
|
44694
44918
|
*/
|
|
44695
|
-
|
|
44696
|
-
})
|
|
44697
|
-
|
|
44698
|
-
|
|
44699
|
-
|
|
44700
|
-
|
|
44701
|
-
|
|
44702
|
-
|
|
44703
|
-
|
|
44704
|
-
|
|
44705
|
-
|
|
44706
|
-
|
|
44707
|
-
|
|
44919
|
+
clientIdPrefix: string().optional()
|
|
44920
|
+
});
|
|
44921
|
+
var AddBrokerInputSchema = object({
|
|
44922
|
+
name: string().min(1),
|
|
44923
|
+
url: string().regex(/^(mqtt|mqtts|ws|wss):\/\//, "URL must start with mqtt(s):// or ws(s)://"),
|
|
44924
|
+
username: string().optional(),
|
|
44925
|
+
password: string().optional(),
|
|
44926
|
+
clientIdPrefix: string().optional()
|
|
44927
|
+
});
|
|
44928
|
+
var AddBrokerResultSchema = object({ id: string() });
|
|
44929
|
+
var IdInputSchema = object({ id: string() });
|
|
44930
|
+
var TestResultSchema$1 = discriminatedUnion("ok", [object({
|
|
44931
|
+
ok: literal(true),
|
|
44932
|
+
latencyMs: number()
|
|
44933
|
+
}), object({
|
|
44934
|
+
ok: literal(false),
|
|
44935
|
+
error: string()
|
|
44936
|
+
})]);
|
|
44937
|
+
var StartEmbeddedInputSchema = object({
|
|
44938
|
+
port: number().int().min(1).max(65535).default(1883),
|
|
44939
|
+
/** Allow anonymous connect (no username/password). Default: false. */
|
|
44940
|
+
allowAnonymous: boolean().default(false),
|
|
44941
|
+
/** Optional shared username/password for clients. */
|
|
44942
|
+
username: string().optional(),
|
|
44943
|
+
password: string().optional()
|
|
44944
|
+
});
|
|
44945
|
+
var StartEmbeddedResultSchema = object({
|
|
44946
|
+
id: string(),
|
|
44947
|
+
url: string()
|
|
44948
|
+
});
|
|
44949
|
+
var StatusSchema = object({
|
|
44950
|
+
brokerCount: number(),
|
|
44951
|
+
embeddedRunning: boolean()
|
|
44952
|
+
});
|
|
44953
|
+
method(_void(), array(BrokerInfoSchema$1)), method(IdInputSchema, BrokerConnectionDetailsSchema, { auth: "admin" }), method(AddBrokerInputSchema, AddBrokerResultSchema, {
|
|
44708
44954
|
kind: "mutation",
|
|
44709
44955
|
auth: "admin"
|
|
44710
|
-
}), method(
|
|
44711
|
-
targetId: string(),
|
|
44712
|
-
sample: NotificationSchema.optional()
|
|
44713
|
-
}), TestResultSchema, {
|
|
44956
|
+
}), method(IdInputSchema, _void(), {
|
|
44714
44957
|
kind: "mutation",
|
|
44715
44958
|
auth: "admin"
|
|
44716
|
-
}), method(
|
|
44717
|
-
target: TargetSchema,
|
|
44718
|
-
/**
|
|
44719
|
-
* Duplicate flow: create a NEW target id while copying secrets from an
|
|
44720
|
-
* existing row. The UI never holds the stored token; blank / redacted
|
|
44721
|
-
* password fields are restored from this source (D634 still applies if
|
|
44722
|
-
* destinations diverge without a re-typed secret).
|
|
44723
|
-
*/
|
|
44724
|
-
cloneSecretsFrom: string().optional()
|
|
44725
|
-
}), TargetSchema, {
|
|
44959
|
+
}), method(IdInputSchema, TestResultSchema$1, {
|
|
44726
44960
|
kind: "mutation",
|
|
44727
44961
|
auth: "admin"
|
|
44728
|
-
}), method(
|
|
44962
|
+
}), method(StartEmbeddedInputSchema, StartEmbeddedResultSchema, {
|
|
44729
44963
|
kind: "mutation",
|
|
44730
44964
|
auth: "admin"
|
|
44731
|
-
}), method(
|
|
44732
|
-
targetId: string(),
|
|
44733
|
-
enabled: boolean()
|
|
44734
|
-
}), _void(), {
|
|
44965
|
+
}), method(IdInputSchema, _void(), {
|
|
44735
44966
|
kind: "mutation",
|
|
44736
44967
|
auth: "admin"
|
|
44968
|
+
}), method(_void(), StatusSchema);
|
|
44969
|
+
var NetworkEndpointSchema = object({
|
|
44970
|
+
url: string(),
|
|
44971
|
+
hostname: string(),
|
|
44972
|
+
port: number(),
|
|
44973
|
+
protocol: _enum(["http", "https"]),
|
|
44974
|
+
/**
|
|
44975
|
+
* Whether this address survives a restart of its provider. `false` = it is
|
|
44976
|
+
* re-issued every time (a Quick tunnel's random `*.trycloudflare.com`); the
|
|
44977
|
+
* hub never selects such an address AUTOMATICALLY for a role (D860), though
|
|
44978
|
+
* it stays visible and an operator may still flag it. Absent = stable: every
|
|
44979
|
+
* provider except a Quick tunnel owns a name that does not change.
|
|
44980
|
+
*/
|
|
44981
|
+
stable: boolean().optional()
|
|
44982
|
+
});
|
|
44983
|
+
object({
|
|
44984
|
+
url: string(),
|
|
44985
|
+
/** Mirrors {@link NetworkEndpointSchema} `stable`; absent = stable. */
|
|
44986
|
+
stable: boolean().optional(),
|
|
44987
|
+
updated: boolean().optional()
|
|
44988
|
+
});
|
|
44989
|
+
var NetworkAccessStatusSchema = object({
|
|
44990
|
+
connected: boolean(),
|
|
44991
|
+
endpoint: NetworkEndpointSchema.nullable(),
|
|
44992
|
+
error: string().optional()
|
|
44993
|
+
});
|
|
44994
|
+
/**
|
|
44995
|
+
* Optional, richer endpoint shape returned by providers that expose
|
|
44996
|
+
* MORE than one ingress concurrently (Tailscale Funnel with mixed
|
|
44997
|
+
* serve+funnel rules, future ngrok multi-tunnel, …). Each entry carries
|
|
44998
|
+
* the originating provider config (mode + sourcePort) so the
|
|
44999
|
+
* orchestrator UI can label rows distinctly. Providers that expose only
|
|
45000
|
+
* one endpoint just omit `listEndpoints` from their provider impl.
|
|
45001
|
+
*/
|
|
45002
|
+
var NetworkEndpointEntrySchema = NetworkEndpointSchema.extend({
|
|
45003
|
+
/**
|
|
45004
|
+
* Stable id within the provider — typically `<mode>-<sourcePort>` so
|
|
45005
|
+
* the orchestrator can dedupe across `listEndpoints` polls.
|
|
45006
|
+
*/
|
|
45007
|
+
id: string(),
|
|
45008
|
+
/** Operator-facing label (mirrors `MeshEndpoint.label`). */
|
|
45009
|
+
label: string(),
|
|
45010
|
+
/** Optional provider-specific mode tag, used for icon/colour in admin UI. */
|
|
45011
|
+
mode: string().optional(),
|
|
45012
|
+
/** Originating local port the ingress fronts (informational). */
|
|
45013
|
+
sourcePort: number().optional()
|
|
44737
45014
|
});
|
|
45015
|
+
method(_void(), NetworkEndpointSchema, { kind: "mutation" }), method(_void(), _void(), { kind: "mutation" }), method(_void(), NetworkEndpointSchema.nullable()), method(_void(), NetworkAccessStatusSchema), method(_void(), array(NetworkEndpointEntrySchema).readonly());
|
|
44738
45016
|
var AUDIO_MACRO_LABELS = [
|
|
44739
45017
|
{
|
|
44740
45018
|
id: "speech",
|
|
@@ -51151,14 +51429,6 @@ var EngineProvisioningSchema = object({
|
|
|
51151
51429
|
*/
|
|
51152
51430
|
configIssues: array(string()).optional()
|
|
51153
51431
|
});
|
|
51154
|
-
var PipelineStepInputSchema = lazy(() => object({
|
|
51155
|
-
addonId: string(),
|
|
51156
|
-
modelId: string().optional(),
|
|
51157
|
-
enabled: boolean().default(true),
|
|
51158
|
-
children: array(PipelineStepInputSchema).optional(),
|
|
51159
|
-
settings: record(string(), unknown()).optional(),
|
|
51160
|
-
jumpDeviceKey: string().optional()
|
|
51161
|
-
}));
|
|
51162
51432
|
var ModelSubstitutionSchema = object({
|
|
51163
51433
|
addonId: string(),
|
|
51164
51434
|
chosen: string(),
|
|
@@ -51237,7 +51507,6 @@ var ConfigUISchemaBridge = custom();
|
|
|
51237
51507
|
var ConfigUISchemaNullableBridge = custom();
|
|
51238
51508
|
var InferenceCapabilitiesBridge = custom();
|
|
51239
51509
|
var ModelAvailabilityListBridge = custom();
|
|
51240
|
-
var PipelineRunResultBridge = custom();
|
|
51241
51510
|
method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngineChoiceSchema), method(object({ nodeId: string() }), EngineProvisioningSchema), method(_void(), record(string(), object({
|
|
51242
51511
|
modelId: string(),
|
|
51243
51512
|
settings: record(string(), unknown()).readonly()
|
|
@@ -54399,6 +54668,12 @@ var ServerUpdateActionResultSchema = object({
|
|
|
54399
54668
|
*/
|
|
54400
54669
|
blockers: array(UpdateBlockerSchema).optional()
|
|
54401
54670
|
});
|
|
54671
|
+
var LaunchOverridesSchema = object({
|
|
54672
|
+
/** The persisted heap ceiling in MB, or `null` when none is set. */
|
|
54673
|
+
heapMb: number().int().nullable() });
|
|
54674
|
+
var SetLaunchOverridesResultSchema = LaunchOverridesSchema.extend({
|
|
54675
|
+
/** Always true: the override is read at launch, not by the running process. */
|
|
54676
|
+
restartRequired: boolean() });
|
|
54402
54677
|
method(_void(), ServerPackageStatusSchema, { auth: "admin" }), method(_void(), ServerUpdateCheckResultSchema, {
|
|
54403
54678
|
kind: "mutation",
|
|
54404
54679
|
auth: "admin"
|
|
@@ -54421,6 +54696,9 @@ method(_void(), ServerPackageStatusSchema, { auth: "admin" }), method(_void(), S
|
|
|
54421
54696
|
}), method(_void(), ServerUpdateActionResultSchema, {
|
|
54422
54697
|
kind: "mutation",
|
|
54423
54698
|
auth: "admin"
|
|
54699
|
+
}), method(_void(), LaunchOverridesSchema, { auth: "admin" }), method(object({ heapMb: number().int().min(512).max(65536).nullable() }), SetLaunchOverridesResultSchema, {
|
|
54700
|
+
kind: "mutation",
|
|
54701
|
+
auth: "admin"
|
|
54424
54702
|
});
|
|
54425
54703
|
/**
|
|
54426
54704
|
* `smtp-provider` — pluggable email delivery surface.
|
|
@@ -56822,7 +57100,9 @@ var ManifestShapeSchema = object({
|
|
|
56822
57100
|
icon: string().optional()
|
|
56823
57101
|
}).optional(),
|
|
56824
57102
|
protected: boolean().optional(),
|
|
56825
|
-
removable: boolean().optional()
|
|
57103
|
+
removable: boolean().optional(),
|
|
57104
|
+
/** Declared Integrations-page block (mirror of `AddonDeclaration.integrationSection`). */
|
|
57105
|
+
integrationSection: _enum(["system", "providers"]).optional()
|
|
56826
57106
|
});
|
|
56827
57107
|
var AddonProcessSchema = object({
|
|
56828
57108
|
pid: number().optional(),
|
|
@@ -57551,11 +57831,373 @@ DeviceType.Light, method(object({
|
|
|
57551
57831
|
level: number().min(0).max(100),
|
|
57552
57832
|
lastChangedAt: number()
|
|
57553
57833
|
});
|
|
57834
|
+
/**
|
|
57835
|
+
* The role vocabulary of a remote (D963): what a button MEANS, independent of
|
|
57836
|
+
* how it is wired. A layout template places buttons by role; a device binds a
|
|
57837
|
+
* role to an action; an exporter asks for a role by name. Roles are shared so
|
|
57838
|
+
* one layout fits every appliance and one voice command fits every binding.
|
|
57839
|
+
*
|
|
57840
|
+
* A role outside this list is `custom:<key>` — the operator's own button (a
|
|
57841
|
+
* SmartIR source, a channel preset). The key is a lowercase slug.
|
|
57842
|
+
*/
|
|
57843
|
+
var REMOTE_KNOWN_ROLES = [
|
|
57844
|
+
"power",
|
|
57845
|
+
"power_on",
|
|
57846
|
+
"power_off",
|
|
57847
|
+
"volume_up",
|
|
57848
|
+
"volume_down",
|
|
57849
|
+
"mute",
|
|
57850
|
+
"channel_up",
|
|
57851
|
+
"channel_down",
|
|
57852
|
+
"up",
|
|
57853
|
+
"down",
|
|
57854
|
+
"left",
|
|
57855
|
+
"right",
|
|
57856
|
+
"ok",
|
|
57857
|
+
"back",
|
|
57858
|
+
"home",
|
|
57859
|
+
"menu",
|
|
57860
|
+
"info",
|
|
57861
|
+
"guide",
|
|
57862
|
+
"exit",
|
|
57863
|
+
"input",
|
|
57864
|
+
"play",
|
|
57865
|
+
"pause",
|
|
57866
|
+
"play_pause",
|
|
57867
|
+
"stop",
|
|
57868
|
+
"next",
|
|
57869
|
+
"previous",
|
|
57870
|
+
"fast_forward",
|
|
57871
|
+
"rewind",
|
|
57872
|
+
"digit_0",
|
|
57873
|
+
"digit_1",
|
|
57874
|
+
"digit_2",
|
|
57875
|
+
"digit_3",
|
|
57876
|
+
"digit_4",
|
|
57877
|
+
"digit_5",
|
|
57878
|
+
"digit_6",
|
|
57879
|
+
"digit_7",
|
|
57880
|
+
"digit_8",
|
|
57881
|
+
"digit_9"
|
|
57882
|
+
];
|
|
57883
|
+
var CUSTOM_KEY_RE = /^[a-z0-9][a-z0-9_]{0,47}$/;
|
|
57884
|
+
var KNOWN_ROLES = new Set(REMOTE_KNOWN_ROLES);
|
|
57885
|
+
function isRemoteKnownRole(value) {
|
|
57886
|
+
return KNOWN_ROLES.has(value);
|
|
57887
|
+
}
|
|
57888
|
+
function isRemoteCustomKey(key) {
|
|
57889
|
+
return CUSTOM_KEY_RE.test(key);
|
|
57890
|
+
}
|
|
57891
|
+
/** The key of a `custom:<key>` role, or null for any other string. */
|
|
57892
|
+
function customKeyOfRole(role) {
|
|
57893
|
+
if (!role.startsWith("custom:")) return null;
|
|
57894
|
+
const key = role.slice(7);
|
|
57895
|
+
return isRemoteCustomKey(key) ? key : null;
|
|
57896
|
+
}
|
|
57897
|
+
function isRemoteRole(value) {
|
|
57898
|
+
return isRemoteKnownRole(value) || customKeyOfRole(value) !== null;
|
|
57899
|
+
}
|
|
57900
|
+
var RemoteRoleSchema = string().refine(isRemoteRole, { message: "a role is one of the known roles or custom:<key> (lowercase letters, digits, _)" });
|
|
57901
|
+
var RemoteBindingSchema = object({ action: AutomationCapStepSchema.extend({ deviceId: number().int().nonnegative() }) });
|
|
57902
|
+
var RemoteCustomButtonSchema = object({
|
|
57903
|
+
/** The slug after `custom:` in the role. */
|
|
57904
|
+
key: string().refine(isRemoteCustomKey, { message: "a lowercase slug" }),
|
|
57905
|
+
/** What the operator calls it, and what a voice command may name. */
|
|
57906
|
+
name: string().min(1).max(60)
|
|
57907
|
+
});
|
|
57908
|
+
var RemotePowerModeSchema = _enum(["toggle", "discrete"]);
|
|
57909
|
+
var RemoteConfigSchema = object({
|
|
57910
|
+
layoutTemplateId: string().min(1).nullable(),
|
|
57911
|
+
/**
|
|
57912
|
+
* The transmitter device new bindings and an import send through. A binding
|
|
57913
|
+
* names its own device, so one command may override it.
|
|
57914
|
+
*/
|
|
57915
|
+
defaultTransmitterId: number().int().nonnegative().nullable().default(null),
|
|
57916
|
+
/** Keyed by role. A role with no entry falls back to the native cap. */
|
|
57917
|
+
bindings: record(string(), RemoteBindingSchema),
|
|
57918
|
+
customButtons: array(RemoteCustomButtonSchema).max(100),
|
|
57919
|
+
power: object({ mode: RemotePowerModeSchema })
|
|
57920
|
+
}).superRefine((config, ctx) => {
|
|
57921
|
+
const roles = Object.keys(config.bindings);
|
|
57922
|
+
if (roles.length > 200) ctx.addIssue({
|
|
57923
|
+
code: "custom",
|
|
57924
|
+
message: "too many bindings",
|
|
57925
|
+
path: ["bindings"]
|
|
57926
|
+
});
|
|
57927
|
+
for (const role of roles) if (!isRemoteRole(role)) ctx.addIssue({
|
|
57928
|
+
code: "custom",
|
|
57929
|
+
message: `"${role}" is not a role`,
|
|
57930
|
+
path: ["bindings", role]
|
|
57931
|
+
});
|
|
57932
|
+
const keys = /* @__PURE__ */ new Set();
|
|
57933
|
+
config.customButtons.forEach((button, index) => {
|
|
57934
|
+
if (keys.has(button.key)) ctx.addIssue({
|
|
57935
|
+
code: "custom",
|
|
57936
|
+
message: `custom button "${button.key}" is listed twice`,
|
|
57937
|
+
path: [
|
|
57938
|
+
"customButtons",
|
|
57939
|
+
index,
|
|
57940
|
+
"key"
|
|
57941
|
+
]
|
|
57942
|
+
});
|
|
57943
|
+
keys.add(button.key);
|
|
57944
|
+
});
|
|
57945
|
+
for (const role of roles) {
|
|
57946
|
+
const key = customKeyOfRole(role);
|
|
57947
|
+
if (key !== null && !keys.has(key)) ctx.addIssue({
|
|
57948
|
+
code: "custom",
|
|
57949
|
+
message: `${role} is bound but has no entry in customButtons`,
|
|
57950
|
+
path: ["bindings", role]
|
|
57951
|
+
});
|
|
57952
|
+
}
|
|
57953
|
+
});
|
|
57954
|
+
object({
|
|
57955
|
+
power: object({
|
|
57956
|
+
state: _enum(["on", "off"]),
|
|
57957
|
+
at: number()
|
|
57958
|
+
}).nullable(),
|
|
57959
|
+
muted: object({
|
|
57960
|
+
value: boolean(),
|
|
57961
|
+
at: number()
|
|
57962
|
+
}).nullable()
|
|
57963
|
+
});
|
|
57964
|
+
var RemoteLayoutButtonSchema = object({
|
|
57965
|
+
id: string().min(1).max(40),
|
|
57966
|
+
/** 0-based grid position. */
|
|
57967
|
+
row: number().int().min(0).max(24),
|
|
57968
|
+
col: number().int().min(0).max(24),
|
|
57969
|
+
rowSpan: number().int().min(1).max(24),
|
|
57970
|
+
colSpan: number().int().min(1).max(24),
|
|
57971
|
+
icon: string().min(1).max(60).optional(),
|
|
57972
|
+
label: string().min(1).max(40).optional(),
|
|
57973
|
+
role: RemoteRoleSchema
|
|
57974
|
+
});
|
|
57975
|
+
object({
|
|
57976
|
+
columns: number().int().min(1).max(24),
|
|
57977
|
+
rows: number().int().min(1).max(24),
|
|
57978
|
+
buttons: array(RemoteLayoutButtonSchema).max(200)
|
|
57979
|
+
}).superRefine((grid, ctx) => {
|
|
57980
|
+
const ids = /* @__PURE__ */ new Set();
|
|
57981
|
+
const taken = /* @__PURE__ */ new Map();
|
|
57982
|
+
grid.buttons.forEach((button, index) => {
|
|
57983
|
+
if (ids.has(button.id)) ctx.addIssue({
|
|
57984
|
+
code: "custom",
|
|
57985
|
+
message: `button id "${button.id}" is used twice`,
|
|
57986
|
+
path: [
|
|
57987
|
+
"buttons",
|
|
57988
|
+
index,
|
|
57989
|
+
"id"
|
|
57990
|
+
]
|
|
57991
|
+
});
|
|
57992
|
+
ids.add(button.id);
|
|
57993
|
+
if (button.row + button.rowSpan > grid.rows || button.col + button.colSpan > grid.columns) {
|
|
57994
|
+
ctx.addIssue({
|
|
57995
|
+
code: "custom",
|
|
57996
|
+
message: `button "${button.id}" leaves the grid`,
|
|
57997
|
+
path: ["buttons", index]
|
|
57998
|
+
});
|
|
57999
|
+
return;
|
|
58000
|
+
}
|
|
58001
|
+
for (let r = button.row; r < button.row + button.rowSpan; r += 1) for (let c = button.col; c < button.col + button.colSpan; c += 1) {
|
|
58002
|
+
const cell = `${r}:${c}`;
|
|
58003
|
+
const other = taken.get(cell);
|
|
58004
|
+
if (other !== void 0) {
|
|
58005
|
+
ctx.addIssue({
|
|
58006
|
+
code: "custom",
|
|
58007
|
+
message: `buttons "${other}" and "${button.id}" overlap`,
|
|
58008
|
+
path: ["buttons", index]
|
|
58009
|
+
});
|
|
58010
|
+
return;
|
|
58011
|
+
}
|
|
58012
|
+
taken.set(cell, button.id);
|
|
58013
|
+
}
|
|
58014
|
+
});
|
|
58015
|
+
});
|
|
58016
|
+
var RemoteBoundCommandSchema = object({
|
|
58017
|
+
role: RemoteRoleSchema,
|
|
58018
|
+
/** The operator's name for a custom button; absent for a known role. */
|
|
58019
|
+
label: string().optional(),
|
|
58020
|
+
custom: boolean()
|
|
58021
|
+
});
|
|
58022
|
+
var RemoteCommandListSchema = object({
|
|
58023
|
+
layoutTemplateId: string().nullable(),
|
|
58024
|
+
power: object({ mode: RemotePowerModeSchema }),
|
|
58025
|
+
/** Only the roles that are BOUND — the ones a press can reach. */
|
|
58026
|
+
commands: array(RemoteBoundCommandSchema)
|
|
58027
|
+
});
|
|
58028
|
+
var RemoteRefusalReasonSchema = _enum([
|
|
58029
|
+
"no-remote",
|
|
58030
|
+
"unbound-role",
|
|
58031
|
+
"action-failed"
|
|
58032
|
+
]);
|
|
58033
|
+
var RemoteSendResultSchema = discriminatedUnion("status", [
|
|
58034
|
+
object({
|
|
58035
|
+
status: literal("sent"),
|
|
58036
|
+
/** How many times the action ran. */
|
|
58037
|
+
sends: number().int().min(1)
|
|
58038
|
+
}),
|
|
58039
|
+
object({
|
|
58040
|
+
status: literal("skipped"),
|
|
58041
|
+
reason: literal("already-in-state")
|
|
58042
|
+
}),
|
|
58043
|
+
object({
|
|
58044
|
+
status: literal("refused"),
|
|
58045
|
+
reason: RemoteRefusalReasonSchema,
|
|
58046
|
+
detail: string().optional()
|
|
58047
|
+
})
|
|
58048
|
+
]);
|
|
58049
|
+
var RemoteMediaCommandSchema = _enum([
|
|
58050
|
+
"play",
|
|
58051
|
+
"pause",
|
|
58052
|
+
"stop",
|
|
58053
|
+
"next",
|
|
58054
|
+
"previous",
|
|
58055
|
+
"setMute",
|
|
58056
|
+
"selectSource"
|
|
58057
|
+
]);
|
|
58058
|
+
/** A send result, or `not-routed`: the role is not bound, so the native cap answers. */
|
|
58059
|
+
var RemoteMediaCommandResultSchema = discriminatedUnion("status", [...RemoteSendResultSchema.options, object({ status: literal("not-routed") })]);
|
|
58060
|
+
var RemoteSetConfigResultSchema = discriminatedUnion("status", [object({ status: literal("saved") }), object({
|
|
58061
|
+
status: literal("refused"),
|
|
58062
|
+
reason: _enum(["unknown-template", "not-a-media-player"]),
|
|
58063
|
+
detail: string()
|
|
58064
|
+
})]);
|
|
58065
|
+
var deviceInput = object({ deviceId: number().int().nonnegative() });
|
|
58066
|
+
DeviceType.MediaPlayer;
|
|
58067
|
+
method(deviceInput, RemoteConfigSchema, { auth: "admin" }), method(deviceInput.extend({ config: RemoteConfigSchema }), RemoteSetConfigResultSchema, {
|
|
58068
|
+
kind: "mutation",
|
|
58069
|
+
auth: "admin"
|
|
58070
|
+
}), method(deviceInput, RemoteCommandListSchema, { auth: "protected" }), method(deviceInput.extend({
|
|
58071
|
+
role: RemoteRoleSchema,
|
|
58072
|
+
/** Sends in a row (volume steps). */
|
|
58073
|
+
repeat: number().int().min(1).max(50).default(1)
|
|
58074
|
+
}), RemoteSendResultSchema, {
|
|
58075
|
+
kind: "mutation",
|
|
58076
|
+
auth: "protected"
|
|
58077
|
+
}), method(deviceInput.extend({
|
|
58078
|
+
command: RemoteMediaCommandSchema,
|
|
58079
|
+
muted: boolean().optional(),
|
|
58080
|
+
source: string().optional(),
|
|
58081
|
+
repeat: number().int().min(1).max(50).default(1)
|
|
58082
|
+
}), RemoteMediaCommandResultSchema, {
|
|
58083
|
+
kind: "mutation",
|
|
58084
|
+
auth: "protected"
|
|
58085
|
+
});
|
|
58086
|
+
var TemplateKindSchema = _enum(["remote"]);
|
|
58087
|
+
/**
|
|
58088
|
+
* template — the generic store of reusable, named operator data (D963). A
|
|
58089
|
+
* record is `{ id, kind, name, payload }`; the kinds (today only `remote`, the
|
|
58090
|
+
* button grid of a remote) and the schema each payload must satisfy are
|
|
58091
|
+
* declared by the system in `template-kinds.ts`. Nothing here is specific to a
|
|
58092
|
+
* kind: the engine validates a payload against its kind's schema and, on a
|
|
58093
|
+
* delete, asks the kind's owner whether anything still points at the record.
|
|
58094
|
+
*
|
|
58095
|
+
* Every refusal is a typed result — a UI says "unknown kind" or names the
|
|
58096
|
+
* devices that still use a template, without parsing text.
|
|
58097
|
+
*/
|
|
58098
|
+
var TemplateRecordSchema = object({
|
|
58099
|
+
id: string().min(1),
|
|
58100
|
+
kind: TemplateKindSchema,
|
|
58101
|
+
name: string().min(1).max(120),
|
|
58102
|
+
/** Shaped by the kind; `checkTemplatePayload(kind, payload)` reads it. */
|
|
58103
|
+
payload: unknown(),
|
|
58104
|
+
createdAt: number(),
|
|
58105
|
+
updatedAt: number()
|
|
58106
|
+
});
|
|
58107
|
+
var TemplateWriteResultSchema = discriminatedUnion("status", [object({
|
|
58108
|
+
status: literal("saved"),
|
|
58109
|
+
template: TemplateRecordSchema
|
|
58110
|
+
}), object({
|
|
58111
|
+
status: literal("refused"),
|
|
58112
|
+
reason: _enum(["invalid-payload", "not-found"]),
|
|
58113
|
+
detail: string()
|
|
58114
|
+
})]);
|
|
58115
|
+
/** A device still pointing at a template. */
|
|
58116
|
+
var TemplateUserSchema = object({
|
|
58117
|
+
deviceId: number().int().nonnegative(),
|
|
58118
|
+
name: string()
|
|
58119
|
+
});
|
|
58120
|
+
var TemplateDeleteResultSchema = discriminatedUnion("status", [
|
|
58121
|
+
object({ status: literal("deleted") }),
|
|
58122
|
+
object({ status: literal("not-found") }),
|
|
58123
|
+
object({
|
|
58124
|
+
status: literal("in-use"),
|
|
58125
|
+
devices: array(TemplateUserSchema).min(1)
|
|
58126
|
+
})
|
|
58127
|
+
]);
|
|
58128
|
+
method(object({ kind: TemplateKindSchema.optional() }), array(TemplateRecordSchema), { auth: "protected" }), method(object({ id: string().min(1) }), TemplateRecordSchema.nullable(), { auth: "protected" }), method(object({
|
|
58129
|
+
kind: TemplateKindSchema,
|
|
58130
|
+
name: string().min(1).max(120),
|
|
58131
|
+
payload: unknown()
|
|
58132
|
+
}), TemplateWriteResultSchema, {
|
|
58133
|
+
kind: "mutation",
|
|
58134
|
+
auth: "admin"
|
|
58135
|
+
}), method(object({
|
|
58136
|
+
id: string().min(1),
|
|
58137
|
+
name: string().min(1).max(120).optional(),
|
|
58138
|
+
payload: unknown().optional()
|
|
58139
|
+
}), TemplateWriteResultSchema, {
|
|
58140
|
+
kind: "mutation",
|
|
58141
|
+
auth: "admin"
|
|
58142
|
+
}), method(object({ id: string().min(1) }), TemplateDeleteResultSchema, {
|
|
58143
|
+
kind: "mutation",
|
|
58144
|
+
auth: "admin"
|
|
58145
|
+
});
|
|
57554
58146
|
DeviceType.Button, method(object({ deviceId: number().int().nonnegative() }), _void(), {
|
|
57555
58147
|
kind: "mutation",
|
|
57556
58148
|
auth: "protected"
|
|
57557
58149
|
});
|
|
57558
58150
|
/**
|
|
58151
|
+
* A pulse train in signed microseconds: mark (+) first, then space (-), strictly
|
|
58152
|
+
* alternating, no zeros, 2..1024 entries.
|
|
58153
|
+
*/
|
|
58154
|
+
var IrTimingsSchema = array(number().int()).min(2).max(1024).superRefine((timings, ctx) => {
|
|
58155
|
+
timings.forEach((value, index) => {
|
|
58156
|
+
const expectMark = index % 2 === 0;
|
|
58157
|
+
if (value === 0 || value > 0 !== expectMark) ctx.addIssue({
|
|
58158
|
+
code: "custom",
|
|
58159
|
+
message: `timing ${index} must be a non-zero ${expectMark ? "mark (positive)" : "space (negative)"}`,
|
|
58160
|
+
path: [index]
|
|
58161
|
+
});
|
|
58162
|
+
});
|
|
58163
|
+
});
|
|
58164
|
+
/** Per-command transmit options. Every key is optional; a transmitter applies what it can. */
|
|
58165
|
+
var TransmitSettingsSchema = object({
|
|
58166
|
+
carrierHz: number().int().positive().optional(),
|
|
58167
|
+
dutyCyclePercent: number().int().min(1).max(100).optional(),
|
|
58168
|
+
repeat: number().int().min(0).max(20).optional(),
|
|
58169
|
+
repeatDelayMs: number().int().min(0).optional()
|
|
58170
|
+
});
|
|
58171
|
+
/** The setting keys a transmitter may declare as settable (`getInfo.settable`). */
|
|
58172
|
+
var TransmitSettingKeySchema = _enum([
|
|
58173
|
+
"carrierHz",
|
|
58174
|
+
"dutyCyclePercent",
|
|
58175
|
+
"repeat",
|
|
58176
|
+
"repeatDelayMs"
|
|
58177
|
+
]);
|
|
58178
|
+
var IrMediumSchema = _enum(["ir", "rf"]);
|
|
58179
|
+
var IrSendResultSchema = object({
|
|
58180
|
+
ok: literal(true),
|
|
58181
|
+
/** Settings the transmitter could not apply; the train was still sent. */
|
|
58182
|
+
ignoredSettings: array(string())
|
|
58183
|
+
});
|
|
58184
|
+
var IrTransmitterInfoSchema = object({
|
|
58185
|
+
media: array(IrMediumSchema),
|
|
58186
|
+
settable: array(TransmitSettingKeySchema),
|
|
58187
|
+
maxTimings: number().int().positive()
|
|
58188
|
+
});
|
|
58189
|
+
DeviceType.Generic, method(object({
|
|
58190
|
+
deviceId: number().int().nonnegative(),
|
|
58191
|
+
timings: IrTimingsSchema,
|
|
58192
|
+
settings: TransmitSettingsSchema.optional()
|
|
58193
|
+
}), IrSendResultSchema, {
|
|
58194
|
+
kind: "mutation",
|
|
58195
|
+
auth: "protected"
|
|
58196
|
+
}), method(object({ deviceId: number().int().nonnegative() }), IrTransmitterInfoSchema, {
|
|
58197
|
+
kind: "query",
|
|
58198
|
+
auth: "protected"
|
|
58199
|
+
});
|
|
58200
|
+
/**
|
|
57559
58201
|
* `calendar-source` — collection cap exposing per-provider calendars and
|
|
57560
58202
|
* their events. Every addon that contributes calendars (Home Assistant,
|
|
57561
58203
|
* a future Google Calendar addon, …) registers a provider here. The hub
|
|
@@ -58559,7 +59201,7 @@ object({
|
|
|
58559
59201
|
/** Ms epoch of the last value received from the appliance; 0 = never. */
|
|
58560
59202
|
lastFetchedAt: number()
|
|
58561
59203
|
});
|
|
58562
|
-
var DeviceIdSchema = number().int().nonnegative();
|
|
59204
|
+
var DeviceIdSchema$1 = number().int().nonnegative();
|
|
58563
59205
|
/** A value a program option or setting can take. */
|
|
58564
59206
|
var DishwasherValueSchema = union([
|
|
58565
59207
|
boolean(),
|
|
@@ -58623,77 +59265,77 @@ var DishwasherOptionsSchema = object({
|
|
|
58623
59265
|
options: array(DishwasherOptionDescriptorSchema)
|
|
58624
59266
|
});
|
|
58625
59267
|
DeviceType.Dishwasher, method(object({
|
|
58626
|
-
deviceId: DeviceIdSchema,
|
|
59268
|
+
deviceId: DeviceIdSchema$1,
|
|
58627
59269
|
program: string().min(1).optional(),
|
|
58628
59270
|
options: record(string(), DishwasherValueSchema).optional()
|
|
58629
59271
|
}), _void(), {
|
|
58630
59272
|
kind: "mutation",
|
|
58631
59273
|
auth: "protected"
|
|
58632
|
-
}), method(object({ deviceId: DeviceIdSchema }), _void(), {
|
|
59274
|
+
}), method(object({ deviceId: DeviceIdSchema$1 }), _void(), {
|
|
58633
59275
|
kind: "mutation",
|
|
58634
59276
|
auth: "protected"
|
|
58635
|
-
}), method(object({ deviceId: DeviceIdSchema }), _void(), {
|
|
59277
|
+
}), method(object({ deviceId: DeviceIdSchema$1 }), _void(), {
|
|
58636
59278
|
kind: "mutation",
|
|
58637
59279
|
auth: "protected"
|
|
58638
|
-
}), method(object({ deviceId: DeviceIdSchema }), _void(), {
|
|
59280
|
+
}), method(object({ deviceId: DeviceIdSchema$1 }), _void(), {
|
|
58639
59281
|
kind: "mutation",
|
|
58640
59282
|
auth: "protected"
|
|
58641
59283
|
}), method(object({
|
|
58642
|
-
deviceId: DeviceIdSchema,
|
|
59284
|
+
deviceId: DeviceIdSchema$1,
|
|
58643
59285
|
program: string().min(1)
|
|
58644
59286
|
}), _void(), {
|
|
58645
59287
|
kind: "mutation",
|
|
58646
59288
|
auth: "protected"
|
|
58647
59289
|
}), method(object({
|
|
58648
|
-
deviceId: DeviceIdSchema,
|
|
59290
|
+
deviceId: DeviceIdSchema$1,
|
|
58649
59291
|
on: boolean()
|
|
58650
59292
|
}), _void(), {
|
|
58651
59293
|
kind: "mutation",
|
|
58652
59294
|
auth: "protected"
|
|
58653
59295
|
}), method(object({
|
|
58654
|
-
deviceId: DeviceIdSchema,
|
|
59296
|
+
deviceId: DeviceIdSchema$1,
|
|
58655
59297
|
on: boolean()
|
|
58656
59298
|
}), _void(), {
|
|
58657
59299
|
kind: "mutation",
|
|
58658
59300
|
auth: "protected"
|
|
58659
59301
|
}), method(object({
|
|
58660
|
-
deviceId: DeviceIdSchema,
|
|
59302
|
+
deviceId: DeviceIdSchema$1,
|
|
58661
59303
|
on: boolean()
|
|
58662
59304
|
}), _void(), {
|
|
58663
59305
|
kind: "mutation",
|
|
58664
59306
|
auth: "protected"
|
|
58665
59307
|
}), method(object({
|
|
58666
|
-
deviceId: DeviceIdSchema,
|
|
59308
|
+
deviceId: DeviceIdSchema$1,
|
|
58667
59309
|
on: boolean()
|
|
58668
59310
|
}), _void(), {
|
|
58669
59311
|
kind: "mutation",
|
|
58670
59312
|
auth: "protected"
|
|
58671
59313
|
}), method(object({
|
|
58672
|
-
deviceId: DeviceIdSchema,
|
|
59314
|
+
deviceId: DeviceIdSchema$1,
|
|
58673
59315
|
on: boolean()
|
|
58674
59316
|
}), _void(), {
|
|
58675
59317
|
kind: "mutation",
|
|
58676
59318
|
auth: "protected"
|
|
58677
59319
|
}), method(object({
|
|
58678
|
-
deviceId: DeviceIdSchema,
|
|
59320
|
+
deviceId: DeviceIdSchema$1,
|
|
58679
59321
|
on: boolean()
|
|
58680
59322
|
}), _void(), {
|
|
58681
59323
|
kind: "mutation",
|
|
58682
59324
|
auth: "protected"
|
|
58683
59325
|
}), method(object({
|
|
58684
|
-
deviceId: DeviceIdSchema,
|
|
59326
|
+
deviceId: DeviceIdSchema$1,
|
|
58685
59327
|
on: boolean()
|
|
58686
59328
|
}), _void(), {
|
|
58687
59329
|
kind: "mutation",
|
|
58688
59330
|
auth: "protected"
|
|
58689
59331
|
}), method(object({
|
|
58690
|
-
deviceId: DeviceIdSchema,
|
|
59332
|
+
deviceId: DeviceIdSchema$1,
|
|
58691
59333
|
key: string().min(1),
|
|
58692
59334
|
value: DishwasherValueSchema
|
|
58693
59335
|
}), _void(), {
|
|
58694
59336
|
kind: "mutation",
|
|
58695
59337
|
auth: "protected"
|
|
58696
|
-
}), method(object({ deviceId: DeviceIdSchema }), DishwasherOptionsSchema, { auth: "protected" });
|
|
59338
|
+
}), method(object({ deviceId: DeviceIdSchema$1 }), DishwasherOptionsSchema, { auth: "protected" });
|
|
58697
59339
|
DeviceType.Camera;
|
|
58698
59340
|
object({
|
|
58699
59341
|
/** Ms epoch of the last press. null = never observed since this provider started. */
|
|
@@ -60250,9 +60892,35 @@ var MediaInfoSchema = object({
|
|
|
60250
60892
|
/** Optional cover-art / thumbnail URL. */
|
|
60251
60893
|
imageUrl: string().optional()
|
|
60252
60894
|
});
|
|
60895
|
+
/**
|
|
60896
|
+
* Where `state`, `volumeLevel`, `isMuted` and `source` come from. `reported`:
|
|
60897
|
+
* the device said so. `assumed`: the driver has no feedback (infrared) and
|
|
60898
|
+
* tracks what it last SENT; it moves only after a send was accepted, and a
|
|
60899
|
+
* human at the real remote makes it wrong. A UI shows an assumed value as a
|
|
60900
|
+
* guess, never as a reading.
|
|
60901
|
+
*/
|
|
60902
|
+
var MediaPlayerStateSourceSchema = _enum(["reported", "assumed"]);
|
|
60903
|
+
/** The fields of a media-player status a driver can only guess. */
|
|
60904
|
+
var MediaPlayerAssumedFieldSchema = _enum([
|
|
60905
|
+
"state",
|
|
60906
|
+
"volumeLevel",
|
|
60907
|
+
"isMuted",
|
|
60908
|
+
"source"
|
|
60909
|
+
]);
|
|
60253
60910
|
object({
|
|
60254
60911
|
/** Playback lifecycle state. */
|
|
60255
60912
|
state: MediaPlayerStateSchema,
|
|
60913
|
+
/**
|
|
60914
|
+
* Whether the state fields are readings or the driver's own bookkeeping.
|
|
60915
|
+
* A slice written before this field existed parses as `reported`.
|
|
60916
|
+
*/
|
|
60917
|
+
stateSource: MediaPlayerStateSourceSchema.default("reported"),
|
|
60918
|
+
/**
|
|
60919
|
+
* Which fields are the driver's own guess. `stateSource` is `assumed` when
|
|
60920
|
+
* this is not empty; a field not listed here is a reading even then (power
|
|
60921
|
+
* from a running-state source, mute guessed from the last send).
|
|
60922
|
+
*/
|
|
60923
|
+
assumedFields: array(MediaPlayerAssumedFieldSchema).default([]),
|
|
60256
60924
|
/** Volume as 0..100 inclusive. Null when the device has no volume
|
|
60257
60925
|
* surface. Pair with `DeviceFeature.MediaPlayerVolume`. */
|
|
60258
60926
|
volumeLevel: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
@@ -61105,7 +61773,8 @@ var TopologyNodeSchema = object({
|
|
|
61105
61773
|
isHub: boolean(),
|
|
61106
61774
|
isOnline: boolean(),
|
|
61107
61775
|
cpuPercent: number(),
|
|
61108
|
-
|
|
61776
|
+
/** `null` when the node's memory read failed or it has not reported one (D393). */
|
|
61777
|
+
memoryPercent: number().nullable(),
|
|
61109
61778
|
uptime: number(),
|
|
61110
61779
|
lastSeen: string(),
|
|
61111
61780
|
localIps: array(string()).readonly(),
|
|
@@ -61640,9 +62309,10 @@ object({
|
|
|
61640
62309
|
* combined reading; per-hopper levels live in `food1`/`food2`. Null when
|
|
61641
62310
|
* the device has not reported yet. */
|
|
61642
62311
|
foodLevel: number().nullable().meta(readingMeta("none")),
|
|
61643
|
-
/** Food in the BOWL
|
|
61644
|
-
* feeder
|
|
61645
|
-
|
|
62312
|
+
/** Food in the BOWL, a mass (stored in kilograms, D944). Reported only by a
|
|
62313
|
+
* feeder with a bowl scale; null when the model has none or its reading is
|
|
62314
|
+
* of an unproven unit. */
|
|
62315
|
+
bowlFood: number().nullable().meta(readingMeta("mass")),
|
|
61646
62316
|
/** True while the pet is eating (`state.eating`). */
|
|
61647
62317
|
eating: boolean(),
|
|
61648
62318
|
/** Whether `markFoodReplenished` does anything on this model. When false
|
|
@@ -61658,9 +62328,14 @@ object({
|
|
|
61658
62328
|
* (`device_class: problem`, on = low). True when the tank reports empty,
|
|
61659
62329
|
* or, on a dual-hopper model, when EITHER hopper is empty. */
|
|
61660
62330
|
lowFood: boolean(),
|
|
61661
|
-
/** Battery charge 0..100 (%).
|
|
61662
|
-
*
|
|
62331
|
+
/** Battery charge 0..100 (%). On a feeder running on `mains` this is the
|
|
62332
|
+
* BACKUP battery's charge, not the power source. Null when the device has
|
|
62333
|
+
* no battery reading. */
|
|
61663
62334
|
batteryPower: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
62335
|
+
/** What the feeder is powered from right now: `mains` (plugged in, the
|
|
62336
|
+
* battery is only a backup) or `battery`. Null when the device does not
|
|
62337
|
+
* report it. */
|
|
62338
|
+
powerSource: _enum(["mains", "battery"]).nullable(),
|
|
61664
62339
|
/**
|
|
61665
62340
|
* Desiccant life remaining, stored in seconds (duration base, D944).
|
|
61666
62341
|
* Providers convert from the days the feeder reports. Null when the
|
|
@@ -61688,6 +62363,14 @@ object({
|
|
|
61688
62363
|
feedSound: boolean(),
|
|
61689
62364
|
/** Speaker / prompt volume level (device-scaled integer). */
|
|
61690
62365
|
volume: number().meta(readingMeta("none")),
|
|
62366
|
+
/** Portion (grams) of the last manual feed sent from a single-hopper
|
|
62367
|
+
* stepper — the default the next manual feed starts from. Persisted per
|
|
62368
|
+
* device by the provider; null until a manual feed has been sent. */
|
|
62369
|
+
lastFeedGrams: gramsPortion.nullable(),
|
|
62370
|
+
/** Hopper-1 portion of the last manual feed (dual-hopper); null until sent. */
|
|
62371
|
+
lastFeedHopper1: gramsPortion.nullable(),
|
|
62372
|
+
/** Hopper-2 portion of the last manual feed (dual-hopper); null until sent. */
|
|
62373
|
+
lastFeedHopper2: gramsPortion.nullable(),
|
|
61691
62374
|
/** Ms epoch when the slice was last refreshed from the cloud. */
|
|
61692
62375
|
lastFetchedAt: number()
|
|
61693
62376
|
});
|
|
@@ -61742,6 +62425,64 @@ DeviceType.PetFeeder, method(object({
|
|
|
61742
62425
|
kind: "mutation",
|
|
61743
62426
|
auth: "protected"
|
|
61744
62427
|
});
|
|
62428
|
+
object({
|
|
62429
|
+
/** Water in the tank, 0..100 (%). Null while the source has not reported. */
|
|
62430
|
+
waterLevel: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
62431
|
+
/** Water in the tank, in litres. Null while the source has not reported. */
|
|
62432
|
+
waterVolume: number().min(0).nullable().meta(readingMeta("volume")),
|
|
62433
|
+
/** True when the tank is empty. Null while unknown. */
|
|
62434
|
+
empty: boolean().nullable(),
|
|
62435
|
+
/** True while the pump is running. Null while unknown. */
|
|
62436
|
+
pumpRunning: boolean().nullable(),
|
|
62437
|
+
/** True when the pump works on an on/off duty cycle rather than continuously. */
|
|
62438
|
+
pumpIntervalEnabled: boolean().nullable(),
|
|
62439
|
+
/** How long the pump runs per cycle, in seconds. */
|
|
62440
|
+
pumpOnTime: number().min(0).nullable().meta(readingMeta("duration")),
|
|
62441
|
+
/** How long the pump rests per cycle, in seconds. */
|
|
62442
|
+
pumpOffTime: number().min(0).nullable().meta(readingMeta("duration")),
|
|
62443
|
+
/** Water drunk in the last drink, in litres. */
|
|
62444
|
+
lastDrink: number().min(0).nullable().meta(readingMeta("volume")),
|
|
62445
|
+
/** Water drunk in the current hour, in litres. */
|
|
62446
|
+
currentHourDrink: number().min(0).nullable().meta(readingMeta("volume")),
|
|
62447
|
+
/** Water drunk over the last 24 hours (rolling), in litres. */
|
|
62448
|
+
last24hDrink: number().min(0).nullable().meta(readingMeta("volume")),
|
|
62449
|
+
/** Water drunk since local midnight, in litres. */
|
|
62450
|
+
todayDrink: number().min(0).nullable().meta(readingMeta("volume")),
|
|
62451
|
+
/** Decoded fault message. Null means healthy; a non-null string is an active fault. */
|
|
62452
|
+
error: string().nullable(),
|
|
62453
|
+
/** Ms epoch when the slice was last refreshed. */
|
|
62454
|
+
lastFetchedAt: number()
|
|
62455
|
+
});
|
|
62456
|
+
var DeviceIdSchema = number().int().nonnegative();
|
|
62457
|
+
var MinutesSchema = number().int().min(0);
|
|
62458
|
+
DeviceType.PetFountain, method(object({
|
|
62459
|
+
deviceId: DeviceIdSchema,
|
|
62460
|
+
on: boolean()
|
|
62461
|
+
}), _void(), {
|
|
62462
|
+
kind: "mutation",
|
|
62463
|
+
auth: "protected"
|
|
62464
|
+
}), method(object({
|
|
62465
|
+
deviceId: DeviceIdSchema,
|
|
62466
|
+
on: boolean()
|
|
62467
|
+
}), _void(), {
|
|
62468
|
+
kind: "mutation",
|
|
62469
|
+
auth: "protected"
|
|
62470
|
+
}), method(object({
|
|
62471
|
+
deviceId: DeviceIdSchema,
|
|
62472
|
+
minutes: MinutesSchema
|
|
62473
|
+
}), _void(), {
|
|
62474
|
+
kind: "mutation",
|
|
62475
|
+
auth: "protected"
|
|
62476
|
+
}), method(object({
|
|
62477
|
+
deviceId: DeviceIdSchema,
|
|
62478
|
+
minutes: MinutesSchema
|
|
62479
|
+
}), _void(), {
|
|
62480
|
+
kind: "mutation",
|
|
62481
|
+
auth: "protected"
|
|
62482
|
+
}), method(object({ deviceId: DeviceIdSchema }), _void(), {
|
|
62483
|
+
kind: "mutation",
|
|
62484
|
+
auth: "protected"
|
|
62485
|
+
});
|
|
61745
62486
|
var VehicleSchema = object({
|
|
61746
62487
|
id: string(),
|
|
61747
62488
|
name: string(),
|
|
@@ -66336,9 +67077,17 @@ method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" })
|
|
|
66336
67077
|
kind: "mutation",
|
|
66337
67078
|
auth: "admin"
|
|
66338
67079
|
});
|
|
67080
|
+
discriminatedUnion("kind", [object({
|
|
67081
|
+
kind: literal("raw"),
|
|
67082
|
+
timings: array(number().int()),
|
|
67083
|
+
settings: TransmitSettingsSchema.optional()
|
|
67084
|
+
}), object({
|
|
67085
|
+
kind: literal("pronto"),
|
|
67086
|
+
code: string()
|
|
67087
|
+
})]);
|
|
66339
67088
|
DeviceFeature.FanSpeed, DeviceFeature.FanPreset, DeviceFeature.FanDirection, DeviceFeature.FanOscillating, DeviceFeature.CoverPositionable, DeviceFeature.CoverTilt, DeviceFeature.ValvePositionable, DeviceFeature.MediaPlayerVolume, DeviceFeature.ClimateFanMode;
|
|
66340
67089
|
SOURCE_CAPS.filter((cap) => cap !== "switch" && cap !== "motion");
|
|
66341
|
-
DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
|
|
67090
|
+
DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
|
|
66342
67091
|
String.raw`rose\(active(\d+), changed(\d+), (\d+(?:\.\d+)?)\)`;
|
|
66343
67092
|
DeviceRole.BinarySensor, DeviceRole.MotionSensor;
|
|
66344
67093
|
new Set(CAP_NAMES);
|
|
@@ -66391,7 +67140,7 @@ var AccessoryKind = {
|
|
|
66391
67140
|
PrivacyMask: DeviceRole.PrivacyMask
|
|
66392
67141
|
};
|
|
66393
67142
|
AccessoryKind.Siren, AccessoryKind.Floodlight, AccessoryKind.Spotlight, AccessoryKind.PirSensor, AccessoryKind.Chime, AccessoryKind.Autotrack, AccessoryKind.Nightvision, AccessoryKind.PrivacyMask;
|
|
66394
|
-
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
|
|
67143
|
+
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
|
|
66395
67144
|
new Set(Object.values(DeviceType));
|
|
66396
67145
|
Object.freeze({
|
|
66397
67146
|
"accessories.getStatus": {
|
|
@@ -68326,6 +69075,13 @@ Object.freeze({
|
|
|
68326
69075
|
access: "create",
|
|
68327
69076
|
role: "admin"
|
|
68328
69077
|
},
|
|
69078
|
+
"deviceExport.exposeEntity": {
|
|
69079
|
+
capName: "device-export",
|
|
69080
|
+
capScope: "system",
|
|
69081
|
+
addonId: null,
|
|
69082
|
+
access: "create",
|
|
69083
|
+
role: "admin"
|
|
69084
|
+
},
|
|
68329
69085
|
"deviceExport.getDeviceLiveContribution": {
|
|
68330
69086
|
capName: "device-export",
|
|
68331
69087
|
capScope: "system",
|
|
@@ -68354,6 +69110,13 @@ Object.freeze({
|
|
|
68354
69110
|
access: "view",
|
|
68355
69111
|
role: "admin"
|
|
68356
69112
|
},
|
|
69113
|
+
"deviceExport.listExposedEntities": {
|
|
69114
|
+
capName: "device-export",
|
|
69115
|
+
capScope: "system",
|
|
69116
|
+
addonId: null,
|
|
69117
|
+
access: "view",
|
|
69118
|
+
role: "admin"
|
|
69119
|
+
},
|
|
68357
69120
|
"deviceExport.listSupportedDeviceKinds": {
|
|
68358
69121
|
capName: "device-export",
|
|
68359
69122
|
capScope: "system",
|
|
@@ -68361,6 +69124,13 @@ Object.freeze({
|
|
|
68361
69124
|
access: "view",
|
|
68362
69125
|
role: "admin"
|
|
68363
69126
|
},
|
|
69127
|
+
"deviceExport.listSupportedEntityKinds": {
|
|
69128
|
+
capName: "device-export",
|
|
69129
|
+
capScope: "system",
|
|
69130
|
+
addonId: null,
|
|
69131
|
+
access: "view",
|
|
69132
|
+
role: "admin"
|
|
69133
|
+
},
|
|
68364
69134
|
"deviceExport.unexposeDevice": {
|
|
68365
69135
|
capName: "device-export",
|
|
68366
69136
|
capScope: "system",
|
|
@@ -68368,6 +69138,13 @@ Object.freeze({
|
|
|
68368
69138
|
access: "create",
|
|
68369
69139
|
role: "admin"
|
|
68370
69140
|
},
|
|
69141
|
+
"deviceExport.unexposeEntity": {
|
|
69142
|
+
capName: "device-export",
|
|
69143
|
+
capScope: "system",
|
|
69144
|
+
addonId: null,
|
|
69145
|
+
access: "create",
|
|
69146
|
+
role: "admin"
|
|
69147
|
+
},
|
|
68371
69148
|
"deviceExtension.listCandidates": {
|
|
68372
69149
|
capName: "device-extension",
|
|
68373
69150
|
capScope: "device",
|
|
@@ -69943,6 +70720,20 @@ Object.freeze({
|
|
|
69943
70720
|
access: "create",
|
|
69944
70721
|
role: "viewer"
|
|
69945
70722
|
},
|
|
70723
|
+
"irTransmitter.getInfo": {
|
|
70724
|
+
capName: "ir-transmitter",
|
|
70725
|
+
capScope: "device",
|
|
70726
|
+
addonId: null,
|
|
70727
|
+
access: "view",
|
|
70728
|
+
role: "viewer"
|
|
70729
|
+
},
|
|
70730
|
+
"irTransmitter.send": {
|
|
70731
|
+
capName: "ir-transmitter",
|
|
70732
|
+
capScope: "device",
|
|
70733
|
+
addonId: null,
|
|
70734
|
+
access: "create",
|
|
70735
|
+
role: "viewer"
|
|
70736
|
+
},
|
|
69946
70737
|
"keychain.delete": {
|
|
69947
70738
|
capName: "keychain",
|
|
69948
70739
|
capScope: "system",
|
|
@@ -71175,6 +71966,13 @@ Object.freeze({
|
|
|
71175
71966
|
access: "create",
|
|
71176
71967
|
role: "admin"
|
|
71177
71968
|
},
|
|
71969
|
+
"nodeRemovalHook.onNodeRemoved": {
|
|
71970
|
+
capName: "node-removal-hook",
|
|
71971
|
+
capScope: "system",
|
|
71972
|
+
addonId: null,
|
|
71973
|
+
access: "create",
|
|
71974
|
+
role: "admin"
|
|
71975
|
+
},
|
|
71178
71976
|
"nodes.clusterAddonStatus": {
|
|
71179
71977
|
capName: "nodes",
|
|
71180
71978
|
capScope: "system",
|
|
@@ -71812,6 +72610,48 @@ Object.freeze({
|
|
|
71812
72610
|
access: "create",
|
|
71813
72611
|
role: "viewer"
|
|
71814
72612
|
},
|
|
72613
|
+
"petFountain.getStatus": {
|
|
72614
|
+
capName: "pet-fountain",
|
|
72615
|
+
capScope: "device",
|
|
72616
|
+
addonId: null,
|
|
72617
|
+
access: "view",
|
|
72618
|
+
role: "viewer"
|
|
72619
|
+
},
|
|
72620
|
+
"petFountain.resetDailyConsumption": {
|
|
72621
|
+
capName: "pet-fountain",
|
|
72622
|
+
capScope: "device",
|
|
72623
|
+
addonId: null,
|
|
72624
|
+
access: "delete",
|
|
72625
|
+
role: "viewer"
|
|
72626
|
+
},
|
|
72627
|
+
"petFountain.setPump": {
|
|
72628
|
+
capName: "pet-fountain",
|
|
72629
|
+
capScope: "device",
|
|
72630
|
+
addonId: null,
|
|
72631
|
+
access: "create",
|
|
72632
|
+
role: "viewer"
|
|
72633
|
+
},
|
|
72634
|
+
"petFountain.setPumpInterval": {
|
|
72635
|
+
capName: "pet-fountain",
|
|
72636
|
+
capScope: "device",
|
|
72637
|
+
addonId: null,
|
|
72638
|
+
access: "create",
|
|
72639
|
+
role: "viewer"
|
|
72640
|
+
},
|
|
72641
|
+
"petFountain.setPumpOffMinutes": {
|
|
72642
|
+
capName: "pet-fountain",
|
|
72643
|
+
capScope: "device",
|
|
72644
|
+
addonId: null,
|
|
72645
|
+
access: "create",
|
|
72646
|
+
role: "viewer"
|
|
72647
|
+
},
|
|
72648
|
+
"petFountain.setPumpOnMinutes": {
|
|
72649
|
+
capName: "pet-fountain",
|
|
72650
|
+
capScope: "device",
|
|
72651
|
+
addonId: null,
|
|
72652
|
+
access: "create",
|
|
72653
|
+
role: "viewer"
|
|
72654
|
+
},
|
|
71815
72655
|
"pipelineAnalytics.addRetrainFrameFromRecording": {
|
|
71816
72656
|
capName: "pipeline-analytics",
|
|
71817
72657
|
capScope: "device",
|
|
@@ -74066,6 +74906,41 @@ Object.freeze({
|
|
|
74066
74906
|
access: "create",
|
|
74067
74907
|
role: "admin"
|
|
74068
74908
|
},
|
|
74909
|
+
"remote.getConfig": {
|
|
74910
|
+
capName: "remote",
|
|
74911
|
+
capScope: "system",
|
|
74912
|
+
addonId: null,
|
|
74913
|
+
access: "view",
|
|
74914
|
+
role: "admin"
|
|
74915
|
+
},
|
|
74916
|
+
"remote.listCommands": {
|
|
74917
|
+
capName: "remote",
|
|
74918
|
+
capScope: "system",
|
|
74919
|
+
addonId: null,
|
|
74920
|
+
access: "view",
|
|
74921
|
+
role: "admin"
|
|
74922
|
+
},
|
|
74923
|
+
"remote.sendCommand": {
|
|
74924
|
+
capName: "remote",
|
|
74925
|
+
capScope: "system",
|
|
74926
|
+
addonId: null,
|
|
74927
|
+
access: "create",
|
|
74928
|
+
role: "admin"
|
|
74929
|
+
},
|
|
74930
|
+
"remote.sendMediaCommand": {
|
|
74931
|
+
capName: "remote",
|
|
74932
|
+
capScope: "system",
|
|
74933
|
+
addonId: null,
|
|
74934
|
+
access: "create",
|
|
74935
|
+
role: "admin"
|
|
74936
|
+
},
|
|
74937
|
+
"remote.setConfig": {
|
|
74938
|
+
capName: "remote",
|
|
74939
|
+
capScope: "system",
|
|
74940
|
+
addonId: null,
|
|
74941
|
+
access: "create",
|
|
74942
|
+
role: "admin"
|
|
74943
|
+
},
|
|
74069
74944
|
"runningState.getStatus": {
|
|
74070
74945
|
capName: "running-state",
|
|
74071
74946
|
capScope: "device",
|
|
@@ -74178,6 +75053,13 @@ Object.freeze({
|
|
|
74178
75053
|
access: "create",
|
|
74179
75054
|
role: "admin"
|
|
74180
75055
|
},
|
|
75056
|
+
"serverManagement.getLaunchOverrides": {
|
|
75057
|
+
capName: "server-management",
|
|
75058
|
+
capScope: "system",
|
|
75059
|
+
addonId: null,
|
|
75060
|
+
access: "view",
|
|
75061
|
+
role: "admin"
|
|
75062
|
+
},
|
|
74181
75063
|
"serverManagement.getServerPackageStatus": {
|
|
74182
75064
|
capName: "server-management",
|
|
74183
75065
|
capScope: "system",
|
|
@@ -74199,6 +75081,13 @@ Object.freeze({
|
|
|
74199
75081
|
access: "create",
|
|
74200
75082
|
role: "admin"
|
|
74201
75083
|
},
|
|
75084
|
+
"serverManagement.setLaunchOverrides": {
|
|
75085
|
+
capName: "server-management",
|
|
75086
|
+
capScope: "system",
|
|
75087
|
+
addonId: null,
|
|
75088
|
+
access: "create",
|
|
75089
|
+
role: "admin"
|
|
75090
|
+
},
|
|
74202
75091
|
"settingsStore.aggregate": {
|
|
74203
75092
|
capName: "settings-store",
|
|
74204
75093
|
capScope: "system",
|
|
@@ -75256,6 +76145,41 @@ Object.freeze({
|
|
|
75256
76145
|
access: "view",
|
|
75257
76146
|
role: "viewer"
|
|
75258
76147
|
},
|
|
76148
|
+
"template.create": {
|
|
76149
|
+
capName: "template",
|
|
76150
|
+
capScope: "system",
|
|
76151
|
+
addonId: null,
|
|
76152
|
+
access: "create",
|
|
76153
|
+
role: "admin"
|
|
76154
|
+
},
|
|
76155
|
+
"template.delete": {
|
|
76156
|
+
capName: "template",
|
|
76157
|
+
capScope: "system",
|
|
76158
|
+
addonId: null,
|
|
76159
|
+
access: "delete",
|
|
76160
|
+
role: "admin"
|
|
76161
|
+
},
|
|
76162
|
+
"template.get": {
|
|
76163
|
+
capName: "template",
|
|
76164
|
+
capScope: "system",
|
|
76165
|
+
addonId: null,
|
|
76166
|
+
access: "view",
|
|
76167
|
+
role: "admin"
|
|
76168
|
+
},
|
|
76169
|
+
"template.list": {
|
|
76170
|
+
capName: "template",
|
|
76171
|
+
capScope: "system",
|
|
76172
|
+
addonId: null,
|
|
76173
|
+
access: "view",
|
|
76174
|
+
role: "admin"
|
|
76175
|
+
},
|
|
76176
|
+
"template.update": {
|
|
76177
|
+
capName: "template",
|
|
76178
|
+
capScope: "system",
|
|
76179
|
+
addonId: null,
|
|
76180
|
+
access: "create",
|
|
76181
|
+
role: "admin"
|
|
76182
|
+
},
|
|
75259
76183
|
"terminalSession.adoptLegacyMonitor": {
|
|
75260
76184
|
capName: "terminal-session",
|
|
75261
76185
|
capScope: "system",
|
|
@@ -77566,6 +78490,11 @@ var ACTUATOR_CAP_VOCABULARY = {
|
|
|
77566
78490
|
icon: "circle-dot"
|
|
77567
78491
|
}]
|
|
77568
78492
|
},
|
|
78493
|
+
"ir-transmitter": {
|
|
78494
|
+
scope: "device",
|
|
78495
|
+
noun: t("IR / RF transmitter", "Trasmettitore IR / RF"),
|
|
78496
|
+
notOperatorFacing: { send: "a raw pulse train is not something an operator composes in an automation; the remote that owns the command table sends it" }
|
|
78497
|
+
},
|
|
77569
78498
|
control: {
|
|
77570
78499
|
scope: "device",
|
|
77571
78500
|
noun: t("Control", "Controllo"),
|
|
@@ -78219,6 +79148,100 @@ var APPLIANCE_CAP_VOCABULARY = {
|
|
|
78219
79148
|
}
|
|
78220
79149
|
]
|
|
78221
79150
|
},
|
|
79151
|
+
"pet-fountain": {
|
|
79152
|
+
scope: "device",
|
|
79153
|
+
noun: t("Pet fountain", "Fontana per animali"),
|
|
79154
|
+
actions: [
|
|
79155
|
+
{
|
|
79156
|
+
id: "petFountain.pumpOn",
|
|
79157
|
+
method: "setPump",
|
|
79158
|
+
label: t("Pump on", "Pompa accesa"),
|
|
79159
|
+
phrase: t("Start the pump of {device}", "Avvia la pompa di {device}"),
|
|
79160
|
+
icon: "play",
|
|
79161
|
+
args: { on: true }
|
|
79162
|
+
},
|
|
79163
|
+
{
|
|
79164
|
+
id: "petFountain.pumpOff",
|
|
79165
|
+
method: "setPump",
|
|
79166
|
+
label: t("Pump off", "Pompa spenta"),
|
|
79167
|
+
phrase: t("Stop the pump of {device}", "Ferma la pompa di {device}"),
|
|
79168
|
+
icon: "square",
|
|
79169
|
+
args: { on: false }
|
|
79170
|
+
},
|
|
79171
|
+
{
|
|
79172
|
+
id: "petFountain.intervalOn",
|
|
79173
|
+
method: "setPumpInterval",
|
|
79174
|
+
label: t("Pump cycle on", "Ciclo pompa attivo"),
|
|
79175
|
+
phrase: t("Run the pump of {device} on its on/off cycle", "Fai lavorare la pompa di {device} a ciclo acceso/spento"),
|
|
79176
|
+
icon: "timer",
|
|
79177
|
+
args: { on: true }
|
|
79178
|
+
},
|
|
79179
|
+
{
|
|
79180
|
+
id: "petFountain.intervalOff",
|
|
79181
|
+
method: "setPumpInterval",
|
|
79182
|
+
label: t("Pump cycle off", "Ciclo pompa spento"),
|
|
79183
|
+
phrase: t("Run the pump of {device} continuously", "Fai lavorare la pompa di {device} in continuo"),
|
|
79184
|
+
icon: "timer-off",
|
|
79185
|
+
args: { on: false }
|
|
79186
|
+
},
|
|
79187
|
+
{
|
|
79188
|
+
id: "petFountain.pumpOnMinutes",
|
|
79189
|
+
method: "setPumpOnMinutes",
|
|
79190
|
+
label: t("Set pump run time", "Imposta il tempo di lavoro della pompa"),
|
|
79191
|
+
phrase: t("Set the pump of {device} to run {minutes} minutes per cycle", "Imposta la pompa di {device} a lavorare {minutes} minuti per ciclo"),
|
|
79192
|
+
icon: "timer",
|
|
79193
|
+
openArgs: [{
|
|
79194
|
+
key: "minutes",
|
|
79195
|
+
label: t("Minutes", "Minuti"),
|
|
79196
|
+
offer: {
|
|
79197
|
+
kind: "number",
|
|
79198
|
+
min: 0,
|
|
79199
|
+
step: 1,
|
|
79200
|
+
unit: "min"
|
|
79201
|
+
}
|
|
79202
|
+
}]
|
|
79203
|
+
},
|
|
79204
|
+
{
|
|
79205
|
+
id: "petFountain.pumpOffMinutes",
|
|
79206
|
+
method: "setPumpOffMinutes",
|
|
79207
|
+
label: t("Set pump rest time", "Imposta il tempo di riposo della pompa"),
|
|
79208
|
+
phrase: t("Set the pump of {device} to rest {minutes} minutes per cycle", "Imposta la pompa di {device} a riposare {minutes} minuti per ciclo"),
|
|
79209
|
+
icon: "timer-off",
|
|
79210
|
+
openArgs: [{
|
|
79211
|
+
key: "minutes",
|
|
79212
|
+
label: t("Minutes", "Minuti"),
|
|
79213
|
+
offer: {
|
|
79214
|
+
kind: "number",
|
|
79215
|
+
min: 0,
|
|
79216
|
+
step: 1,
|
|
79217
|
+
unit: "min"
|
|
79218
|
+
}
|
|
79219
|
+
}]
|
|
79220
|
+
},
|
|
79221
|
+
{
|
|
79222
|
+
id: "petFountain.resetDailyConsumption",
|
|
79223
|
+
method: "resetDailyConsumption",
|
|
79224
|
+
label: t("Clear daily consumption", "Azzera il consumo giornaliero"),
|
|
79225
|
+
phrase: t("Clear the daily water consumption of {device}", "Azzera il consumo giornaliero di acqua di {device}"),
|
|
79226
|
+
icon: "rotate-ccw"
|
|
79227
|
+
}
|
|
79228
|
+
],
|
|
79229
|
+
state: [{
|
|
79230
|
+
kind: "boolean",
|
|
79231
|
+
field: "empty",
|
|
79232
|
+
label: t("Tank empty", "Serbatoio vuoto"),
|
|
79233
|
+
whenTrue: t("When the tank of {device} is empty", "Quando il serbatoio di {device} è vuoto"),
|
|
79234
|
+
whenFalse: t("When the tank of {device} is refilled", "Quando il serbatoio di {device} viene riempito"),
|
|
79235
|
+
icon: "droplet"
|
|
79236
|
+
}, {
|
|
79237
|
+
kind: "numeric",
|
|
79238
|
+
field: "waterLevel",
|
|
79239
|
+
quantity: t("the water level", "il livello dell’acqua"),
|
|
79240
|
+
label: t("Water level", "Livello dell’acqua"),
|
|
79241
|
+
unit: "%",
|
|
79242
|
+
icon: "droplets"
|
|
79243
|
+
}]
|
|
79244
|
+
},
|
|
78222
79245
|
"media-player": {
|
|
78223
79246
|
scope: "device",
|
|
78224
79247
|
noun: t("Media player", "Lettore multimediale"),
|
|
@@ -80043,6 +81066,7 @@ var SYSTEM_CAP_VOCABULARY = {
|
|
|
80043
81066
|
"device-manager": system("the device registry itself — rename, move and remove are administration"),
|
|
80044
81067
|
"device-provider": system(INTERNAL),
|
|
80045
81068
|
"device-removal-hook": system(INTERNAL),
|
|
81069
|
+
"node-removal-hook": system(INTERNAL),
|
|
80046
81070
|
"device-state": system("the runtime-state mirror every trigger already reads through"),
|
|
80047
81071
|
"display-palette": system("the cluster display palette — one colour table for every client, not a device action"),
|
|
80048
81072
|
"embedding-encoder": system(ML),
|
|
@@ -80082,6 +81106,7 @@ var SYSTEM_CAP_VOCABULARY = {
|
|
|
80082
81106
|
"recording-archive": system(STORAGE),
|
|
80083
81107
|
"recording-export": system("recording exports — requested from the timeline, not an automation step"),
|
|
80084
81108
|
records: system(INTERNAL),
|
|
81109
|
+
remote: system("the per-device remote setup — authored in the Customize remote editor, sent through the remote UI"),
|
|
80085
81110
|
"server-management": system(CLUSTER),
|
|
80086
81111
|
"settings-store": system(INTERNAL),
|
|
80087
81112
|
"smtp-provider": system(INTERNAL),
|
|
@@ -80094,6 +81119,7 @@ var SYSTEM_CAP_VOCABULARY = {
|
|
|
80094
81119
|
"storage-provider": system(STORAGE),
|
|
80095
81120
|
"stream-broker": system(PIPELINE),
|
|
80096
81121
|
system: system(CLUSTER),
|
|
81122
|
+
template: system("operator-authored templates — edited in their own editor, never actuated"),
|
|
80097
81123
|
"terminal-session": system(CLUSTER),
|
|
80098
81124
|
toast: system(UI_PLUMBING),
|
|
80099
81125
|
training: system(ML),
|
|
@@ -80153,7 +81179,7 @@ function projectAction(cap, action) {
|
|
|
80153
81179
|
};
|
|
80154
81180
|
}
|
|
80155
81181
|
Object.entries(CAP_VOCABULARY_BY_NAME).flatMap(([cap, entry]) => entry.scope === "device" ? (entry.actions ?? []).map((a) => projectAction(cap, a)) : []);
|
|
80156
|
-
DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
|
|
81182
|
+
DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
|
|
80157
81183
|
DeviceFeature.BatteryOperated;
|
|
80158
81184
|
/**
|
|
80159
81185
|
* How a washer, dryer or dishwasher leaves CamStack.
|
|
@@ -81310,6 +82336,16 @@ Object.freeze({
|
|
|
81310
82336
|
form: "single",
|
|
81311
82337
|
optional: false
|
|
81312
82338
|
}],
|
|
82339
|
+
"irTransmitter.getInfo": [{
|
|
82340
|
+
name: "deviceId",
|
|
82341
|
+
form: "single",
|
|
82342
|
+
optional: false
|
|
82343
|
+
}],
|
|
82344
|
+
"irTransmitter.send": [{
|
|
82345
|
+
name: "deviceId",
|
|
82346
|
+
form: "single",
|
|
82347
|
+
optional: false
|
|
82348
|
+
}],
|
|
81313
82349
|
"keychain.deleteDeviceScope": [{
|
|
81314
82350
|
name: "deviceId",
|
|
81315
82351
|
form: "single",
|
|
@@ -81719,6 +82755,36 @@ Object.freeze({
|
|
|
81719
82755
|
form: "single",
|
|
81720
82756
|
optional: false
|
|
81721
82757
|
}],
|
|
82758
|
+
"petFountain.getStatus": [{
|
|
82759
|
+
name: "deviceId",
|
|
82760
|
+
form: "single",
|
|
82761
|
+
optional: false
|
|
82762
|
+
}],
|
|
82763
|
+
"petFountain.resetDailyConsumption": [{
|
|
82764
|
+
name: "deviceId",
|
|
82765
|
+
form: "single",
|
|
82766
|
+
optional: false
|
|
82767
|
+
}],
|
|
82768
|
+
"petFountain.setPump": [{
|
|
82769
|
+
name: "deviceId",
|
|
82770
|
+
form: "single",
|
|
82771
|
+
optional: false
|
|
82772
|
+
}],
|
|
82773
|
+
"petFountain.setPumpInterval": [{
|
|
82774
|
+
name: "deviceId",
|
|
82775
|
+
form: "single",
|
|
82776
|
+
optional: false
|
|
82777
|
+
}],
|
|
82778
|
+
"petFountain.setPumpOffMinutes": [{
|
|
82779
|
+
name: "deviceId",
|
|
82780
|
+
form: "single",
|
|
82781
|
+
optional: false
|
|
82782
|
+
}],
|
|
82783
|
+
"petFountain.setPumpOnMinutes": [{
|
|
82784
|
+
name: "deviceId",
|
|
82785
|
+
form: "single",
|
|
82786
|
+
optional: false
|
|
82787
|
+
}],
|
|
81722
82788
|
"pipelineAnalytics.addRetrainFrameFromRecording": [{
|
|
81723
82789
|
name: "deviceId",
|
|
81724
82790
|
form: "single",
|
|
@@ -82535,6 +83601,31 @@ Object.freeze({
|
|
|
82535
83601
|
form: "single",
|
|
82536
83602
|
optional: true
|
|
82537
83603
|
}],
|
|
83604
|
+
"remote.getConfig": [{
|
|
83605
|
+
name: "deviceId",
|
|
83606
|
+
form: "single",
|
|
83607
|
+
optional: false
|
|
83608
|
+
}],
|
|
83609
|
+
"remote.listCommands": [{
|
|
83610
|
+
name: "deviceId",
|
|
83611
|
+
form: "single",
|
|
83612
|
+
optional: false
|
|
83613
|
+
}],
|
|
83614
|
+
"remote.sendCommand": [{
|
|
83615
|
+
name: "deviceId",
|
|
83616
|
+
form: "single",
|
|
83617
|
+
optional: false
|
|
83618
|
+
}],
|
|
83619
|
+
"remote.sendMediaCommand": [{
|
|
83620
|
+
name: "deviceId",
|
|
83621
|
+
form: "single",
|
|
83622
|
+
optional: false
|
|
83623
|
+
}],
|
|
83624
|
+
"remote.setConfig": [{
|
|
83625
|
+
name: "deviceId",
|
|
83626
|
+
form: "single",
|
|
83627
|
+
optional: false
|
|
83628
|
+
}],
|
|
82538
83629
|
"runningState.getStatus": [{
|
|
82539
83630
|
name: "deviceId",
|
|
82540
83631
|
form: "single",
|
|
@@ -84343,6 +85434,14 @@ DEFAULT_NATIVE_LEASE_SETTINGS.admission;
|
|
|
84343
85434
|
String.raw`(?<=^|["'(\s>,\[{])`;
|
|
84344
85435
|
var MB = 1024 * 1024;
|
|
84345
85436
|
1024 * MB, 3072 * MB;
|
|
85437
|
+
object({
|
|
85438
|
+
manufacturer: string().optional(),
|
|
85439
|
+
supportedModels: array(string()).optional(),
|
|
85440
|
+
supportedController: string().optional(),
|
|
85441
|
+
commandsEncoding: string(),
|
|
85442
|
+
delay: number().nonnegative().optional(),
|
|
85443
|
+
commands: record(string(), unknown())
|
|
85444
|
+
});
|
|
84346
85445
|
//#endregion
|
|
84347
85446
|
//#region src/custom-actions.ts
|
|
84348
85447
|
/**
|