@camstack/addon-provider-velux 0.2.114 → 0.2.116

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.
Files changed (3) hide show
  1. package/dist/addon.js +3537 -33
  2. package/dist/addon.mjs +3537 -33
  3. package/package.json +1 -1
package/dist/addon.js CHANGED
@@ -5360,7 +5360,7 @@ var ZodIssueCode = {
5360
5360
  var ZodFirstPartyTypeKind;
5361
5361
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5362
5362
  //#endregion
5363
- //#region ../types/dist/sleep-Bs3xPtSh.mjs
5363
+ //#region ../types/dist/sleep-i3eUVc-d.mjs
5364
5364
  /**
5365
5365
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5366
5366
  * window to float samples (D455).
@@ -6502,6 +6502,17 @@ var CamProfileSchema = _enum([
6502
6502
  "mid",
6503
6503
  "low"
6504
6504
  ]);
6505
+ /**
6506
+ * Which rung a per-camera consumer listens on: an explicit profile, or `auto`.
6507
+ *
6508
+ * `auto` is a REAL value, not an absent one — it means "resolve it by the rule
6509
+ * that consumer owns". It lives beside `CamProfile` because a rung is the only
6510
+ * operator-facing way to name a stream: a cam-stream id is broker-internal and
6511
+ * moves when a slot is reassigned, so a stored id silently stops meaning what
6512
+ * the operator picked. Today's one user is the audio analyser, whose rule is
6513
+ * "the lowest AVAILABLE native rung" (D537).
6514
+ */
6515
+ var AudioStreamPickSchema = union([CamProfileSchema, literal("auto")]);
6505
6516
  var CamStreamKindSchema = _enum([
6506
6517
  "pull-rtsp",
6507
6518
  "pull-rtmp",
@@ -6920,6 +6931,18 @@ function systemMethod(input, output, options) {
6920
6931
  systemOnly: true
6921
6932
  };
6922
6933
  }
6934
+ /**
6935
+ * A method a SOURCE of a collection cap may legitimately not serve — OPTIONAL
6936
+ * on `InferProvider`. The `providerOptional: true` literal is what
6937
+ * `InferProvider` keys on; see {@link CapabilityMethodSchema.providerOptional}
6938
+ * for when this is the honest answer and when it is a soft stub.
6939
+ */
6940
+ function optionalMethod(input, output, options) {
6941
+ return {
6942
+ ...method(input, output, options),
6943
+ providerOptional: true
6944
+ };
6945
+ }
6923
6946
  /** Shorthand to define an event schema */
6924
6947
  function event(data) {
6925
6948
  return { data };
@@ -7350,6 +7373,8 @@ var EVENT_OWNER_TYPES = [
7350
7373
  * nothing failing until a caller asked.
7351
7374
  */
7352
7375
  var EventOwnerTypeSchema = _enum(EVENT_OWNER_TYPES);
7376
+ /** The same list as a Zod enum, for the cap input that carries it. */
7377
+ var MediaPresenceOwnerKindSchema = _enum([...EVENT_OWNER_TYPES, "track"]);
7353
7378
  new Set(EVENT_OWNER_TYPES);
7354
7379
  var EncodeProfileSchema = object({
7355
7380
  video: object({
@@ -7722,6 +7747,7 @@ var CameraSwitchIdSchema = _enum([
7722
7747
  "device-audio",
7723
7748
  "broker-audio",
7724
7749
  "audio-analysis",
7750
+ "event-saving",
7725
7751
  "recording",
7726
7752
  "notifications"
7727
7753
  ]);
@@ -7757,10 +7783,20 @@ var CameraSwitchAuthoritySchema = discriminatedUnion("kind", [
7757
7783
  var CameraSwitchUnavailableReasonSchema = _enum([
7758
7784
  "no-provider",
7759
7785
  "source-unreachable",
7760
- "not-configured",
7761
7786
  "device-disabled"
7762
7787
  ]);
7763
7788
  /**
7789
+ * Something true about a switch that is nonetheless OFFERED.
7790
+ *
7791
+ * The distinction from {@link CameraSwitchUnavailableReasonSchema} is the
7792
+ * whole point: a reason replaces the control, a warning travels WITH it. The
7793
+ * privacy mask taught us the difference — greying the one button that starts
7794
+ * the feature teaches the operator the feature is broken, while a live toggle
7795
+ * that flips nothing teaches them the switch is broken. Neither is true; the
7796
+ * honest surface is a working toggle that says what is missing.
7797
+ */
7798
+ var CameraSwitchWarningSchema = _enum(["no-privacy-zones"]);
7799
+ /**
7764
7800
  * One switch, resolved for one camera.
7765
7801
  *
7766
7802
  * `label` and `costWhenOff` travel ON THE WIRE rather than being looked up
@@ -7779,6 +7815,11 @@ var CameraSwitchSchema = object({
7779
7815
  /** False = do not render a control. `unavailableReason` says why. */
7780
7816
  available: boolean(),
7781
7817
  unavailableReason: CameraSwitchUnavailableReasonSchema.optional(),
7818
+ /**
7819
+ * Present on an AVAILABLE switch only. Rendered beside the live control;
7820
+ * never a substitute for one.
7821
+ */
7822
+ warning: CameraSwitchWarningSchema.optional(),
7782
7823
  /** Current state. Meaningless when `available` is false — read it as `true`. */
7783
7824
  enabled: boolean(),
7784
7825
  authority: CameraSwitchAuthoritySchema
@@ -8196,11 +8237,31 @@ var RecordingBandTriggersSchema = RecordingTriggersSchema;
8196
8237
  * band engine's `applies` rule). `start`/`end` are `HH:MM`; an `end <= start`
8197
8238
  * span wraps past midnight (handled by the band engine).
8198
8239
  */
8240
+ /**
8241
+ * Whether a band's footage carries sound.
8242
+ *
8243
+ * The recorder has always attached with `audio: 'aac'`, so every band of every
8244
+ * camera recorded sound whether anyone wanted it or not. The broker already
8245
+ * serves the other answer — `audio: 'none'` takes the video-only `/muted`
8246
+ * restream — so this was a choice the product could always have offered.
8247
+ *
8248
+ * It belongs on the BAND rather than the camera because one camera can want
8249
+ * both: silent across the shop floor during opening hours, sound overnight.
8250
+ * And it applies to BOTH modes — an events band firing on motion has the same
8251
+ * question to answer as a continuous one.
8252
+ */
8253
+ var RecordingBandAudioSchema = _enum(["on", "muted"]);
8199
8254
  var RecordingBandSchema = object({
8200
8255
  days: array(RecordingWeekdaySchema),
8201
8256
  start: string().regex(HHMM),
8202
8257
  end: string().regex(HHMM),
8203
8258
  mode: RecordingBandModeSchema,
8259
+ /**
8260
+ * Sound, or silence. OPTIONAL and absent-means-`on`: every recording
8261
+ * written before this existed carried sound, and a band whose key is
8262
+ * missing must keep meaning what it meant. See {@link RecordingBandAudioSchema}.
8263
+ */
8264
+ audio: RecordingBandAudioSchema.optional(),
8204
8265
  triggers: RecordingBandTriggersSchema.optional(),
8205
8266
  /**
8206
8267
  * RETIRED (D381). A band no longer carries a pre-buffer of its own.
@@ -13484,6 +13545,210 @@ method(object({ integrationId: string() }), object({ filters: array(AdoptionFilt
13484
13545
  auth: "admin"
13485
13546
  });
13486
13547
  /**
13548
+ * device-admin-link — "this device has a management page of its own, and here
13549
+ * is its address".
13550
+ *
13551
+ * ## Why this is not a `deviceConfig` cap
13552
+ *
13553
+ * There is nothing to edit. A `deviceConfig` cap (D14) exists so the framework
13554
+ * can DERIVE a settings form from `getOptions` + `getStatus` and route a flat
13555
+ * patch back through a setter; it costs a `builderId` reducer in
13556
+ * `device-config-contribution.ts` and a `*-config-schema.ts` beside it, and it
13557
+ * renders a form section. This cap answers ONE question with ONE read and
13558
+ * renders a button. Nothing about it is a form, so it carries no `deviceConfig`
13559
+ * block, no `settings`, no `runtimeState` and no reducer — exactly like
13560
+ * `reboot`, the other pure-RPC device-native cap.
13561
+ *
13562
+ * ## Absent, and the difference between "no page" and "we cannot say"
13563
+ *
13564
+ * The two are answered at DIFFERENT layers, on purpose:
13565
+ *
13566
+ * - **"We cannot say"** → the provider never registers the cap for that
13567
+ * device. A VeSync humidifier, a Petkit feeder, a Dreame vacuum and a Dreo
13568
+ * fan are reached only through a vendor cloud; there is no address to hand
13569
+ * out and no page to open. A Tuya plug, a Wyze camera and a Gree air
13570
+ * conditioner DO have a LAN IP, and still have no HTTP management page
13571
+ * behind it. None of them register, so `deviceManager.getBindings` never
13572
+ * lists the cap and no surface asks.
13573
+ * - **"This device has no page, and I know that"** → the provider registers
13574
+ * and `getAdminLink` returns `null`. This is the answer for a device whose
13575
+ * sibling DOES have a page: a Reolink battery camera reached over UDP by
13576
+ * `uid` with a blank `host`, an Ecowitt gateway configured in `listener`
13577
+ * transport, a Home Assistant broker authenticated by supervisor token
13578
+ * (which carries no `baseUrl` at all).
13579
+ *
13580
+ * Both draw NOTHING. A button that opens a browser error is worse than no
13581
+ * button, and D62 is the same rule from the other side: an off switch is
13582
+ * reported off, never made to look broken. There is no third state where the
13583
+ * UI renders a disabled button "because the device might have a page".
13584
+ *
13585
+ * ## The URL never carries credentials
13586
+ *
13587
+ * Not in userinfo, not in a query string. Every provider builds through
13588
+ * `buildDeviceAdminUrl` (`device-admin-link-url.ts`), which takes host, port,
13589
+ * scheme and path as separate arguments — there is no parameter a secret could
13590
+ * arrive in — and re-checks its own output for the `scheme://user:pass@` shape
13591
+ * that `scripts/check-no-credential-urls-in-fixtures.ts` bans from recorded
13592
+ * output. `scripts/check-admin-link-builder-is-the-only-url-source.ts` is what
13593
+ * keeps providers from hand-rolling one anyway.
13594
+ *
13595
+ * This matters here more than anywhere else in the repo, because every provider
13596
+ * that knows a device's host knows its PASSWORD too: `{ host, port, username,
13597
+ * password }` sit in one object on Hikvision, Amcrest, Reolink and ONVIF alike,
13598
+ * and `http://admin:hunter2@192.168.50.139/` is a URL a browser accepts. The
13599
+ * camera's own page will ask for its own login. That is correct, and pre-
13600
+ * filling it is the operator's business, not ours.
13601
+ *
13602
+ * ## It is a LAN fact
13603
+ *
13604
+ * The URL addresses the device where the NODE can see it. It is not proxied,
13605
+ * not made reachable from outside, and not sent anywhere. A surface renders it
13606
+ * as a link the operator's own browser follows, on the operator's own network,
13607
+ * or renders nothing.
13608
+ */
13609
+ /**
13610
+ * Whose page is it. The distinction is for the OPERATOR, who needs to know
13611
+ * before clicking whether he is about to land on a camera's own web server or
13612
+ * inside Home Assistant.
13613
+ */
13614
+ var AdminLinkTargetEnum = _enum(["device", "integration"]);
13615
+ var DeviceAdminLinkSchema = object({
13616
+ /**
13617
+ * Absolute `http(s)://` URL. Built by `buildDeviceAdminUrl` and therefore
13618
+ * free of userinfo and of any credential-shaped query key.
13619
+ */
13620
+ url: string(),
13621
+ /**
13622
+ * What the surface calls it — "Web UI", "Home Assistant", "UniFi controller".
13623
+ * The PROVIDER names it, because only the provider knows what the page is;
13624
+ * a UI that invented the label from the addon id would call the Home
13625
+ * Assistant device page "Provider Homeassistant".
13626
+ */
13627
+ label: string(),
13628
+ target: AdminLinkTargetEnum,
13629
+ /**
13630
+ * Host the URL points at, without scheme, port or path — for the tooltip, so
13631
+ * an operator can see WHERE the button goes before he follows it. Redundant
13632
+ * with `url` by construction; carried separately so no surface has to parse
13633
+ * a URL to show it.
13634
+ */
13635
+ host: string()
13636
+ });
13637
+ var deviceAdminLinkCapability = {
13638
+ name: "device-admin-link",
13639
+ scope: "device",
13640
+ deviceNative: true,
13641
+ mode: "singleton",
13642
+ methods: {
13643
+ /**
13644
+ * The device's management page, or `null` when this device has none.
13645
+ *
13646
+ * `auth: 'admin'` deliberately. This is administration, not actuation —
13647
+ * the same bucket as `reboot` and `camera-credentials`, and explicitly NOT
13648
+ * the actuation set `scripts/check-actuation-not-admin.ts` protects (D403).
13649
+ * The URL is also a statement about the LAN, which a household member with
13650
+ * a `view` grant on a light has no reason to be handed.
13651
+ *
13652
+ * The surfaces gate on the QUERY, never on a role they guessed: a caller
13653
+ * without the right loses the query and draws nothing, which is the same
13654
+ * thing a device with no page draws. There is no path on which a button
13655
+ * appears and then fails — the D403 failure mode, from the other end.
13656
+ */
13657
+ getAdminLink: method(object({ deviceId: number().int().nonnegative() }), DeviceAdminLinkSchema.nullable(), { auth: "admin" }) }
13658
+ };
13659
+ /**
13660
+ * Query keys that may never appear on an admin link. A credential smuggled as
13661
+ * `?password=` is the same leak as userinfo, in a form the userinfo check
13662
+ * cannot see: it survives copy-paste, referrer headers and proxy logs
13663
+ * identically.
13664
+ */
13665
+ var CREDENTIAL_QUERY_KEYS = [
13666
+ "password",
13667
+ "passwd",
13668
+ "pwd",
13669
+ "pass",
13670
+ "user",
13671
+ "username",
13672
+ "usr",
13673
+ "login",
13674
+ "token",
13675
+ "access_token",
13676
+ "auth",
13677
+ "authorization",
13678
+ "apikey",
13679
+ "api_key",
13680
+ "secret",
13681
+ "credential",
13682
+ "credentials",
13683
+ "session",
13684
+ "sessionid",
13685
+ "key"
13686
+ ];
13687
+ /**
13688
+ * The same userinfo shape `scripts/check-no-credential-urls-in-fixtures.ts`
13689
+ * scans recorded fixtures for, applied to what we are about to EMIT. Kept
13690
+ * structurally identical on purpose: a URL this function returns is a URL that
13691
+ * guard would pass.
13692
+ */
13693
+ var CREDENTIAL_URL = /[a-z][a-z0-9+.-]*:\/\/[^/\s:@'"]+:[^/\s:@'"]+@/i;
13694
+ /** A host that is safe to place in an authority component verbatim. */
13695
+ var PLAIN_HOST = /^[a-zA-Z0-9._-]+$/;
13696
+ /** A bracketed IPv6 literal, the only other authority form we emit. */
13697
+ var IPV6_HOST = /^\[[0-9a-fA-F:.]+\]$/;
13698
+ function defaultPortFor(scheme) {
13699
+ return scheme === "https" ? 443 : 80;
13700
+ }
13701
+ /**
13702
+ * Build the admin-page URL, or refuse by name.
13703
+ *
13704
+ * The refusal is never thrown: a provider answering "no page for this device"
13705
+ * is an ordinary answer (`getAdminLink` → `null`), and a throw here would turn
13706
+ * a missing host on one device into a failed query for the whole surface.
13707
+ */
13708
+ function buildDeviceAdminUrl(parts) {
13709
+ const host = parts.host.trim();
13710
+ if (host.length === 0) return {
13711
+ ok: false,
13712
+ reason: "empty-host"
13713
+ };
13714
+ if (host.includes("@")) return {
13715
+ ok: false,
13716
+ reason: "host-carries-userinfo"
13717
+ };
13718
+ if (!PLAIN_HOST.test(host) && !IPV6_HOST.test(host)) return {
13719
+ ok: false,
13720
+ reason: "host-not-plain"
13721
+ };
13722
+ if (parts.port !== null) {
13723
+ if (!Number.isInteger(parts.port) || parts.port < 1 || parts.port > 65535) return {
13724
+ ok: false,
13725
+ reason: "port-out-of-range"
13726
+ };
13727
+ }
13728
+ if (!parts.path.startsWith("/")) return {
13729
+ ok: false,
13730
+ reason: "path-not-absolute"
13731
+ };
13732
+ const query = parts.query ?? {};
13733
+ for (const key of Object.keys(query)) if (CREDENTIAL_QUERY_KEYS.includes(key.toLowerCase())) return {
13734
+ ok: false,
13735
+ reason: "credential-query-key"
13736
+ };
13737
+ const authority = parts.port === null || parts.port === defaultPortFor(parts.scheme) ? host : `${host}:${String(parts.port)}`;
13738
+ const search = new URLSearchParams();
13739
+ for (const [key, value] of Object.entries(query)) search.append(key, value);
13740
+ const suffix = search.size > 0 ? `?${search.toString()}` : "";
13741
+ const url = `${parts.scheme}://${authority}${parts.path}${suffix}`;
13742
+ if (CREDENTIAL_URL.test(url)) return {
13743
+ ok: false,
13744
+ reason: "userinfo-in-result"
13745
+ };
13746
+ return {
13747
+ ok: true,
13748
+ url
13749
+ };
13750
+ }
13751
+ /**
13487
13752
  * `device-export` — collection cap for addons that export camstack
13488
13753
  * devices to external ecosystems (HomeAssistant via MQTT discovery,
13489
13754
  * HomeKit/HAP, Alexa Smart Home, …).
@@ -20250,6 +20515,7 @@ var MediaFileKindEnum = _enum([
20250
20515
  "keyFrameSmall",
20251
20516
  "thumbnailSmall",
20252
20517
  "confirmationCrop",
20518
+ "debugCrop",
20253
20519
  "sceneFrame"
20254
20520
  ]);
20255
20521
  /**
@@ -21329,7 +21595,11 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
21329
21595
  ownerType: EventOwnerTypeSchema,
21330
21596
  eventId: number().int(),
21331
21597
  deviceId: number()
21332
- }), array(MediaFileInfoSchema).readonly()), method(SearchObjectEventsInput, array(ScoredObjectEventSchema).readonly()), method(object({}), WipeObjectEmbeddingsResultSchema, {
21598
+ }), array(MediaFileInfoSchema).readonly()), method(object({
21599
+ deviceId: number(),
21600
+ ownerKind: MediaPresenceOwnerKindSchema,
21601
+ ownerIds: array(string()).max(5e3)
21602
+ }), array(string()).readonly()), method(SearchObjectEventsInput, array(ScoredObjectEventSchema).readonly()), method(object({}), WipeObjectEmbeddingsResultSchema, {
21333
21603
  kind: "mutation",
21334
21604
  auth: "admin"
21335
21605
  }), method(RebuildObjectEmbeddingsInput, RebuildObjectEmbeddingsResultSchema, {
@@ -21914,6 +22184,18 @@ var RunnerCameraConfigSchema = object({
21914
22184
  motionStreamId: string(),
21915
22185
  detectionStreamId: string(),
21916
22186
  /**
22187
+ * Which rung this camera's audio analysis listens on — `auto` (the lowest
22188
+ * AVAILABLE native rung) or an explicit one.
22189
+ *
22190
+ * Not consumed by the runner: carried here so it travels with the camera's
22191
+ * config the way `audioMotionWindowMs` does, and so the orchestrator's
22192
+ * watchdog resolves the same stream the audio subscription did. OPTIONAL
22193
+ * with no default — absent means `auto`, which is what every camera written
22194
+ * before this field had, and an absent optional adds nothing to the
22195
+ * generated cap-input defaults (D537).
22196
+ */
22197
+ audioStreamPick: AudioStreamPickSchema.optional(),
22198
+ /**
21917
22199
  * Motion sources that can activate the pipeline. At least one must
21918
22200
  * be present. Multiple sources OR-ed: any one firing arms the
21919
22201
  * cooldown timer and transitions watching → active. The same
@@ -22984,10 +23266,9 @@ var ServerBootModeSchema = _enum([
22984
23266
  * - `idle` / `checking` / `staging` — steady / in-flight registry work.
22985
23267
  * - `pending-restart` — a version is staged and the node has NOT yet
22986
23268
  * restarted onto it (still running the OLD version).
22987
- * - `awaiting-confirmation` — the node HAS restarted onto the staged version
22988
- * (it is the active probation boot) and is waiting to confirm boot-health.
22989
- * Apply/rollback are refused in this state and the node must NOT be
22990
- * manually restarted, or the probation boot auto-rolls-back.
23269
+ * - `awaiting-confirmation` — RETIRED with the probation boot (single-copy
23270
+ * collapse, 2026-07-18). Kept in the enum so an older client still parses;
23271
+ * no provider emits it.
22991
23272
  */
22992
23273
  var ServerUpdateStateSchema = _enum([
22993
23274
  "idle",
@@ -23076,12 +23357,35 @@ var ServerRollbackInfoSchema = object({
23076
23357
  var ServerPackageStatusSchema = object({
23077
23358
  /** Root package name (`@camstack/server` on the hub). */
23078
23359
  packageName: string(),
23079
- /** Version of the code the running process ACTUALLY loaded. */
23360
+ /**
23361
+ * Version of the code THIS PROCESS loaded — captured once, at boot, from the
23362
+ * package.json of the copy the code was loaded from, and never re-read. A
23363
+ * copy replaced on disk under a live process must not move this number;
23364
+ * that divergence is what `installedVersion` is for. Before 2026-09-20 this
23365
+ * was a lazy disk read that would have followed such a swap silently.
23366
+ */
23080
23367
  runningVersion: string().nullable(),
23081
23368
  /** Node.js runtime version the node's process runs on (`process.versions.node`). */
23082
23369
  nodeRuntimeVersion: string().nullable(),
23083
23370
  /** Active data-dir root version; null when booted from seed/workspace. */
23084
23371
  activeVersion: string().nullable(),
23372
+ /**
23373
+ * Version of the root package in the data-root `current/` copy RIGHT NOW —
23374
+ * what the next boot would load if nothing is staged. Normally equal to
23375
+ * `runningVersion`; differs only when the copy on disk changed under the
23376
+ * live process. `null` when there is no data-root copy (baked seed or
23377
+ * workspace boot). Optional for version skew: an older provider omits it.
23378
+ */
23379
+ installedVersion: string().nullable().optional(),
23380
+ /**
23381
+ * True when the code that would run after a restart is NOT the code running
23382
+ * now: a version is staged (`pendingVersion`), or `installedVersion` differs
23383
+ * from `runningVersion`. Derived on every read, never stored. This is the
23384
+ * one field that lets an operator or a script say "1.2.353 is installed and
23385
+ * will run after a restart" instead of reading it off a number that means
23386
+ * "installed". Optional for version skew.
23387
+ */
23388
+ restartRequired: boolean().optional(),
23085
23389
  /** N-1 version kept for rollback; null when no previous version exists. */
23086
23390
  previousVersion: string().nullable(),
23087
23391
  /** Version of the immutable baked seed closure (image fallback). */
@@ -23116,19 +23420,71 @@ var ServerPackageStatusSchema = object({
23116
23420
  });
23117
23421
  var ServerUpdateCheckResultSchema = object({
23118
23422
  packageName: string(),
23423
+ /** Same meaning as on the status payload: what THIS process loaded. */
23119
23424
  runningVersion: string().nullable(),
23120
23425
  latestVersion: string().nullable(),
23426
+ /**
23427
+ * `latestVersion` is newer than `runningVersion` AND is not the version
23428
+ * already staged on this node. A staged-and-waiting version is not "an
23429
+ * update available" — applying it again is refused (`already-staged`), and
23430
+ * a button that announced "updating…" on this boolean then got refused
23431
+ * would be lying. It is reported through `pendingVersion` instead.
23432
+ */
23121
23433
  updateAvailable: boolean(),
23122
23434
  checkedAtMs: number(),
23123
23435
  /** Non-null when the registry lookup failed (offline, bad registry, …). */
23124
- error: string().nullable()
23436
+ error: string().nullable(),
23437
+ /**
23438
+ * Version staged on this node and awaiting its restart, when one is. Before
23439
+ * 2026-09-20 a check answered `{runningVersion, updateAvailable:false}` for a
23440
+ * node whose staged closure had never booted, and the caller had no way to
23441
+ * see the difference. Optional for version skew.
23442
+ */
23443
+ pendingVersion: string().nullable().optional(),
23444
+ /** See the status payload: staged, or installed-on-disk ≠ running. Optional for skew. */
23445
+ restartRequired: boolean().optional()
23125
23446
  });
23447
+ /**
23448
+ * What an action DID — the discriminant `accepted` cannot carry. Before
23449
+ * 2026-09-20 `applyServerUpdate` answered `accepted:false` both for a refusal
23450
+ * where nothing was wrong (already current, already staged) and for a staging
23451
+ * install that died on `npm error code ECONNRESET`; the only difference was
23452
+ * prose in `message`, and an operator restarted a container on the strength of
23453
+ * it, booting the previous version.
23454
+ *
23455
+ * - `staged` — the closure is installed and validated; the node
23456
+ * restarts to apply it (`restarting:true`). NOTHING
23457
+ * runs the new code until that restart completes.
23458
+ * - `restart-scheduled` — a plain, version-preserving restart was accepted.
23459
+ * - `already-current` — the target IS the running version; nothing done.
23460
+ * - `refused` — dropped by a gate; `reason` names which.
23461
+ * - `failed` — attempted and did not land; `error` says why.
23462
+ */
23463
+ var ServerUpdateOutcomeSchema = _enum([
23464
+ "staged",
23465
+ "restart-scheduled",
23466
+ "already-current",
23467
+ "refused",
23468
+ "failed"
23469
+ ]);
23126
23470
  var ServerUpdateActionResultSchema = object({
23127
23471
  accepted: boolean(),
23128
23472
  targetVersion: string().nullable(),
23129
23473
  /** True when a graceful restart was scheduled to apply the change. */
23130
23474
  restarting: boolean(),
23131
- message: string()
23475
+ message: string(),
23476
+ /** See {@link ServerUpdateOutcomeSchema}. Optional for version skew. */
23477
+ outcome: ServerUpdateOutcomeSchema.optional(),
23478
+ /**
23479
+ * Stable, greppable cause for `refused` / `failed` (the engine's
23480
+ * `UpdateRefusalReason`, `staging-failed`, …). `null` on success.
23481
+ */
23482
+ reason: string().nullable().optional(),
23483
+ /**
23484
+ * The failure itself, verbatim enough to act on (the npm output for a
23485
+ * staging install). Non-null only for `failed`.
23486
+ */
23487
+ error: string().nullable().optional()
23132
23488
  });
23133
23489
  method(_void(), ServerPackageStatusSchema, { auth: "admin" }), method(_void(), ServerUpdateCheckResultSchema, {
23134
23490
  kind: "mutation",
@@ -24237,6 +24593,18 @@ method(VectorDeclareIndexInputSchema, _void(), {
24237
24593
  kind: "mutation",
24238
24594
  auth: "admin"
24239
24595
  }), method(VectorStatsInputSchema, VectorStatsResultSchema, { auth: "admin" });
24596
+ _enum([
24597
+ "queue-full",
24598
+ "camera-backoff",
24599
+ "sleeping",
24600
+ "camera-refused",
24601
+ "no-keyframe",
24602
+ "no-catalog-row",
24603
+ "unsupported",
24604
+ "unknown-device",
24605
+ "uid-missing"
24606
+ ]);
24607
+ _enum(["deferred", "final"]);
24240
24608
  var ClipSchema = object({
24241
24609
  /** Opaque, provider-namespaced id. The default provider encodes the time
24242
24610
  * window so `getClipPlayback` is self-contained (no event re-query). */
@@ -24311,29 +24679,455 @@ var ClipSchema = object({
24311
24679
  holes: array(object({
24312
24680
  startMs: number(),
24313
24681
  endMs: number()
24314
- })).optional()
24682
+ })).optional(),
24683
+ /**
24684
+ * A URL that MAY produce this clip's still, asked only for rows actually on
24685
+ * screen. The opposite of {@link ClipSchema.thumbnail}: that one is VOUCHED
24686
+ * (a JPEG is already on disk), this one is an offer. The route answers 200
24687
+ * with the image, or 204 with `x-camstack-reason` when it could not mint one
24688
+ * — a surface latches that refusal to the instant rather than retrying.
24689
+ *
24690
+ * Never both: a clip with a vouched `thumbnail` needs no mint.
24691
+ */
24692
+ thumbnailMint: string().optional(),
24693
+ /**
24694
+ * Why no still will be produced for this clip RIGHT NOW — set when the
24695
+ * provider already knows, so the surface draws the glyph and the reason
24696
+ * instead of firing a mint that cannot succeed.
24697
+ *
24698
+ * `sleeping` — a standalone battery camera; a read would be a wake (D549 4).
24699
+ * `camera-refused` — the camera answered the CoverPreview with a refusal.
24700
+ * `no-keyframe` — the window holds no decodable I-frame (an event that sits
24701
+ * inside no file is the measured case).
24702
+ * `unsupported` — this source cannot mint stills at all.
24703
+ */
24704
+ thumbnailUnavailable: object({ reason: _enum([
24705
+ "sleeping",
24706
+ "camera-refused",
24707
+ "no-keyframe",
24708
+ "unsupported"
24709
+ ]) }).optional(),
24710
+ /**
24711
+ * When the catalog this row came from was last CONFIRMED against the device.
24712
+ * Absent means "this row was read live". A persisted catalog served while a
24713
+ * camera sleeps carries the age it really has — a cached list is never drawn
24714
+ * as current (D549 13).
24715
+ */
24716
+ catalogAsOf: number().optional(),
24717
+ /**
24718
+ * The camera's OWN type strings for this clip, all of them, unmapped
24719
+ * (`md`, `people`, `dog_cat`, `sched`, …). Kept beside {@link labels}
24720
+ * because a firmware inventing a type must not vanish: the mapping into our
24721
+ * filter vocabulary is lossy on purpose and this is the lossless copy
24722
+ * (D549 20).
24723
+ */
24724
+ nativeTypes: array(string()).optional(),
24725
+ /**
24726
+ * What the subject DID — `crossline`, `intrude`, `loitering`. A behaviour
24727
+ * travels BESIDE a class, never instead of one, and the class filter ignores
24728
+ * it: "a person crossed a line" is still a person (D549 20).
24729
+ */
24730
+ behaviours: array(string()).optional(),
24731
+ /**
24732
+ * The same recording as two files — the sub twin (what the row and its
24733
+ * thumbnail are) and its main twin, matched at listing time so a quality
24734
+ * change never re-searches the camera (D549 15). `getClipPlayback`'s
24735
+ * `profile` picks between them: `low | mid` → sub, `high` → main.
24736
+ */
24737
+ streams: object({
24738
+ sub: object({
24739
+ id: string(),
24740
+ bytes: number().optional()
24741
+ }).optional(),
24742
+ main: object({
24743
+ id: string(),
24744
+ bytes: number().optional()
24745
+ }).optional()
24746
+ }).optional(),
24747
+ /** The camera says it holds a sub-stream copy of this recording. */
24748
+ supportSub: boolean().optional(),
24749
+ /**
24750
+ * Whether this row has bytes behind it. ABSENT means yes — every clip that
24751
+ * IS a file is playable, and only a source that lists EVENTS can produce a
24752
+ * row with nothing to play (the measured case: 1 of 29 hub events on 3628
24753
+ * fell inside no file). Such a row is shown, never dropped and never offered
24754
+ * as playable-then-failing (D549 19).
24755
+ */
24756
+ playable: boolean().optional(),
24757
+ /** Why {@link playable} is false, verbatim (`no-file-for-window`). */
24758
+ unplayableReason: string().optional(),
24759
+ /**
24760
+ * This clip is STILL BEING WRITTEN, so {@link ClipSchema.timeRange}`.endMs`
24761
+ * is not its end.
24762
+ *
24763
+ * Absent — the common case — means the row is closed and its `endMs` is the
24764
+ * end of the recording. Present and `true` means the source told us the file
24765
+ * has no end yet, and the `endMs` we carry is whatever the camera's index
24766
+ * entry happened to hold: on a Reolink E1 Outdoor PoE (592, measured
24767
+ * 2026-09-20) the newest file `…_192927_000000_…_0.mp4` reported an `endTime`
24768
+ * of 19:29:56 and STILL reported it eight minutes later, while the file went
24769
+ * on growing. A surface that drew 29 s there was lying about a clip that
24770
+ * plays for minutes, on the one row the operator looks at first.
24771
+ *
24772
+ * `endMs` is deliberately still a number: it is the best bound anything has
24773
+ * for a mint window or a byte fetch, and every consumer already requires it.
24774
+ * This flag says what it is WORTH, and a duration is not drawn from it.
24775
+ */
24776
+ inProgress: boolean().optional()
24315
24777
  });
24316
24778
  var ClipPlaybackSchema = object({
24317
- /** HLS master URL through the hub data-plane (Range + token in path). */
24779
+ /**
24780
+ * A media URL through the hub data-plane. {@link ClipPlaybackSchema.format}
24781
+ * says what kind — an HLS master playlist for a recording-derived clip, a
24782
+ * progressive MP4 for a native file the vendor addon muxed and serves with
24783
+ * `Range`. The URL is NOT a credential: both planes are registered
24784
+ * `access: 'authenticated'` and the hub's `/addon/<id>/<prefix>` proxy takes
24785
+ * the session cookie, so nothing is appended to it (D549 22).
24786
+ */
24318
24787
  playbackUrl: string(),
24788
+ /**
24789
+ * How to play {@link playbackUrl}. Absent means `hls` — the shape every
24790
+ * existing consumer already assumes. A player that branches on this is the
24791
+ * one change a native clip needs; a player that ignores it will hand an MP4
24792
+ * to hls.js and fail parsing it as a manifest.
24793
+ */
24794
+ format: _enum(["hls", "mp4"]).optional(),
24795
+ /**
24796
+ * Which twin was actually served. A clip that holds only one stream answers
24797
+ * with the one it has, and the surface SAYS so — a missing main twin is
24798
+ * never served silently as if it were the asked-for quality (D549 15).
24799
+ */
24800
+ served: CamProfileSchema.optional(),
24319
24801
  /** Optional LAN/remote alternates for the same clip. */
24320
24802
  playbackEndpoints: array(string()).optional(),
24321
24803
  token: string().optional()
24322
24804
  });
24805
+ /**
24806
+ * Why a source cannot answer right now — per SOURCE, never fleet-wide.
24807
+ *
24808
+ * `ok` is the only state whose clip list may be read as complete. The other
24809
+ * three exist because an empty list from a sleeping camera reads as "this
24810
+ * camera has no recordings", which is the defect this whole line of work is
24811
+ * about: a battery camera nobody woke (`sleeping`), a camera that could not be
24812
+ * reached at all (`unreachable`, also what a provider that THREW reports), a
24813
+ * camera whose SD card is not mounted (`no-storage`, measured on 640 —
24814
+ * `HddInfo mount 0`, honestly nothing to list rather than "no clips"), and a
24815
+ * camera whose OWN index disagrees with its OWN calendar (`index-empty`,
24816
+ * measured on 618: the calendar marks 3–20 September, days 6–20 list zero
24817
+ * files on both streams and both filters, with 177 GB free). That last one is
24818
+ * a defect ON THE CAMERA, and the only honest thing a provider can do is say
24819
+ * which days it asked for and got nothing — "no clips" would be a lie about a
24820
+ * card that is full of them.
24821
+ */
24822
+ /**
24823
+ * The operator's authorisation to WAKE a sleeping camera for one clip read.
24824
+ *
24825
+ * ONE value, absent by default, and it is a `force`-shaped operator signal in
24826
+ * exactly the sense `snapshot-wake-gate.ts` uses the word: *"`snapshot.getSnapshot`'s
24827
+ * `force` flag, and nothing else… a background caller must never set it…
24828
+ * Stale but honest beats woken"*. A scheduler, a retry, a reconcile and a
24829
+ * prefetch never set it; a surface sets it only behind the same confirm the
24830
+ * "Wake and refresh" gesture uses, and it is refused below 15 % battery
24831
+ * exactly as that gesture is.
24832
+ *
24833
+ * The gate is decided BEFORE `getApi()`, because on UDP the login IS the wake
24834
+ * (D549) — a read that opened a session and then checked would have woken the
24835
+ * camera to find out it was not allowed to.
24836
+ *
24837
+ * **One authorised yes is one wake.** `next-natural` — take the clip the next
24838
+ * time the camera is awake for its own reasons — is deliberately not a member:
24839
+ * it was proposed, it is free on the battery, and the operator declined it on
24840
+ * 2026-09-20 (*"Quando un export viene richiesto si sveglia la camera."*,
24841
+ * D558 "Considered and not taken").
24842
+ */
24843
+ var ClipWakeSchema = _enum(["authorised"]);
24844
+ /**
24845
+ * A clip's finished bytes, inline — the twin of `recordingExport.readExportBytes`.
24846
+ *
24847
+ * `bytes` is the DECODED length, so nobody infers it from the base64 length,
24848
+ * and `served` says which twin the caller actually got.
24849
+ */
24850
+ var ClipBytesSchema = object({
24851
+ base64: string(),
24852
+ contentType: string(),
24853
+ /** Suggested filename, extension included. */
24854
+ name: string(),
24855
+ bytes: number().int().nonnegative(),
24856
+ /**
24857
+ * Which twin was actually served — the same contract
24858
+ * {@link ClipPlaybackSchema.served} carries, and REQUIRED here because the
24859
+ * export record persists it: a row read a week later must say the same thing
24860
+ * the panel said at the moment of the tap. A missing main twin is never
24861
+ * served silently as if it were the asked-for quality (D549 15).
24862
+ */
24863
+ served: CamProfileSchema,
24864
+ /**
24865
+ * The DECODED duration of the delivered file, when the fetch measured one.
24866
+ *
24867
+ * A clip fetch verifies its own completion against the catalog row and
24868
+ * retries a materially short pass (D568); this is that measurement, carried
24869
+ * so a consumer can say the same thing rather than re-deriving it. Absent
24870
+ * when the producer did not measure — never zero, which would say the file
24871
+ * is empty.
24872
+ */
24873
+ durationMs: number().positive().optional()
24874
+ });
24875
+ /**
24876
+ * Where a clip's STREAM can be dialled (D597) — the answer to
24877
+ * {@link videoclipsCapability.methods.dialClipStream}.
24878
+ *
24879
+ * `url` is plain `http://` on the provider's own token-gated listener, one
24880
+ * shot, short-lived. It is NOT the hub-proxied `/addon/<id>/clip-stream/…`
24881
+ * path: that plane takes only a user credential, which an addon does not
24882
+ * hold, and the framework offers no addon→addon byte transport — the one
24883
+ * precedent is the broker's own restream URLs (`getStreamWithCodec`), which
24884
+ * a consumer dials directly, and this is that precedent one addon over.
24885
+ */
24886
+ /**
24887
+ * The audio a clip stream can be asked for, and the audio it carries.
24888
+ *
24889
+ * The camera stores AAC and no WebRTC session speaks it, so a stream that
24890
+ * carries sound carries it TRANSCODED, muxed as a second track beside the
24891
+ * video by the one ffmpeg the provider already runs (D600). `opus` is
24892
+ * 48 kHz mono, `pcmu` is 8 kHz µ-law — the two codecs a broker session
24893
+ * negotiates — and `none` is a stream asked for, or served, without sound.
24894
+ */
24895
+ var ClipStreamAudioSchema = _enum([
24896
+ "opus",
24897
+ "pcmu",
24898
+ "none"
24899
+ ]);
24900
+ /**
24901
+ * Why a stream that was ASKED for sound is not carrying it (D600).
24902
+ *
24903
+ * Only ever set beside `servedAudio: 'none'` after a non-`none` ask. Absent
24904
+ * means the ask was honoured, or there was no ask.
24905
+ *
24906
+ * - `not-requested` — the caller asked for `none`.
24907
+ * - `unsupported-ask` — the provider cannot produce that codec.
24908
+ *
24909
+ * Whether the RECORDING has sound at all is not knowable here: the camera
24910
+ * declares no audio track before its first frame arrives. That answer is in
24911
+ * the stream itself — an fMP4 with no audio track — and the broker reads it
24912
+ * there. A dial that says `opus` promises the codec, never the content.
24913
+ */
24914
+ var ClipStreamAudioReasonSchema = _enum(["not-requested", "unsupported-ask"]);
24915
+ var ClipStreamDialSchema = object({
24916
+ url: string().min(1),
24917
+ /** After this the token is gone and the URL answers 404 `dial-expired`. */
24918
+ expiresAtMs: number(),
24919
+ /** What the stream IS — a consumer that cannot honour it must not dial. */
24920
+ transport: literal("forward-only"),
24921
+ /**
24922
+ * Which twin the stream ACTUALLY carries — not what was asked for.
24923
+ *
24924
+ * The stream serves every profile (D599), and a recording whose main twin
24925
+ * does not exist is streamed as its sub copy, which this field reports as
24926
+ * `low`. That is the whole reason the dial no longer refuses `high`:
24927
+ * stating what was served is what makes accepting honest, where a silent
24928
+ * substitution would be the 33x lie D576 forbids. Stated rather than
24929
+ * assumed, the way {@link ClipPlaybackSchema.served} is (D549 15).
24930
+ */
24931
+ served: CamProfileSchema,
24932
+ /**
24933
+ * Which audio the stream will ACTUALLY carry — `served`'s companion for
24934
+ * sound, and the same reasoning (D599, D600).
24935
+ *
24936
+ * The broker asks for the codec its WebRTC session negotiated, and the
24937
+ * provider either muxes that codec or carries none. Stating it is what
24938
+ * lets the broker wire the matching sink before the first byte, and what
24939
+ * keeps a session from being handed a codec it cannot send — the audio
24940
+ * shape of the substitution `served` exists to prevent.
24941
+ *
24942
+ * It is a promise about the CODEC, not about the content: a recording with
24943
+ * no microphone track answers `opus` here and then arrives with no audio
24944
+ * track at all. That second answer is in the stream, and the broker reads
24945
+ * it from the `moov`.
24946
+ */
24947
+ servedAudio: ClipStreamAudioSchema,
24948
+ /** Why `servedAudio` is `none` although sound was asked for. */
24949
+ audioReason: ClipStreamAudioReasonSchema.optional()
24950
+ });
24951
+ var ClipSourceAvailabilitySchema = object({
24952
+ state: _enum([
24953
+ "ok",
24954
+ "sleeping",
24955
+ "unreachable",
24956
+ "no-storage",
24957
+ "index-empty"
24958
+ ]),
24959
+ /** Free text, shown verbatim. Names the camera's own refusal when there is one. */
24960
+ reason: string().optional(),
24961
+ /** When this source's catalog was last CONFIRMED. A cached list is never
24962
+ * drawn as current: the surface shows the age whenever it is older than the
24963
+ * refresh interval. */
24964
+ catalogAsOf: number().optional()
24965
+ });
24966
+ /**
24967
+ * One SOURCE of clips for a camera — a row of the picker, and the namespace
24968
+ * every clip id from it is prefixed with (`analytics`,
24969
+ * `native:reolink:onboard`, `hksv`, …).
24970
+ *
24971
+ * A provider lists the sources IT serves for that device, and answers for each
24972
+ * of them whether it can answer at all. A provider with nothing to offer on a
24973
+ * camera returns `[]` — it is not that camera's business.
24974
+ */
24975
+ var ClipSourceSchema = object({
24976
+ /** The value this source stamps on {@link ClipSchema.source}, and the prefix
24977
+ * of every clip id it mints. `getClipPlayback` routes on it. */
24978
+ source: string(),
24979
+ /** Operator-facing name of the source ("CamStack recordings", "SD card"). */
24980
+ label: string(),
24981
+ /**
24982
+ * The addon that SERVES this row.
24983
+ *
24984
+ * A surface cannot otherwise resolve a source to who answers it, and the
24985
+ * alternative — a `native:reolink:* → provider-reolink` table inside the
24986
+ * widget — is a second authority on provider identity living in the one
24987
+ * package with no business knowing it, wrong the day a third source appears
24988
+ * (D557). One addon may serve SEVERAL sources, which is why the per-device
24989
+ * switch is keyed by SOURCE and not by this (D555) — `addon-provider-reolink`
24990
+ * served a hub child two of them until the two views were measured to be one
24991
+ * store read twice (D555) and then read ONE way (D565).
24992
+ *
24993
+ * Optional for version skew only. The collection dispatcher stamps it from
24994
+ * the registry, so a row that travelled through the fan-out carries the
24995
+ * authoritative id whatever the provider filled in.
24996
+ */
24997
+ addonId: string().optional(),
24998
+ availability: ClipSourceAvailabilitySchema
24999
+ });
24323
25000
  DeviceType.Camera, method(object({
24324
25001
  deviceId: number(),
24325
25002
  since: number(),
24326
25003
  until: number(),
24327
- limit: number().int().positive().optional()
25004
+ limit: number().int().positive().optional(),
25005
+ /**
25006
+ * WHICH provider to ask — the `addonId` a {@link ClipSourceSchema} row
25007
+ * carries, never a source id and never a list. **Required** (D554 amended).
25008
+ *
25009
+ * A provider the device is not bound to is refused by name rather than
25010
+ * answered by another one (D552's `rejectUnresolvedAddonPin` rule).
25011
+ *
25012
+ * It was optional, documented as "absent means the device's BOUND
25013
+ * provider, which is CamStack on every camera". No code implemented
25014
+ * that. Measured on the live hub 2026-09-20 — device 592, bound to
25015
+ * `recorder` AND `provider-reolink` — a bare call with `limit: 3`
25016
+ * answered SIX rows, three from each source, merged newest-first:
25017
+ * `device-collection-dispatch.ts` simply left the fan-out un-narrowed,
25018
+ * so absence bought the union this method exists not to be, and
25019
+ * `limit` meant `limit × sources`.
25020
+ *
25021
+ * There is nothing to restore the default to. `getBindings` answers a
25022
+ * collection cap with a DERIVED, PLURAL set (D554 amended, step 0);
25023
+ * `setWrapperActive` — the singleton authority that could name one —
25024
+ * throws for a collection cap by design. Naming CamStack here instead
25025
+ * would privilege one addon by id inside a surface whose premise is
25026
+ * that sources are peers, and would be wrong on the first camera with
25027
+ * no recorder binding. So absence is REFUSED, in the schema, where the
25028
+ * generated types make it unomittable rather than merely discouraged.
25029
+ *
25030
+ * The default belongs to the SURFACE, which has the `listSources` rows
25031
+ * and can say which one it picked (D569 § 1–3; the viewer already
25032
+ * always sends this).
25033
+ *
25034
+ * It replaced `sources?: string[]`, a VIEW filter over source ids that
25035
+ * assumed the answer was a fan-out over everything a camera has. The
25036
+ * operator settled otherwise on 2026-09-20 — *"l'utilizzatore è uno
25037
+ * solo"* — so the list is asked of one provider at a time and there is
25038
+ * nothing to filter out of it.
25039
+ */
25040
+ provider: string().min(1)
24328
25041
  }), array(ClipSchema).readonly(), {
24329
25042
  kind: "query",
24330
- auth: "admin"
25043
+ auth: "protected"
25044
+ }), method(object({ deviceId: number() }), array(ClipSourceSchema).readonly(), {
25045
+ kind: "query",
25046
+ auth: "protected"
24331
25047
  }), method(object({
24332
25048
  deviceId: number(),
24333
- clipId: string()
25049
+ clipId: string(),
25050
+ /**
25051
+ * Which twin to serve, on the ONE quality scale the system already has
25052
+ * (`CamProfileSchema`). `low | mid` → the sub file, `high` → the main
25053
+ * twin; both ids are already on the row so this never re-searches the
25054
+ * camera. Absent means the provider's own default (the sub file, which
25055
+ * every source is measured to hold).
25056
+ *
25057
+ * `auto` is deliberately NOT accepted here: a stored file has no
25058
+ * broker session, so the adaptive tier cannot be resolved for it. The
25059
+ * viewer resolves `auto` to a profile the same way live does, before
25060
+ * it calls (D549 15).
25061
+ */
25062
+ profile: CamProfileSchema.optional()
24334
25063
  }), ClipPlaybackSchema, {
24335
25064
  kind: "query",
24336
- auth: "admin"
25065
+ auth: "protected"
25066
+ }), optionalMethod(object({
25067
+ deviceId: number(),
25068
+ clipId: string().min(1),
25069
+ /**
25070
+ * WHICH provider holds the bytes — the `addonId` a
25071
+ * {@link ClipSourceSchema} row carries. **Required**, for the reason
25072
+ * `listClips` states one method above and for a second one this method
25073
+ * learned the hard way.
25074
+ *
25075
+ * The caller is the stream broker, and the broker lives in
25076
+ * `addon-pipeline` — the same addon that registers the RECORDER's
25077
+ * videoclips provider. With no provider named, the in-process
25078
+ * resolution handed it its own sibling, which implements this method
25079
+ * solely to explain that an analytics visit has no file behind it. So
25080
+ * every onboard clip answered with that sentence, a flash of video and
25081
+ * nothing more, while the SAME call from outside the addon reached the
25082
+ * right provider and returned the bytes (measured on 3628,
25083
+ * 2026-09-21).
25084
+ */
25085
+ provider: string().min(1),
25086
+ /**
25087
+ * Which twin to fetch, on the mapping D549 15 already fixed:
25088
+ * `low | mid` → the sub file, `high` → the main twin. `auto` is not
25089
+ * accepted here for the same reason it is not accepted by
25090
+ * `getClipPlayback` — a stored file has no broker session, so the
25091
+ * adaptive tier cannot be resolved for it.
25092
+ */
25093
+ profile: CamProfileSchema.optional(),
25094
+ /**
25095
+ * The CALLER's byte bound, so an over-size clip is refused before it is
25096
+ * read and encoded rather than after. Capped by
25097
+ * {@link VIDEOCLIPS_MAX_READ_BYTES} whatever is passed; absent means
25098
+ * that ceiling.
25099
+ */
25100
+ maxBytes: number().int().positive().optional(),
25101
+ /**
25102
+ * The operator's authorisation to wake a sleeping camera for this
25103
+ * read. Absent — the default — means a sleeping standalone battery
25104
+ * camera is REFUSED by name, before any session is opened.
25105
+ */
25106
+ wake: ClipWakeSchema.optional()
25107
+ }), ClipBytesSchema, {
25108
+ kind: "query",
25109
+ auth: "protected"
25110
+ }), optionalMethod(object({
25111
+ deviceId: number(),
25112
+ clipId: string().min(1),
25113
+ /** WHICH provider holds the camera — see `readClipBytes.provider`. */
25114
+ provider: string().min(1),
25115
+ /** Which twin — `high` → the main file, everything else the sub (D599). */
25116
+ profile: CamProfileSchema.optional(),
25117
+ /**
25118
+ * Which audio codec the caller's session negotiated, so the provider
25119
+ * can mux it (D600). The ask travels on the DIAL because the mux is
25120
+ * spawned once, before the first byte, and cannot gain a track later.
25121
+ *
25122
+ * ABSENT IS `none`, never a guess: a caller that does not state an
25123
+ * ask is served the video-only stream that shipped first, so a broker
25124
+ * older than this field keeps working unchanged (D382 — an unstated
25125
+ * ask is zero).
25126
+ */
25127
+ audio: ClipStreamAudioSchema.optional()
25128
+ }), ClipStreamDialSchema, {
25129
+ kind: "query",
25130
+ auth: "protected"
24337
25131
  });
24338
25132
  /**
24339
25133
  * Optional client-side hints sent at session creation to help the provider
@@ -24405,6 +25199,104 @@ var WebrtcStreamChoiceSchema = object({
24405
25199
  /** Bitrate in kbps (null for adaptive). */
24406
25200
  bitrateKbps: number().nullable()
24407
25201
  });
25202
+ /**
25203
+ * The last move the adaptive ladder made on this session, and the numbers it
25204
+ * rested on. Mirrors `LadderDecision` in the stream-broker's
25205
+ * `adaptive-controller.ts` — the log line's evidence, made readable.
25206
+ *
25207
+ * Nullability is load-bearing: `lossRatio: null` means the loss tracker had
25208
+ * no window to report, which is NOT a link with zero loss.
25209
+ */
25210
+ var WebrtcLadderDecisionSchema = object({
25211
+ /** `loss` — RTCP / client-reported packet loss; `stall` — the picture
25212
+ * stopped moving; `healthy` — a promotion. */
25213
+ cause: _enum([
25214
+ "loss",
25215
+ "stall",
25216
+ "healthy"
25217
+ ]),
25218
+ /** The rung the ladder moved TO. Null for a move that changed no rung
25219
+ * (an MTU reduction, a forced transcode-down at the bottom). */
25220
+ tier: CamProfileSchema.nullable(),
25221
+ /** Whether that move forced the egress transcode-down rung. */
25222
+ forcedTranscodeDown: boolean(),
25223
+ /** Loss ratio over the tracker's window at the moment of the decision. */
25224
+ lossRatio: number().nullable(),
25225
+ /** The client's reported downlink at that moment, in kbps. */
25226
+ clientKbps: number().nullable(),
25227
+ /** How long the stall detector had been seeing nothing arrive. */
25228
+ stalledForMs: number().nullable(),
25229
+ /** Whether the broker WAS sending while that was measured — the half that
25230
+ * separates "the camera stopped" from "the link stopped". */
25231
+ serverSending: boolean().nullable(),
25232
+ /** Epoch ms. The overlay prints its age; a decision from 40 minutes ago
25233
+ * must not read like one from this second. */
25234
+ at: number()
25235
+ });
25236
+ /** Per-tier count of MEASURED downgrades this viewer session has suffered. */
25237
+ var WebrtcTierFailureSchema = object({
25238
+ tier: CamProfileSchema,
25239
+ failures: number().int().nonnegative()
25240
+ });
25241
+ /**
25242
+ * What the SERVER decided for one WebRTC session — the half the client cannot
25243
+ * measure. See `getSessionDebug`.
25244
+ */
25245
+ var WebrtcSessionDebugSchema = object({
25246
+ sessionId: string(),
25247
+ /** Whether the session still exists here. Everything below is null when
25248
+ * it does not — a dead session has no measurements, not zero ones. */
25249
+ alive: boolean(),
25250
+ /** Epoch ms this snapshot was taken, so the overlay can show its age. */
25251
+ observedAt: number(),
25252
+ /** The broker actually feeding this session (`<deviceId>/<camStreamId>`). */
25253
+ brokerId: string().nullable(),
25254
+ camStreamId: string().nullable(),
25255
+ /** `derived` = this hub BUILT the rung being served (a transcode/scale of
25256
+ * another stream); `native` = the camera's own encode. */
25257
+ sourceKind: _enum([
25258
+ "native",
25259
+ "derived",
25260
+ "unknown"
25261
+ ]),
25262
+ /** Whether the ladder is running at all (an `adaptive` target). */
25263
+ adaptive: boolean(),
25264
+ /** The rung `auto` ACTUALLY resolved to right now. Null when the broker
25265
+ * is bound to no profile slot (a manually-activated stream). */
25266
+ servedTier: CamProfileSchema.nullable(),
25267
+ /** Which node ingests the source. Null when unresolved. */
25268
+ ingestNodeId: string().nullable(),
25269
+ /** Whether that node is a remote one (the media crosses a node boundary
25270
+ * before it reaches this session). Null when unresolved. */
25271
+ ingestIsRemote: boolean().nullable(),
25272
+ /** Codec off the source, and the one negotiated with this client. */
25273
+ sourceCodec: string().nullable(),
25274
+ negotiatedCodec: string().nullable(),
25275
+ /** Whether the EGRESS leg re-encodes for this client or forwards the
25276
+ * source bytes untouched. */
25277
+ egressLeg: _enum([
25278
+ "copy",
25279
+ "transcode",
25280
+ "unknown"
25281
+ ]),
25282
+ /** What the broker itself reports about the rung it is serving. */
25283
+ brokerStatus: string().nullable(),
25284
+ brokerCodec: string().nullable(),
25285
+ brokerBitrateKbps: number().nullable(),
25286
+ brokerInputFps: number().nullable(),
25287
+ brokerUptimeMs: number().nullable(),
25288
+ /** RTP packets this session has sent — the server's own "am I sending?". */
25289
+ rtpPacketsSent: number().nullable(),
25290
+ /** D42: the track may be carrying the recorded feeder, not live. The ladder
25291
+ * is suspended there, so a frozen picture in `recorded` mode means
25292
+ * something entirely different. */
25293
+ trackMode: _enum(["live", "recorded"]).nullable(),
25294
+ lastDecision: WebrtcLadderDecisionSchema.nullable(),
25295
+ tierFailures: array(WebrtcTierFailureSchema),
25296
+ /** Successful promotions in this viewer session (drives the progressive
25297
+ * healthy timer). Null when no ladder is running. */
25298
+ upgradeCount: number().nullable()
25299
+ });
24408
25300
  DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), array(WebrtcStreamChoiceSchema)), method(object({
24409
25301
  deviceId: number().int().nonnegative(),
24410
25302
  target: WebrtcStreamTargetSchema,
@@ -24569,7 +25461,10 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
24569
25461
  * the same answer as "it ended": either way nothing is holding it up.
24570
25462
  */
24571
25463
  alive: boolean()
24572
- }));
25464
+ })), method(object({
25465
+ deviceId: number().int().nonnegative(),
25466
+ sessionId: string()
25467
+ }), WebrtcSessionDebugSchema, { kind: "query" });
24573
25468
  object({
24574
25469
  /** All accessory children of the parent. */
24575
25470
  childDeviceIds: array(number()).readonly(),
@@ -26395,6 +27290,346 @@ var dayNightCapability = {
26395
27290
  volatileStateFields: ["lastFetchedAt"]
26396
27291
  };
26397
27292
  /**
27293
+ * Vendor-neutral **onboard** recording + storage cap — what the CAMERA
27294
+ * writes to the CAMERA's own card, on the camera's own schedule.
27295
+ *
27296
+ * This is NOT `recording.cap.ts`. That one is CamStack's recorder: our
27297
+ * footage ledger, our storage locations, our retention. This one has a
27298
+ * different authority — the camera's firmware — and per D62 it stores
27299
+ * nothing of its own. Every value here is read from the camera and every
27300
+ * write goes back to the camera; there is no CamStack-side mirror that
27301
+ * could disagree with the device.
27302
+ *
27303
+ * ## One shape, two firmwares
27304
+ *
27305
+ * Measured 2026-09-22 against the live fleet:
27306
+ *
27307
+ * | fact | Hikvision (ISAPI) | Reolink (Baichuan) |
27308
+ * | --- | --- | --- |
27309
+ * | storage | `ContentMgmt/Storage` `<hdd>` rows: status, capacity, freeSpace (MB) | `getHddInfoList` (cmd 102): `mount`, `format`, `capacity` GB + `capacityM` MB remainder |
27310
+ * | tracks | several (101 **and** 103 on both 1436 and 3833), each with its own schedule | one per channel |
27311
+ * | schedule | per track, 7 `ScheduleAction` blocks: DayOfWeek + TimeOfDay range + ONE `ActionRecordingMode` | per trigger type, a 168-char weekly HOUR mask |
27312
+ * | triggers | `CMR`, `MOTION` | `Normal`, `MD`, `people`, `vehicle`, `dog_cat`, `crossline`, `intrude`, `loitering` |
27313
+ * | pre-record | `PreRecordTimeSeconds` | `preRecordTime` |
27314
+ * | post-record | `PostRecordTimeSeconds` | `recordDelayTime` |
27315
+ * | overwrite | per track `LoopEnable` | `cycle`, with `cycleList` enumerating the accepted values |
27316
+ * | segment length | not exposed on V5.7.1 | `packageTime` (minutes) |
27317
+ *
27318
+ * The two schedule models look different and are the same thing in
27319
+ * different coordinates: both answer "for this trigger, during which
27320
+ * weekly windows does the camera record". {@link RecordWindow} is that
27321
+ * question in one shape — Hikvision's ranges map straight onto it,
27322
+ * Reolink's mask expands into hour-aligned windows.
27323
+ *
27324
+ * ## Union, not intersection
27325
+ *
27326
+ * **The same fields exist on every camera.** What differs per device is
27327
+ * which VALUES that device accepts, and that is what {@link
27328
+ * RecordingOnboardOptions} reports — a `{ readable, writable, reason }`
27329
+ * per field plus the schedule's own limits. A control a camera cannot
27330
+ * honour is rendered DISABLED WITH ITS REASON, never missing and never
27331
+ * dead: disabled must not look like broken.
27332
+ *
27333
+ * ## Refusal by name
27334
+ *
27335
+ * A write a camera cannot honour is refused with a sentence the operator
27336
+ * can read — never accepted and dropped. Both providers refuse through
27337
+ * {@link describeOnboardRefusal}, so the vocabulary is one function and
27338
+ * one test, not two hand-written vendor opinions.
27339
+ *
27340
+ * Follows the D14 `deviceConfig` archetype (see `stream-params.cap.ts`):
27341
+ * `getOptions` advertises per-camera availability, `getStatus` (auto-
27342
+ * injected from `status`) reports the live values, and a single
27343
+ * `setSettings` mutation applies a partial change. No hand-written
27344
+ * settings-contribution methods.
27345
+ */
27346
+ /**
27347
+ * What makes the camera start recording during a window.
27348
+ *
27349
+ * The union of both vendors' vocabularies. `continuous` is Hikvision's
27350
+ * `CMR` and Reolink's `Normal`; `motion` is `MOTION` / `MD`. The
27351
+ * object-class triggers are Reolink-only today and the smart-event ones
27352
+ * (`lineCrossing`, `intrusion`, `loitering`) are Reolink-only on the
27353
+ * firmwares measured — a camera that cannot record on a trigger simply
27354
+ * does not list it in `options.schedule.triggers`, and a window naming
27355
+ * it is REFUSED, not dropped.
27356
+ */
27357
+ var RecordTriggerSchema = _enum([
27358
+ "continuous",
27359
+ "motion",
27360
+ "person",
27361
+ "vehicle",
27362
+ "animal",
27363
+ "lineCrossing",
27364
+ "intrusion",
27365
+ "loitering",
27366
+ "alarmInput"
27367
+ ]);
27368
+ /**
27369
+ * One weekly recording window: "on `day`, from `startMinute` to
27370
+ * `endMinute`, record on `trigger`".
27371
+ *
27372
+ * `day` is 0 = Monday … 6 = Sunday (ISO order, which is also the order
27373
+ * both firmwares enumerate). Minutes are local camera time since
27374
+ * midnight; `endMinute` may be 1440, meaning end of day — that is
27375
+ * Hikvision's literal `24:00` and Reolink's 24th mask slot, and
27376
+ * collapsing it to 0 would turn a whole-day window into an empty one.
27377
+ */
27378
+ var RecordWindowSchema = object({
27379
+ trigger: RecordTriggerSchema,
27380
+ day: number().int().min(0).max(6),
27381
+ startMinute: number().int().min(0).max(1439),
27382
+ endMinute: number().int().min(1).max(1440)
27383
+ });
27384
+ /** Status of one physical volume, as the camera itself describes it. */
27385
+ var OnboardStorageVolumeSchema = object({
27386
+ /** The camera's own id for the volume (`hdd/id`, Reolink `HddInfo/number`). */
27387
+ id: string(),
27388
+ /** The camera's own name for it, when it gives one (`hddName`). */
27389
+ label: string().optional(),
27390
+ status: _enum([
27391
+ "ok",
27392
+ "unformatted",
27393
+ "error",
27394
+ "offline",
27395
+ "unknown"
27396
+ ]),
27397
+ /**
27398
+ * Total size in MB, or **null when the camera did not say**.
27399
+ *
27400
+ * Never 0 for an unreadable value: a measurement that failed is not a
27401
+ * measurement (D393), and a card whose size is unknown must not be
27402
+ * rendered as a card of size zero.
27403
+ */
27404
+ capacityMb: number().nullable(),
27405
+ /**
27406
+ * Free space in MB, or null when unknown.
27407
+ *
27408
+ * **Not a proxy for "has footage".** Measured 2026-09-22: 1436 and
27409
+ * 1439 both report exactly 11776 MB free — the fixed reserve a looping
27410
+ * card converges on once it has wrapped. At loop steady state the
27411
+ * number is identical whether the camera recorded yesterday or stopped
27412
+ * a month ago.
27413
+ */
27414
+ freeMb: number().nullable(),
27415
+ /** True when the camera reports the volume writable (`property` RW). */
27416
+ writable: boolean().optional()
27417
+ });
27418
+ /**
27419
+ * What the camera is doing with its own storage, right now.
27420
+ *
27421
+ * Every scalar is nullable and **null means the camera did not answer**,
27422
+ * never a default. A form that seeds `0` from an unanswered read invites
27423
+ * the operator to save that 0 back onto the camera.
27424
+ */
27425
+ var RecordingOnboardStatusSchema = object({
27426
+ storage: discriminatedUnion("kind", [
27427
+ object({
27428
+ kind: literal("present"),
27429
+ volumes: array(OnboardStorageVolumeSchema)
27430
+ }),
27431
+ object({
27432
+ kind: literal("absent"),
27433
+ reason: string()
27434
+ }),
27435
+ object({
27436
+ kind: literal("unknown"),
27437
+ reason: string()
27438
+ })
27439
+ ]),
27440
+ tracks: array(object({
27441
+ id: string(),
27442
+ enabled: boolean(),
27443
+ isVideo: boolean(),
27444
+ /** From the camera's own track description. Null when it does not say. */
27445
+ codec: string().nullable(),
27446
+ resolution: string().nullable(),
27447
+ /** Per-track overwrite flag, where the firmware keeps it per track. */
27448
+ overwriteWhenFull: boolean().nullable()
27449
+ })),
27450
+ /**
27451
+ * The track the write path targets — the enabled VIDEO one. Null when
27452
+ * no track could be identified, which is itself a refusal reason.
27453
+ */
27454
+ primaryTrackId: string().nullable(),
27455
+ /** Master "record to the card at all" switch. */
27456
+ enabled: boolean().nullable(),
27457
+ overwriteWhenFull: boolean().nullable(),
27458
+ preRecordSec: number().nullable(),
27459
+ postRecordSec: number().nullable(),
27460
+ /** Length of one recorded file, in minutes. */
27461
+ segmentMinutes: number().nullable(),
27462
+ /** The primary track's weekly windows, flattened. */
27463
+ windows: array(RecordWindowSchema),
27464
+ /**
27465
+ * How many windows the camera described that CamStack could NOT read —
27466
+ * an unrecognised trigger, an unparseable clock, a weekday it does not
27467
+ * name.
27468
+ *
27469
+ * A dropped window is work the reader threw away, and a schedule that
27470
+ * silently shows fewer rows than the camera holds is how an operator
27471
+ * saves back a schedule shorter than the one they were looking at
27472
+ * (D391). Non-zero means the window list is INCOMPLETE and a write
27473
+ * that replaces it would delete what was not shown — which is why a
27474
+ * provider reporting a non-zero count also reports the schedule as not
27475
+ * writable.
27476
+ */
27477
+ unreadableWindows: number(),
27478
+ /**
27479
+ * The camera is scheduled to record and has NO usable storage.
27480
+ *
27481
+ * A first-class fact because it is the fleet's most common silent
27482
+ * defect: measured 2026-09-22, 1441 and 3831 are both motion-recording
27483
+ * to a card that is not there. Neither the schedule nor the storage
27484
+ * read says anything wrong on its own; only the pair does.
27485
+ */
27486
+ recordingToNowhere: boolean(),
27487
+ lastFetchedAt: number()
27488
+ });
27489
+ /** Numeric range descriptor — `{ min, max, step }` per the getOptions convention. */
27490
+ var RangeSchema = object({
27491
+ min: number(),
27492
+ max: number(),
27493
+ step: number()
27494
+ });
27495
+ /**
27496
+ * The values a camera actually takes for a numeric field, when they are a SET
27497
+ * rather than a range.
27498
+ *
27499
+ * `{min,max,step}` cannot say what these two firmwares do. Measured on 1436
27500
+ * (I91DN) on 2026-09-22 by writing each value and reading it back:
27501
+ *
27502
+ * - pre-record: `0, 5, 10, 15, 20, 25, 30` and `2147483647` (INT32_MAX, the
27503
+ * camera's "no limit" — `-1` and `4294967295` both land on it);
27504
+ * - post-record: `5, 10, 30, 60, 120, 300, 600`.
27505
+ *
27506
+ * Neither is expressible as a step: the first has a sentinel two billion away
27507
+ * from its neighbours, the second doubles and then jumps. A range that tried
27508
+ * would forbid values the camera takes AND permit values it silently replaces
27509
+ * with 5 — wrong in both directions at once.
27510
+ *
27511
+ * `sentinel` names the member that is not a duration, so a surface can render
27512
+ * "no limit" instead of `2147483647` seconds.
27513
+ */
27514
+ var AllowedValuesSchema = object({
27515
+ values: array(number()).min(1),
27516
+ sentinel: object({
27517
+ value: number(),
27518
+ meaning: _enum(["no-limit", "disabled"])
27519
+ }).optional()
27520
+ });
27521
+ /**
27522
+ * Per-field availability on ONE camera.
27523
+ *
27524
+ * The field exists on every camera — this says whether this one can be
27525
+ * read and whether it can be written, and `reason` says why not when
27526
+ * either is false. The UI renders the control DISABLED with the reason
27527
+ * rather than hiding it, so a limitation is legible instead of looking
27528
+ * like a missing feature.
27529
+ */
27530
+ var OnboardFieldSupportSchema = object({
27531
+ readable: boolean(),
27532
+ writable: boolean(),
27533
+ /** Required whenever `readable` or `writable` is false. */
27534
+ reason: string().optional()
27535
+ });
27536
+ /** What this camera's schedule model can express. */
27537
+ var OnboardScheduleSupportSchema = object({
27538
+ support: OnboardFieldSupportSchema,
27539
+ /**
27540
+ * The smallest time step the camera can express, in minutes.
27541
+ *
27542
+ * Hikvision takes arbitrary minutes (`00:05:00`–`23:57:00` observed on
27543
+ * 1436's track 103). Reolink's schedule is a 7×24 HOUR mask, so 60. A
27544
+ * window whose edges are not a multiple of this is REFUSED rather than
27545
+ * quietly rounded — rounding is how an operator's 06:30 becomes 06:00
27546
+ * and nothing says so.
27547
+ */
27548
+ granularityMinutes: number(),
27549
+ /** Triggers this camera can record on. A window naming another is refused. */
27550
+ triggers: array(RecordTriggerSchema),
27551
+ /**
27552
+ * False when the camera stores ONE trigger per time range, so two
27553
+ * windows overlapping on the same day cannot carry different triggers.
27554
+ * True on Reolink, whose mask is per-trigger and independent.
27555
+ */
27556
+ supportsOverlappingTriggers: boolean()
27557
+ });
27558
+ var RecordingOnboardOptionsSchema = object({
27559
+ enabled: OnboardFieldSupportSchema,
27560
+ overwriteWhenFull: OnboardFieldSupportSchema,
27561
+ preRecordSec: OnboardFieldSupportSchema,
27562
+ preRecordSecRange: RangeSchema.optional(),
27563
+ /** Preferred over the range when the camera takes a SET, not a span. */
27564
+ preRecordSecAllowed: AllowedValuesSchema.optional(),
27565
+ postRecordSec: OnboardFieldSupportSchema,
27566
+ postRecordSecRange: RangeSchema.optional(),
27567
+ /** Preferred over the range when the camera takes a SET, not a span. */
27568
+ postRecordSecAllowed: AllowedValuesSchema.optional(),
27569
+ segmentMinutes: OnboardFieldSupportSchema,
27570
+ segmentMinutesRange: RangeSchema.optional(),
27571
+ /** Preferred over the range when the camera takes a SET, not a span. */
27572
+ segmentMinutesAllowed: AllowedValuesSchema.optional(),
27573
+ schedule: OnboardScheduleSupportSchema
27574
+ });
27575
+ /**
27576
+ * A partial change. Every field optional.
27577
+ *
27578
+ * Unlike the other `deviceConfig` caps, a provider here does **NOT**
27579
+ * silently ignore a field it cannot support — it refuses, by name,
27580
+ * through {@link describeOnboardRefusal}. Silence on a recording setting
27581
+ * is the failure D62 exists to prevent: the operator believes the camera
27582
+ * is recording the way the form says, and it is not.
27583
+ */
27584
+ var RecordingOnboardPatchSchema = object({
27585
+ enabled: boolean().optional(),
27586
+ overwriteWhenFull: boolean().optional(),
27587
+ preRecordSec: number().optional(),
27588
+ postRecordSec: number().optional(),
27589
+ segmentMinutes: number().optional(),
27590
+ /** The complete new window set for the primary track — not a delta. */
27591
+ windows: array(RecordWindowSchema).optional()
27592
+ });
27593
+ var recordingOnboardCapability = {
27594
+ name: "recording-onboard",
27595
+ scope: "device",
27596
+ deviceNative: true,
27597
+ mode: "singleton",
27598
+ deviceTypes: [DeviceType.Camera],
27599
+ deviceConfig: { ui: {
27600
+ kind: "derived-form",
27601
+ builderId: "recording-onboard",
27602
+ tab: "recording"
27603
+ } },
27604
+ methods: {
27605
+ getOptions: method(object({ deviceId: number() }), RecordingOnboardOptionsSchema),
27606
+ setSettings: method(object({
27607
+ deviceId: number(),
27608
+ settings: RecordingOnboardPatchSchema
27609
+ }), _void(), {
27610
+ kind: "mutation",
27611
+ auth: "admin"
27612
+ })
27613
+ },
27614
+ status: {
27615
+ schema: RecordingOnboardStatusSchema,
27616
+ kind: "poll"
27617
+ },
27618
+ runtimeState: RecordingOnboardStatusSchema,
27619
+ /**
27620
+ * Runtime-state durability: **restored** — operator-set camera-side
27621
+ * recording config; mutation-driven, and the storage half is the last
27622
+ * thing the camera said about its own card.
27623
+ *
27624
+ * See `RuntimeStateDurability`. Enforced by
27625
+ * `scripts/check-runtime-state-durability.ts`.
27626
+ */
27627
+ durability: "restored",
27628
+ /** Clock fields: written, but excluded from the compare that decides
27629
+ * whether persisting is worth a SQLite commit. */
27630
+ volatileStateFields: ["lastFetchedAt"]
27631
+ };
27632
+ /**
26398
27633
  * Generic device-level status snapshot. Auto-registered by `BaseDevice`
26399
27634
  * for every device, regardless of provider — the kernel needs a uniform
26400
27635
  * cap-keyed slice for the basic device flags every consumer expects to
@@ -28904,11 +30139,15 @@ var motionTriggerCapability = {
28904
30139
  *
28905
30140
  * Adding a fifth name to that list would have been the wrong fix twice over:
28906
30141
  * that page is per-camera DETECTION tuning, and a grid's geometry belongs
28907
- * beside PTZ and motion zones on the camera itself — which is exactly where the
28908
- * framework already puts a widget, when the widget is declared on a CAPABILITY.
28909
- * `deviceConfig.ui` is the mechanism (`motion-zones`, `ptz`, `ptz-autotrack`
28910
- * all use it): the framework emits the structural section and the widget
28911
- * self-persists through the cap's own mutations.
30142
+ * beside PTZ and motion zones on the camera itself. The device page is
30143
+ * BINDING-driven (D12), so the way in is a capability bound to the device —
30144
+ * and this cap carries its section the way `recording` does, by RETURNING it
30145
+ * from `getDeviceSettingsContribution`.
30146
+ *
30147
+ * Seven other widgets are still declared the other way, through a
30148
+ * `deviceConfig.ui` block the framework derives a section from. That route
30149
+ * gives the addon no say in where its own panel lands and no way to decline
30150
+ * for a device the panel does not suit, which is why this one does not use it.
28912
30151
  *
28913
30152
  * ## Why one addon may implement it
28914
30153
  *
@@ -28964,16 +30203,37 @@ var GridProfileOfferSchema = object({
28964
30203
  ]),
28965
30204
  offered: boolean(),
28966
30205
  /** Sources that cannot serve it. Empty when it is offered, or when there are no cells. */
28967
- missingSources: array(number().int().positive())
30206
+ missingSources: array(number().int().positive()),
30207
+ /**
30208
+ * The canvas this profile composes onto, `WxH`, or empty when it is not
30209
+ * offered. DERIVED from the cells and the sources' own size at this profile —
30210
+ * it is reported because nothing else in the system would ever say what the
30211
+ * grid came out as, and because it is the number an operator would otherwise
30212
+ * expect to type.
30213
+ */
30214
+ canvas: string(),
30215
+ /**
30216
+ * Whether this profile is PUBLISHED, of the ones the grid could serve.
30217
+ *
30218
+ * A grid's `high` is composed of its sources' `high`, so on a 4K fleet it is
30219
+ * a 4K canvas built from 4K decodes — something to opt into, not something a
30220
+ * viewer's adaptive should be handed by climbing to the top rung it can see.
30221
+ * Default is `mid` + `low`.
30222
+ */
30223
+ published: boolean()
28968
30224
  });
28969
30225
  var GridLayoutViewSchema = object({
28970
30226
  /** The persisted grid row this camera was declared from. */
28971
30227
  instanceId: string(),
28972
30228
  deviceId: number().int().nonnegative(),
28973
30229
  name: string(),
28974
- /** The canvas the operator laid out — this grid's `high`. mid/low are scaled from it. */
28975
- width: number().int(),
28976
- height: number().int(),
30230
+ /**
30231
+ * NO canvas size. A grid's resolution is not authored: each profile derives
30232
+ * its own from the cells and its sources' dimensions. The two numbers that
30233
+ * used to be here were a text field that silently decided both how much the
30234
+ * composite cost and how sharp it was — see `profiles[].canvas` for what it
30235
+ * came out as.
30236
+ */
28977
30237
  fps: number().int(),
28978
30238
  cells: array(GridLayoutCellSchema),
28979
30239
  /** What the catalog will publish, and what it refuses to. Read-only. */
@@ -28982,9 +30242,13 @@ var GridLayoutViewSchema = object({
28982
30242
  var GridLayoutPatchSchema = object({
28983
30243
  deviceId: number().int().nonnegative(),
28984
30244
  name: string().min(1).max(160).optional(),
28985
- width: number().int().min(160).max(7680).optional(),
28986
- height: number().int().min(120).max(4320).optional(),
28987
30245
  fps: number().int().min(1).max(60).optional(),
30246
+ /** Which profiles to publish. See `GridProfileOffer.published`. */
30247
+ publishedProfiles: array(_enum([
30248
+ "high",
30249
+ "mid",
30250
+ "low"
30251
+ ])).max(3).optional(),
28988
30252
  /**
28989
30253
  * The whole cell list at once. A per-cell patch would need an ordering the
28990
30254
  * editor does not have, and a half-applied layout is a picture nobody asked
@@ -31267,6 +32531,25 @@ var ptzAutotrackCapability = {
31267
32531
  scope: "device",
31268
32532
  deviceNative: true,
31269
32533
  mode: "singleton",
32534
+ /**
32535
+ * Two kinds of provider behind one name, the same shape `snapshot` and
32536
+ * `doorbell` use:
32537
+ *
32538
+ * - **Native**: the camera's own firmware autotrack, registered per device by
32539
+ * the driver when the probe says it exists (Reolink: yes; Hikvision:
32540
+ * model-dependent).
32541
+ * - **Wrapper**: the emulated implementation (`@camstack/system`'s `autotrack` builtin),
32542
+ * which follows a subject with `ptz.move` pulses driven by the detection
32543
+ * pipeline. `defaultActive: false` — the operator binds it per camera in
32544
+ * the bindings UI, exactly as `virtual-doorbell` is bound.
32545
+ *
32546
+ * The binding chooses WHICH implementation answers; `setEnabled` stays the
32547
+ * one switch for the function either way. A camera never has both driving its
32548
+ * head, which is the whole reason this is not a second cap with a second
32549
+ * toggle (D62, D520).
32550
+ */
32551
+ kind: "wrapper",
32552
+ defaultActive: false,
31270
32553
  deviceTypes: [DeviceType.Camera],
31271
32554
  deviceConfig: { ui: {
31272
32555
  kind: "widget",
@@ -31749,7 +33032,7 @@ method(object({
31749
33032
  auth: "admin"
31750
33033
  }), method(object({ deviceId: number() }), RecordingConfigSchema, {
31751
33034
  kind: "query",
31752
- auth: "admin"
33035
+ auth: "protected"
31753
33036
  }), method(object({
31754
33037
  deviceId: number(),
31755
33038
  profile: string(),
@@ -31979,13 +33262,101 @@ var ExportStateSchema = _enum([
31979
33262
  "expired",
31980
33263
  "deleted"
31981
33264
  ]);
31982
- /** One export job / history row. */
33265
+ /**
33266
+ * WHAT an export is — the authority, as opposed to the four top-level fields
33267
+ * the Library sorts and labels on (D558 § 2.2).
33268
+ *
33269
+ * Read it through {@link exportSubjectOf}, never off the record directly: the
33270
+ * field is optional for the history rows written before it existed, and that
33271
+ * absence has exactly one interpreter.
33272
+ */
33273
+ var ExportSubjectSchema = discriminatedUnion("kind", [object({
33274
+ kind: literal("footage"),
33275
+ deviceId: number(),
33276
+ profiles: array(string()).min(1),
33277
+ fromMs: number(),
33278
+ toMs: number()
33279
+ }), object({
33280
+ kind: literal("clip"),
33281
+ deviceId: number(),
33282
+ provider: string().min(1),
33283
+ source: string().min(1),
33284
+ sourceLabel: string().min(1),
33285
+ clipId: string().min(1),
33286
+ /**
33287
+ * WHERE IN THE CATALOG to confirm this clip — the day window the surface was
33288
+ * already listing when the operator picked the segment.
33289
+ *
33290
+ * It is **not** a time range control and it never becomes one: the record's
33291
+ * `fromMs`/`toMs` come from the catalog ROW and from nothing a caller
33292
+ * supplied (D558 § 5.4.3), and a window that does not contain the clip is a
33293
+ * `catalog-miss`, not a silently wider search. It exists because
33294
+ * `videoclips.listClips` takes `since`/`until` and has no by-handle twin:
33295
+ * the catalog check D558 asks for is literally that call, and a call needs a
33296
+ * window. The surface has one — `ClipsBrowser`'s `dayWindow`, one local
33297
+ * wall-clock day, which is also the only width measured to be cheap (one
33298
+ * day on 592 lists 171 clips in 712 ms, a busy day 546 in 2.0 s; twenty days
33299
+ * of one child's events took 3.6–5.4 s).
33300
+ */
33301
+ catalogWindow: object({
33302
+ sinceMs: number(),
33303
+ untilMs: number()
33304
+ }),
33305
+ profile: _enum([
33306
+ "high",
33307
+ "mid",
33308
+ "low"
33309
+ ]),
33310
+ /**
33311
+ * The operator's authorisation to wake a sleeping camera for this export.
33312
+ * ONE definition, in the cap that owns the clip read ({@link ClipWakeSchema}),
33313
+ * because the gate that honours it is the clip provider's sleep gate — a
33314
+ * second enum here would be a second contract. Absent by default; never
33315
+ * settable by a scheduler or a retry.
33316
+ *
33317
+ * **One authorised yes is ONE wake.** A failed clip export is retried only by
33318
+ * an operator act that asks again; a queued job that outlived its wake fails
33319
+ * with a reason rather than waking on its turn; and this subject carries
33320
+ * exactly one profile precisely so one tap is never two fetches (D558 § 5.2).
33321
+ */
33322
+ wake: ClipWakeSchema.optional()
33323
+ })]);
33324
+ /**
33325
+ * One export job / history row.
33326
+ *
33327
+ * **`subject` is the AUTHORITY on what was exported. `deviceId`, `profile`,
33328
+ * `fromMs` and `toMs` are its PROJECTION** — kept top-level because the whole
33329
+ * Library sorts and labels on them (`library-items.ts` orders an export by
33330
+ * `fromMs`; `export-format.ts` draws `rangeLabel` from the pair), and a row
33331
+ * that did not fill them would sort under the epoch and render a blank range.
33332
+ * Write to the subject and read from the projection and the two will disagree;
33333
+ * the projection is derived at creation and never edited afterwards.
33334
+ *
33335
+ * And they mean DIFFERENT FACTS for the two kinds, which is the part a reader
33336
+ * who knows only the recording export will get wrong:
33337
+ *
33338
+ * | field | `kind:'footage'` | `kind:'clip'` |
33339
+ * | --- | --- | --- |
33340
+ * | `fromMs`/`toMs` | the stretch the operator ASKED for | the camera's own boundaries, always `clip.timeRange`, never anything a caller supplied |
33341
+ * | `profile` | the stream rendered | the twin actually SERVED (`subject.profile` is the one asked for) |
33342
+ *
33343
+ * Same type, different fact — the shape this repo keeps getting wrong (D385's
33344
+ * two authorities, D224's second copy).
33345
+ */
31983
33346
  var ExportRecordSchema = object({
31984
33347
  id: string(),
31985
33348
  deviceId: number(),
31986
33349
  profile: string(),
31987
33350
  fromMs: number(),
31988
33351
  toMs: number(),
33352
+ /**
33353
+ * What this export IS. Optional ONLY for the rows written before D558: the
33354
+ * store parses every row through this schema on every read, so a required
33355
+ * field would make the export AUDIT — which is the whole reason rows survive
33356
+ * file deletion — unreadable in one release. Absence means `footage`, and
33357
+ * {@link exportSubjectOf} is the one place that says so.
33358
+ */
33359
+ subject: ExportSubjectSchema.optional(),
31989
33360
  options: ExportOptionsSchema,
31990
33361
  state: ExportStateSchema,
31991
33362
  /** 0–100 while rendering; null otherwise. */
@@ -32002,6 +33373,18 @@ var ExportRecordSchema = object({
32002
33373
  /** Failure reason when state is 'failed'; null otherwise. */
32003
33374
  error: string().nullable()
32004
33375
  });
33376
+ _enum([
33377
+ "catalog-miss",
33378
+ "catalog-unreachable",
33379
+ "no-file-for-window",
33380
+ "clip-in-progress",
33381
+ "unsupported-option",
33382
+ "sleeping",
33383
+ "camera-refused",
33384
+ "fetch-failed",
33385
+ "too-large-to-transfer",
33386
+ "wake-expired"
33387
+ ]);
32005
33388
  /** Candidate download URLs (LAN first, then operator extra hosts). */
32006
33389
  var ExportDownloadSchema = object({
32007
33390
  url: string(),
@@ -32020,16 +33403,50 @@ var ExportBytesSchema = object({
32020
33403
  name: string(),
32021
33404
  bytes: number().int().nonnegative()
32022
33405
  });
33406
+ /** Canonical `profiles[]`, falling back to the legacy singular `profile`. */
33407
+ function resolveExportProfiles(input) {
33408
+ if (input.profiles !== void 0 && input.profiles.length > 0) return [...input.profiles];
33409
+ if (typeof input.profile === "string" && input.profile.length > 0) return [input.profile];
33410
+ return [];
33411
+ }
32023
33412
  method(object({
32024
33413
  deviceId: number(),
32025
33414
  /** @deprecated Prefer `profiles`. Kept so timelapse/notifiers keep working. */
32026
33415
  profile: string().optional(),
32027
33416
  profiles: array(string()).min(1).optional(),
32028
- fromMs: number(),
32029
- toMs: number(),
33417
+ /** Footage only — a clip's boundaries are the camera's. */
33418
+ fromMs: number().optional(),
33419
+ toMs: number().optional(),
33420
+ /** What to export. Absent means the legacy flat footage request. */
33421
+ subject: ExportSubjectSchema.optional(),
32030
33422
  options: ExportOptionsSchema
32031
33423
  }).superRefine((v, ctx) => {
32032
- if ((v.profiles !== void 0 && v.profiles.length > 0 ? v.profiles : v.profile !== void 0 ? [v.profile] : []).length < 1) ctx.addIssue({
33424
+ if (v.subject?.kind === "clip") {
33425
+ if (v.subject.deviceId !== v.deviceId) ctx.addIssue({
33426
+ code: ZodIssueCode.custom,
33427
+ message: `subject.deviceId (${v.subject.deviceId}) must equal deviceId (${v.deviceId}) — the top-level field is what per-device scope enforcement reads`,
33428
+ path: ["subject", "deviceId"]
33429
+ });
33430
+ if (v.fromMs !== void 0 || v.toMs !== void 0) ctx.addIssue({
33431
+ code: ZodIssueCode.custom,
33432
+ message: "a clip export asks for no time range: the camera chose the boundaries and they are read from the catalog row",
33433
+ path: ["fromMs"]
33434
+ });
33435
+ return;
33436
+ }
33437
+ if (v.subject?.kind === "footage" && v.subject.deviceId !== v.deviceId) ctx.addIssue({
33438
+ code: ZodIssueCode.custom,
33439
+ message: `subject.deviceId (${v.subject.deviceId}) must equal deviceId (${v.deviceId})`,
33440
+ path: ["subject", "deviceId"]
33441
+ });
33442
+ const fromMs = v.subject?.kind === "footage" ? v.subject.fromMs : v.fromMs;
33443
+ const toMs = v.subject?.kind === "footage" ? v.subject.toMs : v.toMs;
33444
+ if (typeof fromMs !== "number" || typeof toMs !== "number") ctx.addIssue({
33445
+ code: ZodIssueCode.custom,
33446
+ message: "a footage export needs fromMs and toMs",
33447
+ path: ["fromMs"]
33448
+ });
33449
+ if ((v.subject?.kind === "footage" ? [...v.subject.profiles] : resolveExportProfiles(v)).length < 1) ctx.addIssue({
32033
33450
  code: ZodIssueCode.custom,
32034
33451
  message: "pass profiles[] (min 1) or legacy profile",
32035
33452
  path: ["profiles"]
@@ -34841,6 +36258,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
34841
36258
  pressureSensor: pressureSensorCapability,
34842
36259
  privacyMask: privacyMaskCapability,
34843
36260
  ptzAutotrack: ptzAutotrackCapability,
36261
+ recordingOnboard: recordingOnboardCapability,
34844
36262
  recordingSignal: recordingSignalCapability,
34845
36263
  sceneMonitor: sceneMonitorCapability,
34846
36264
  scriptRunner: scriptRunnerCapability,
@@ -36002,7 +37420,1336 @@ var BaseDeviceProvider = class extends BaseAddon {
36002
37420
  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;
36003
37421
  new Set(Object.values(DeviceType));
36004
37422
  DeviceFeature.BatteryOperated;
37423
+ /**
37424
+ * The vocabulary, in the order a picker offers it.
37425
+ *
37426
+ * Adding a key here is not enough to make it pickable: both glyph tables must
37427
+ * gain it too, and their tests fail until they do. That is the intended
37428
+ * friction — it is the only thing that keeps the two surfaces honest.
37429
+ */
37430
+ var DISPLAY_ICON_VOCABULARY = [
37431
+ {
37432
+ key: "camera",
37433
+ group: "device",
37434
+ synonyms: [
37435
+ "telecamera",
37436
+ "videocamera",
37437
+ "camera",
37438
+ "cam"
37439
+ ]
37440
+ },
37441
+ {
37442
+ key: "network",
37443
+ group: "device",
37444
+ synonyms: [
37445
+ "rete",
37446
+ "network",
37447
+ "lan"
37448
+ ]
37449
+ },
37450
+ {
37451
+ key: "toggle-left",
37452
+ group: "device",
37453
+ synonyms: [
37454
+ "interruttore",
37455
+ "switch",
37456
+ "toggle"
37457
+ ]
37458
+ },
37459
+ {
37460
+ key: "toggle-right",
37461
+ group: "device",
37462
+ synonyms: [
37463
+ "interruttore",
37464
+ "switch",
37465
+ "toggle",
37466
+ "acceso"
37467
+ ]
37468
+ },
37469
+ {
37470
+ key: "circle-dot",
37471
+ group: "device",
37472
+ synonyms: [
37473
+ "pulsante",
37474
+ "bottone",
37475
+ "button",
37476
+ "dot"
37477
+ ]
37478
+ },
37479
+ {
37480
+ key: "refresh-cw",
37481
+ group: "device",
37482
+ synonyms: [
37483
+ "aggiorna",
37484
+ "ricarica",
37485
+ "refresh",
37486
+ "reload",
37487
+ "ciclo"
37488
+ ]
37489
+ },
37490
+ {
37491
+ key: "box",
37492
+ group: "device",
37493
+ synonyms: [
37494
+ "scatola",
37495
+ "box",
37496
+ "contenitore"
37497
+ ]
37498
+ },
37499
+ {
37500
+ key: "scroll-text",
37501
+ group: "device",
37502
+ synonyms: [
37503
+ "registro",
37504
+ "log",
37505
+ "testo"
37506
+ ]
37507
+ },
37508
+ {
37509
+ key: "workflow",
37510
+ group: "device",
37511
+ synonyms: [
37512
+ "automazione",
37513
+ "flusso",
37514
+ "workflow",
37515
+ "scenario"
37516
+ ]
37517
+ },
37518
+ {
37519
+ key: "lock",
37520
+ group: "device",
37521
+ synonyms: [
37522
+ "serratura",
37523
+ "chiave",
37524
+ "lucchetto",
37525
+ "chiuso",
37526
+ "locked"
37527
+ ]
37528
+ },
37529
+ {
37530
+ key: "lock-open",
37531
+ group: "device",
37532
+ synonyms: [
37533
+ "serratura",
37534
+ "aperta",
37535
+ "sbloccato",
37536
+ "unlocked"
37537
+ ]
37538
+ },
37539
+ {
37540
+ key: "blinds",
37541
+ group: "device",
37542
+ synonyms: [
37543
+ "tapparella",
37544
+ "persiana",
37545
+ "serranda",
37546
+ "avvolgibile",
37547
+ "shutter",
37548
+ "blind",
37549
+ "veneziana"
37550
+ ]
37551
+ },
37552
+ {
37553
+ key: "air-vent",
37554
+ group: "device",
37555
+ synonyms: [
37556
+ "bocchetta",
37557
+ "aria",
37558
+ "ventilazione",
37559
+ "condizionatore",
37560
+ "vent"
37561
+ ]
37562
+ },
37563
+ {
37564
+ key: "monitor-play",
37565
+ group: "device",
37566
+ synonyms: [
37567
+ "schermo",
37568
+ "riproduzione",
37569
+ "player",
37570
+ "display"
37571
+ ]
37572
+ },
37573
+ {
37574
+ key: "sliders-horizontal",
37575
+ group: "device",
37576
+ synonyms: [
37577
+ "regolazione",
37578
+ "cursori",
37579
+ "impostazioni",
37580
+ "slider"
37581
+ ]
37582
+ },
37583
+ {
37584
+ key: "map-pin",
37585
+ group: "device",
37586
+ synonyms: [
37587
+ "posizione",
37588
+ "luogo",
37589
+ "mappa",
37590
+ "pin"
37591
+ ]
37592
+ },
37593
+ {
37594
+ key: "bot",
37595
+ group: "device",
37596
+ synonyms: [
37597
+ "robot",
37598
+ "aspirapolvere",
37599
+ "bot"
37600
+ ]
37601
+ },
37602
+ {
37603
+ key: "tractor",
37604
+ group: "device",
37605
+ synonyms: [
37606
+ "trattore",
37607
+ "tosaerba",
37608
+ "giardino"
37609
+ ]
37610
+ },
37611
+ {
37612
+ key: "image",
37613
+ group: "device",
37614
+ synonyms: [
37615
+ "immagine",
37616
+ "foto",
37617
+ "snapshot"
37618
+ ]
37619
+ },
37620
+ {
37621
+ key: "bone",
37622
+ group: "device",
37623
+ synonyms: ["osso", "cane"]
37624
+ },
37625
+ {
37626
+ key: "door-closed",
37627
+ group: "device",
37628
+ synonyms: [
37629
+ "porta",
37630
+ "chiusa",
37631
+ "contatto"
37632
+ ]
37633
+ },
37634
+ {
37635
+ key: "door-open",
37636
+ group: "device",
37637
+ synonyms: [
37638
+ "porta",
37639
+ "aperta",
37640
+ "contatto",
37641
+ "ingresso",
37642
+ "uscita"
37643
+ ]
37644
+ },
37645
+ {
37646
+ key: "crosshair",
37647
+ group: "device",
37648
+ synonyms: [
37649
+ "mirino",
37650
+ "puntamento",
37651
+ "centro"
37652
+ ]
37653
+ },
37654
+ {
37655
+ key: "eye",
37656
+ group: "device",
37657
+ synonyms: [
37658
+ "occhio",
37659
+ "visibile",
37660
+ "visto"
37661
+ ]
37662
+ },
37663
+ {
37664
+ key: "eye-off",
37665
+ group: "device",
37666
+ synonyms: [
37667
+ "privacy",
37668
+ "nascosto",
37669
+ "oscurato",
37670
+ "mascherato",
37671
+ "invisibile"
37672
+ ]
37673
+ },
37674
+ {
37675
+ key: "smartphone",
37676
+ group: "device",
37677
+ synonyms: [
37678
+ "telefono",
37679
+ "cellulare",
37680
+ "smartphone"
37681
+ ]
37682
+ },
37683
+ {
37684
+ key: "phone",
37685
+ group: "device",
37686
+ synonyms: ["telefono", "chiamata"]
37687
+ },
37688
+ {
37689
+ key: "tablet",
37690
+ group: "device",
37691
+ synonyms: ["tablet", "ipad"]
37692
+ },
37693
+ {
37694
+ key: "laptop",
37695
+ group: "device",
37696
+ synonyms: [
37697
+ "portatile",
37698
+ "laptop",
37699
+ "notebook"
37700
+ ]
37701
+ },
37702
+ {
37703
+ key: "monitor",
37704
+ group: "device",
37705
+ synonyms: ["monitor", "schermo"]
37706
+ },
37707
+ {
37708
+ key: "tv",
37709
+ group: "device",
37710
+ synonyms: ["televisore", "tv"]
37711
+ },
37712
+ {
37713
+ key: "speaker",
37714
+ group: "device",
37715
+ synonyms: [
37716
+ "altoparlante",
37717
+ "cassa",
37718
+ "speaker"
37719
+ ]
37720
+ },
37721
+ {
37722
+ key: "printer",
37723
+ group: "device",
37724
+ synonyms: ["stampante"]
37725
+ },
37726
+ {
37727
+ key: "projector",
37728
+ group: "device",
37729
+ synonyms: ["proiettore"]
37730
+ },
37731
+ {
37732
+ key: "gamepad-2",
37733
+ group: "device",
37734
+ synonyms: [
37735
+ "console",
37736
+ "gioco",
37737
+ "joystick"
37738
+ ]
37739
+ },
37740
+ {
37741
+ key: "radio",
37742
+ group: "device",
37743
+ synonyms: ["radio"]
37744
+ },
37745
+ {
37746
+ key: "router",
37747
+ group: "device",
37748
+ synonyms: ["router", "modem"]
37749
+ },
37750
+ {
37751
+ key: "bluetooth",
37752
+ group: "device",
37753
+ synonyms: ["bluetooth"]
37754
+ },
37755
+ {
37756
+ key: "cpu",
37757
+ group: "device",
37758
+ synonyms: [
37759
+ "processore",
37760
+ "cpu",
37761
+ "chip",
37762
+ "dispositivo"
37763
+ ]
37764
+ },
37765
+ {
37766
+ key: "hard-drive",
37767
+ group: "device",
37768
+ synonyms: [
37769
+ "disco",
37770
+ "hdd",
37771
+ "archiviazione",
37772
+ "storage"
37773
+ ]
37774
+ },
37775
+ {
37776
+ key: "server",
37777
+ group: "device",
37778
+ synonyms: ["server", "nas"]
37779
+ },
37780
+ {
37781
+ key: "mic",
37782
+ group: "device",
37783
+ synonyms: ["microfono", "audio"]
37784
+ },
37785
+ {
37786
+ key: "mic-off",
37787
+ group: "device",
37788
+ synonyms: [
37789
+ "microfono",
37790
+ "spento",
37791
+ "muto"
37792
+ ]
37793
+ },
37794
+ {
37795
+ key: "video",
37796
+ group: "device",
37797
+ synonyms: ["video"]
37798
+ },
37799
+ {
37800
+ key: "video-off",
37801
+ group: "device",
37802
+ synonyms: ["video", "spento"]
37803
+ },
37804
+ {
37805
+ key: "music",
37806
+ group: "device",
37807
+ synonyms: ["musica"]
37808
+ },
37809
+ {
37810
+ key: "plug",
37811
+ group: "device",
37812
+ synonyms: [
37813
+ "presa",
37814
+ "spina",
37815
+ "plug"
37816
+ ]
37817
+ },
37818
+ {
37819
+ key: "plug-zap",
37820
+ group: "device",
37821
+ synonyms: ["presa", "alimentata"]
37822
+ },
37823
+ {
37824
+ key: "power",
37825
+ group: "device",
37826
+ synonyms: [
37827
+ "accensione",
37828
+ "alimentazione",
37829
+ "power"
37830
+ ]
37831
+ },
37832
+ {
37833
+ key: "power-off",
37834
+ group: "device",
37835
+ synonyms: ["spegnimento", "spento"]
37836
+ },
37837
+ {
37838
+ key: "cable",
37839
+ group: "device",
37840
+ synonyms: ["cavo"]
37841
+ },
37842
+ {
37843
+ key: "battery",
37844
+ group: "device",
37845
+ synonyms: ["batteria"]
37846
+ },
37847
+ {
37848
+ key: "battery-charging",
37849
+ group: "device",
37850
+ synonyms: [
37851
+ "batteria",
37852
+ "carica",
37853
+ "ricarica"
37854
+ ]
37855
+ },
37856
+ {
37857
+ key: "battery-full",
37858
+ group: "device",
37859
+ synonyms: [
37860
+ "batteria",
37861
+ "carica",
37862
+ "piena"
37863
+ ]
37864
+ },
37865
+ {
37866
+ key: "battery-low",
37867
+ group: "device",
37868
+ synonyms: ["batteria", "scarica"]
37869
+ },
37870
+ {
37871
+ key: "key",
37872
+ group: "device",
37873
+ synonyms: ["chiave"]
37874
+ },
37875
+ {
37876
+ key: "key-round",
37877
+ group: "device",
37878
+ synonyms: ["chiave", "tonda"]
37879
+ },
37880
+ {
37881
+ key: "mailbox",
37882
+ group: "device",
37883
+ synonyms: [
37884
+ "cassetta",
37885
+ "postale",
37886
+ "posta"
37887
+ ]
37888
+ },
37889
+ {
37890
+ key: "package",
37891
+ group: "device",
37892
+ synonyms: ["pacco", "consegna"]
37893
+ },
37894
+ {
37895
+ key: "shield",
37896
+ group: "device",
37897
+ synonyms: [
37898
+ "scudo",
37899
+ "protezione",
37900
+ "sicurezza",
37901
+ "allarme"
37902
+ ]
37903
+ },
37904
+ {
37905
+ key: "shield-check",
37906
+ group: "device",
37907
+ synonyms: [
37908
+ "protetto",
37909
+ "sicuro",
37910
+ "armato"
37911
+ ]
37912
+ },
37913
+ {
37914
+ key: "shield-off",
37915
+ group: "device",
37916
+ synonyms: [
37917
+ "protezione",
37918
+ "disattivata",
37919
+ "disarmato"
37920
+ ]
37921
+ },
37922
+ {
37923
+ key: "briefcase",
37924
+ group: "device",
37925
+ synonyms: [
37926
+ "ufficio",
37927
+ "lavoro",
37928
+ "valigetta",
37929
+ "studio"
37930
+ ]
37931
+ },
37932
+ {
37933
+ key: "lightbulb",
37934
+ group: "lighting",
37935
+ synonyms: [
37936
+ "luce",
37937
+ "lampadina",
37938
+ "lampada",
37939
+ "light"
37940
+ ]
37941
+ },
37942
+ {
37943
+ key: "lamp",
37944
+ group: "lighting",
37945
+ synonyms: ["lampada", "abatjour"]
37946
+ },
37947
+ {
37948
+ key: "lamp-ceiling",
37949
+ group: "lighting",
37950
+ synonyms: [
37951
+ "plafoniera",
37952
+ "lampadario",
37953
+ "luce",
37954
+ "soffitto"
37955
+ ]
37956
+ },
37957
+ {
37958
+ key: "lamp-desk",
37959
+ group: "lighting",
37960
+ synonyms: [
37961
+ "lampada",
37962
+ "scrivania",
37963
+ "abatjour"
37964
+ ]
37965
+ },
37966
+ {
37967
+ key: "lamp-floor",
37968
+ group: "lighting",
37969
+ synonyms: [
37970
+ "piantana",
37971
+ "lampada",
37972
+ "terra"
37973
+ ]
37974
+ },
37975
+ {
37976
+ key: "flashlight",
37977
+ group: "lighting",
37978
+ synonyms: [
37979
+ "faretto",
37980
+ "torcia",
37981
+ "spot",
37982
+ "faro"
37983
+ ]
37984
+ },
37985
+ {
37986
+ key: "heater",
37987
+ group: "lighting",
37988
+ synonyms: [
37989
+ "riscaldamento",
37990
+ "termosifone",
37991
+ "stufa",
37992
+ "calore"
37993
+ ]
37994
+ },
37995
+ {
37996
+ key: "snowflake",
37997
+ group: "lighting",
37998
+ synonyms: [
37999
+ "freddo",
38000
+ "raffrescamento",
38001
+ "aria",
38002
+ "condizionata",
38003
+ "neve"
38004
+ ]
38005
+ },
38006
+ {
38007
+ key: "thermometer-sun",
38008
+ group: "lighting",
38009
+ synonyms: [
38010
+ "caldo",
38011
+ "temperatura",
38012
+ "alta"
38013
+ ]
38014
+ },
38015
+ {
38016
+ key: "thermometer-snowflake",
38017
+ group: "lighting",
38018
+ synonyms: [
38019
+ "freddo",
38020
+ "temperatura",
38021
+ "bassa"
38022
+ ]
38023
+ },
38024
+ {
38025
+ key: "refrigerator",
38026
+ group: "lighting",
38027
+ synonyms: ["frigorifero", "frigo"]
38028
+ },
38029
+ {
38030
+ key: "microwave",
38031
+ group: "lighting",
38032
+ synonyms: ["microonde", "forno"]
38033
+ },
38034
+ {
38035
+ key: "washing-machine",
38036
+ group: "lighting",
38037
+ synonyms: [
38038
+ "lavatrice",
38039
+ "lavastoviglie",
38040
+ "asciugatrice"
38041
+ ]
38042
+ },
38043
+ {
38044
+ key: "cooking-pot",
38045
+ group: "lighting",
38046
+ synonyms: [
38047
+ "pentola",
38048
+ "cucina",
38049
+ "fornello"
38050
+ ]
38051
+ },
38052
+ {
38053
+ key: "utensils",
38054
+ group: "lighting",
38055
+ synonyms: [
38056
+ "cucina",
38057
+ "posate",
38058
+ "sala",
38059
+ "pranzo"
38060
+ ]
38061
+ },
38062
+ {
38063
+ key: "thermometer",
38064
+ group: "sensing",
38065
+ synonyms: [
38066
+ "temperatura",
38067
+ "termometro",
38068
+ "termostato"
38069
+ ]
38070
+ },
38071
+ {
38072
+ key: "droplets",
38073
+ group: "sensing",
38074
+ synonyms: [
38075
+ "umidita",
38076
+ "acqua",
38077
+ "allagamento",
38078
+ "perdita"
38079
+ ]
38080
+ },
38081
+ {
38082
+ key: "droplet",
38083
+ group: "sensing",
38084
+ synonyms: [
38085
+ "goccia",
38086
+ "acqua",
38087
+ "perdita",
38088
+ "allagamento"
38089
+ ]
38090
+ },
38091
+ {
38092
+ key: "gauge",
38093
+ group: "sensing",
38094
+ synonyms: [
38095
+ "misura",
38096
+ "livello",
38097
+ "pressione",
38098
+ "indicatore"
38099
+ ]
38100
+ },
38101
+ {
38102
+ key: "gauge2",
38103
+ group: "sensing",
38104
+ synonyms: [
38105
+ "misura",
38106
+ "livello",
38107
+ "pressione",
38108
+ "indicatore"
38109
+ ],
38110
+ aliasOf: "gauge"
38111
+ },
38112
+ {
38113
+ key: "sun",
38114
+ group: "sensing",
38115
+ synonyms: [
38116
+ "sole",
38117
+ "luminosita",
38118
+ "giorno",
38119
+ "esterno"
38120
+ ]
38121
+ },
38122
+ {
38123
+ key: "sun-medium",
38124
+ group: "sensing",
38125
+ synonyms: ["sole", "luminosita"]
38126
+ },
38127
+ {
38128
+ key: "sunrise",
38129
+ group: "sensing",
38130
+ synonyms: ["alba"]
38131
+ },
38132
+ {
38133
+ key: "moon",
38134
+ group: "sensing",
38135
+ synonyms: [
38136
+ "notte",
38137
+ "luna",
38138
+ "notturna",
38139
+ "nightvision"
38140
+ ]
38141
+ },
38142
+ {
38143
+ key: "wind",
38144
+ group: "sensing",
38145
+ synonyms: [
38146
+ "vento",
38147
+ "aria",
38148
+ "gas",
38149
+ "monossido",
38150
+ "co"
38151
+ ]
38152
+ },
38153
+ {
38154
+ key: "cloud",
38155
+ group: "sensing",
38156
+ synonyms: ["nuvola", "nuvoloso"]
38157
+ },
38158
+ {
38159
+ key: "cloud-rain",
38160
+ group: "sensing",
38161
+ synonyms: ["pioggia"]
38162
+ },
38163
+ {
38164
+ key: "cloud-sun",
38165
+ group: "sensing",
38166
+ synonyms: [
38167
+ "variabile",
38168
+ "sole",
38169
+ "nuvole"
38170
+ ]
38171
+ },
38172
+ {
38173
+ key: "waves",
38174
+ group: "sensing",
38175
+ synonyms: [
38176
+ "onde",
38177
+ "acqua",
38178
+ "vibrazione"
38179
+ ]
38180
+ },
38181
+ {
38182
+ key: "sprout",
38183
+ group: "sensing",
38184
+ synonyms: [
38185
+ "irrigazione",
38186
+ "pianta",
38187
+ "germoglio",
38188
+ "orto"
38189
+ ]
38190
+ },
38191
+ {
38192
+ key: "leaf",
38193
+ group: "sensing",
38194
+ synonyms: [
38195
+ "foglia",
38196
+ "pianta",
38197
+ "verde"
38198
+ ]
38199
+ },
38200
+ {
38201
+ key: "flower",
38202
+ group: "sensing",
38203
+ synonyms: ["fiore", "pianta"]
38204
+ },
38205
+ {
38206
+ key: "zap",
38207
+ group: "sensing",
38208
+ synonyms: [
38209
+ "energia",
38210
+ "corrente",
38211
+ "consumo",
38212
+ "watt",
38213
+ "elettricita"
38214
+ ]
38215
+ },
38216
+ {
38217
+ key: "flame",
38218
+ group: "sensing",
38219
+ synonyms: [
38220
+ "fiamma",
38221
+ "gas",
38222
+ "fuoco",
38223
+ "incendio"
38224
+ ]
38225
+ },
38226
+ {
38227
+ key: "bell",
38228
+ group: "sensing",
38229
+ synonyms: [
38230
+ "campanello",
38231
+ "suoneria",
38232
+ "notifica",
38233
+ "bell",
38234
+ "chime"
38235
+ ]
38236
+ },
38237
+ {
38238
+ key: "bell-ring",
38239
+ group: "sensing",
38240
+ synonyms: [
38241
+ "campanello",
38242
+ "suona",
38243
+ "doorbell",
38244
+ "notifica"
38245
+ ]
38246
+ },
38247
+ {
38248
+ key: "bell-off",
38249
+ group: "sensing",
38250
+ synonyms: [
38251
+ "silenzioso",
38252
+ "notifiche",
38253
+ "disattivate",
38254
+ "muto"
38255
+ ]
38256
+ },
38257
+ {
38258
+ key: "siren",
38259
+ group: "sensing",
38260
+ synonyms: ["sirena", "allarme"]
38261
+ },
38262
+ {
38263
+ key: "radar",
38264
+ group: "sensing",
38265
+ synonyms: [
38266
+ "movimento",
38267
+ "presenza",
38268
+ "pir",
38269
+ "rilevamento",
38270
+ "radar"
38271
+ ]
38272
+ },
38273
+ {
38274
+ key: "activity",
38275
+ group: "sensing",
38276
+ synonyms: [
38277
+ "attivita",
38278
+ "sensore",
38279
+ "generico"
38280
+ ]
38281
+ },
38282
+ {
38283
+ key: "hash",
38284
+ group: "sensing",
38285
+ synonyms: [
38286
+ "numero",
38287
+ "contatore",
38288
+ "valore"
38289
+ ]
38290
+ },
38291
+ {
38292
+ key: "clock",
38293
+ group: "sensing",
38294
+ synonyms: [
38295
+ "orologio",
38296
+ "ora",
38297
+ "tempo"
38298
+ ]
38299
+ },
38300
+ {
38301
+ key: "timer",
38302
+ group: "sensing",
38303
+ synonyms: [
38304
+ "timer",
38305
+ "conto",
38306
+ "rovescia"
38307
+ ]
38308
+ },
38309
+ {
38310
+ key: "calendar",
38311
+ group: "sensing",
38312
+ synonyms: [
38313
+ "calendario",
38314
+ "data",
38315
+ "pianificazione"
38316
+ ]
38317
+ },
38318
+ {
38319
+ key: "pipette",
38320
+ group: "sensing",
38321
+ synonyms: [
38322
+ "qualita",
38323
+ "aria",
38324
+ "misura",
38325
+ "campione"
38326
+ ]
38327
+ },
38328
+ {
38329
+ key: "fan",
38330
+ group: "sensing",
38331
+ synonyms: [
38332
+ "ventilatore",
38333
+ "ventola",
38334
+ "aria"
38335
+ ]
38336
+ },
38337
+ {
38338
+ key: "bath",
38339
+ group: "sensing",
38340
+ synonyms: [
38341
+ "bagno",
38342
+ "vasca",
38343
+ "doccia"
38344
+ ]
38345
+ },
38346
+ {
38347
+ key: "footprints",
38348
+ group: "sensing",
38349
+ synonyms: [
38350
+ "movimento",
38351
+ "passi",
38352
+ "presenza",
38353
+ "motion"
38354
+ ]
38355
+ },
38356
+ {
38357
+ key: "alarm-smoke",
38358
+ group: "sensing",
38359
+ synonyms: [
38360
+ "fumo",
38361
+ "antincendio",
38362
+ "rilevatore"
38363
+ ]
38364
+ },
38365
+ {
38366
+ key: "shield-alert",
38367
+ group: "sensing",
38368
+ synonyms: [
38369
+ "manomissione",
38370
+ "allarme",
38371
+ "tamper",
38372
+ "avviso"
38373
+ ]
38374
+ },
38375
+ {
38376
+ key: "vibrate",
38377
+ group: "sensing",
38378
+ synonyms: [
38379
+ "vibrazione",
38380
+ "urto",
38381
+ "tamper"
38382
+ ]
38383
+ },
38384
+ {
38385
+ key: "wifi",
38386
+ group: "sensing",
38387
+ synonyms: [
38388
+ "wifi",
38389
+ "rete",
38390
+ "segnale"
38391
+ ]
38392
+ },
38393
+ {
38394
+ key: "wifi-off",
38395
+ group: "sensing",
38396
+ synonyms: [
38397
+ "wifi",
38398
+ "assente",
38399
+ "offline",
38400
+ "disconnesso"
38401
+ ]
38402
+ },
38403
+ {
38404
+ key: "volume-2",
38405
+ group: "sensing",
38406
+ synonyms: [
38407
+ "volume",
38408
+ "audio",
38409
+ "altoparlante",
38410
+ "suono"
38411
+ ]
38412
+ },
38413
+ {
38414
+ key: "volume-x",
38415
+ group: "sensing",
38416
+ synonyms: [
38417
+ "muto",
38418
+ "silenziato",
38419
+ "volume",
38420
+ "spento"
38421
+ ]
38422
+ },
38423
+ {
38424
+ key: "heart",
38425
+ group: "sensing",
38426
+ synonyms: [
38427
+ "cuore",
38428
+ "preferito",
38429
+ "salute"
38430
+ ]
38431
+ },
38432
+ {
38433
+ key: "heart-pulse",
38434
+ group: "sensing",
38435
+ synonyms: [
38436
+ "battito",
38437
+ "salute",
38438
+ "monitoraggio"
38439
+ ]
38440
+ },
38441
+ {
38442
+ key: "star",
38443
+ group: "sensing",
38444
+ synonyms: [
38445
+ "preferito",
38446
+ "stella",
38447
+ "importante"
38448
+ ]
38449
+ },
38450
+ {
38451
+ key: "sparkles",
38452
+ group: "sensing",
38453
+ synonyms: [
38454
+ "automatico",
38455
+ "intelligente",
38456
+ "ai",
38457
+ "scena"
38458
+ ]
38459
+ },
38460
+ {
38461
+ key: "house",
38462
+ group: "place",
38463
+ synonyms: [
38464
+ "casa",
38465
+ "abitazione",
38466
+ "home"
38467
+ ]
38468
+ },
38469
+ {
38470
+ key: "sofa",
38471
+ group: "place",
38472
+ synonyms: [
38473
+ "salone",
38474
+ "soggiorno",
38475
+ "divano",
38476
+ "living"
38477
+ ]
38478
+ },
38479
+ {
38480
+ key: "bed-double",
38481
+ group: "place",
38482
+ synonyms: [
38483
+ "camera",
38484
+ "letto",
38485
+ "matrimoniale"
38486
+ ]
38487
+ },
38488
+ {
38489
+ key: "bed",
38490
+ group: "place",
38491
+ synonyms: [
38492
+ "cameretta",
38493
+ "letto",
38494
+ "singolo"
38495
+ ]
38496
+ },
38497
+ {
38498
+ key: "warehouse",
38499
+ group: "place",
38500
+ synonyms: [
38501
+ "magazzino",
38502
+ "capanno",
38503
+ "deposito",
38504
+ "cantina"
38505
+ ]
38506
+ },
38507
+ {
38508
+ key: "trees",
38509
+ group: "place",
38510
+ synonyms: [
38511
+ "giardino",
38512
+ "alberi",
38513
+ "esterno",
38514
+ "parco"
38515
+ ]
38516
+ },
38517
+ {
38518
+ key: "tree-pine",
38519
+ group: "place",
38520
+ synonyms: [
38521
+ "albero",
38522
+ "pino",
38523
+ "giardino"
38524
+ ]
38525
+ },
38526
+ {
38527
+ key: "fence",
38528
+ group: "place",
38529
+ synonyms: [
38530
+ "recinto",
38531
+ "cancello",
38532
+ "staccionata",
38533
+ "perimetro"
38534
+ ]
38535
+ },
38536
+ {
38537
+ key: "store",
38538
+ group: "place",
38539
+ synonyms: [
38540
+ "negozio",
38541
+ "ingresso",
38542
+ "vetrina"
38543
+ ]
38544
+ },
38545
+ {
38546
+ key: "building",
38547
+ group: "place",
38548
+ synonyms: ["edificio", "palazzo"]
38549
+ },
38550
+ {
38551
+ key: "building-2",
38552
+ group: "place",
38553
+ synonyms: [
38554
+ "edificio",
38555
+ "uffici",
38556
+ "condominio"
38557
+ ]
38558
+ },
38559
+ {
38560
+ key: "mountain",
38561
+ group: "place",
38562
+ synonyms: [
38563
+ "montagna",
38564
+ "esterno",
38565
+ "panorama"
38566
+ ]
38567
+ },
38568
+ {
38569
+ key: "umbrella",
38570
+ group: "place",
38571
+ synonyms: [
38572
+ "tenda",
38573
+ "markise",
38574
+ "ombrellone",
38575
+ "pergola",
38576
+ "veranda"
38577
+ ]
38578
+ },
38579
+ {
38580
+ key: "dumbbell",
38581
+ group: "place",
38582
+ synonyms: ["palestra", "attrezzi"]
38583
+ },
38584
+ {
38585
+ key: "wrench",
38586
+ group: "place",
38587
+ synonyms: [
38588
+ "officina",
38589
+ "manutenzione",
38590
+ "attrezzi",
38591
+ "utenze"
38592
+ ]
38593
+ },
38594
+ {
38595
+ key: "hammer",
38596
+ group: "place",
38597
+ synonyms: [
38598
+ "officina",
38599
+ "martello",
38600
+ "lavori"
38601
+ ]
38602
+ },
38603
+ {
38604
+ key: "drill",
38605
+ group: "place",
38606
+ synonyms: [
38607
+ "officina",
38608
+ "trapano",
38609
+ "lavori"
38610
+ ]
38611
+ },
38612
+ {
38613
+ key: "waves-ladder",
38614
+ group: "place",
38615
+ synonyms: ["piscina", "vasca"]
38616
+ },
38617
+ {
38618
+ key: "circle-parking",
38619
+ group: "place",
38620
+ synonyms: [
38621
+ "parcheggio",
38622
+ "posto",
38623
+ "auto",
38624
+ "garage"
38625
+ ]
38626
+ },
38627
+ {
38628
+ key: "route",
38629
+ group: "place",
38630
+ synonyms: [
38631
+ "percorso",
38632
+ "strada",
38633
+ "vialetto",
38634
+ "tragitto"
38635
+ ]
38636
+ },
38637
+ {
38638
+ key: "car",
38639
+ group: "life",
38640
+ synonyms: [
38641
+ "auto",
38642
+ "macchina",
38643
+ "veicolo",
38644
+ "parcheggio"
38645
+ ]
38646
+ },
38647
+ {
38648
+ key: "bike",
38649
+ group: "life",
38650
+ synonyms: [
38651
+ "bicicletta",
38652
+ "bici",
38653
+ "moto"
38654
+ ]
38655
+ },
38656
+ {
38657
+ key: "bus",
38658
+ group: "life",
38659
+ synonyms: ["autobus", "pullman"]
38660
+ },
38661
+ {
38662
+ key: "truck",
38663
+ group: "life",
38664
+ synonyms: [
38665
+ "camion",
38666
+ "furgone",
38667
+ "consegna"
38668
+ ]
38669
+ },
38670
+ {
38671
+ key: "plane",
38672
+ group: "life",
38673
+ synonyms: ["aereo"]
38674
+ },
38675
+ {
38676
+ key: "train-front",
38677
+ group: "life",
38678
+ synonyms: ["treno"]
38679
+ },
38680
+ {
38681
+ key: "sailboat",
38682
+ group: "life",
38683
+ synonyms: ["barca", "imbarcazione"]
38684
+ },
38685
+ {
38686
+ key: "dog",
38687
+ group: "life",
38688
+ synonyms: ["cane", "animale"]
38689
+ },
38690
+ {
38691
+ key: "cat",
38692
+ group: "life",
38693
+ synonyms: ["gatto", "animale"]
38694
+ },
38695
+ {
38696
+ key: "bird",
38697
+ group: "life",
38698
+ synonyms: ["uccello", "animale"]
38699
+ },
38700
+ {
38701
+ key: "paw-print",
38702
+ group: "life",
38703
+ synonyms: [
38704
+ "animale",
38705
+ "zampa",
38706
+ "pet"
38707
+ ]
38708
+ },
38709
+ {
38710
+ key: "baby",
38711
+ group: "life",
38712
+ synonyms: [
38713
+ "neonato",
38714
+ "bimbo",
38715
+ "cameretta",
38716
+ "babymonitor"
38717
+ ]
38718
+ },
38719
+ {
38720
+ key: "user",
38721
+ group: "life",
38722
+ synonyms: ["persona", "utente"]
38723
+ },
38724
+ {
38725
+ key: "users",
38726
+ group: "life",
38727
+ synonyms: [
38728
+ "persone",
38729
+ "gruppo",
38730
+ "famiglia"
38731
+ ]
38732
+ },
38733
+ {
38734
+ key: "person-standing",
38735
+ group: "life",
38736
+ synonyms: [
38737
+ "persona",
38738
+ "piedi",
38739
+ "presenza"
38740
+ ]
38741
+ }
38742
+ ];
38743
+ DISPLAY_ICON_VOCABULARY.map((e) => e.key);
38744
+ DISPLAY_ICON_VOCABULARY.filter((e) => e.aliasOf === void 0).map((e) => e.key);
38745
+ new Map(DISPLAY_ICON_VOCABULARY.map((e) => [e.key, e]));
36005
38746
  Object.freeze({
38747
+ "accessories.getStatus": {
38748
+ capName: "accessories",
38749
+ capScope: "device",
38750
+ addonId: null,
38751
+ access: "view"
38752
+ },
36006
38753
  "accessories.setChildHidden": {
36007
38754
  capName: "accessories",
36008
38755
  capScope: "device",
@@ -36285,6 +39032,12 @@ Object.freeze({
36285
39032
  addonId: null,
36286
39033
  access: "view"
36287
39034
  },
39035
+ "airQualitySensor.getStatus": {
39036
+ capName: "air-quality-sensor",
39037
+ capScope: "device",
39038
+ addonId: null,
39039
+ access: "view"
39040
+ },
36288
39041
  "alarmPanel.arm": {
36289
39042
  capName: "alarm-panel",
36290
39043
  capScope: "device",
@@ -36297,6 +39050,12 @@ Object.freeze({
36297
39050
  addonId: null,
36298
39051
  access: "create"
36299
39052
  },
39053
+ "alarmPanel.getStatus": {
39054
+ capName: "alarm-panel",
39055
+ capScope: "device",
39056
+ addonId: null,
39057
+ access: "view"
39058
+ },
36300
39059
  "alarmPanel.trigger": {
36301
39060
  capName: "alarm-panel",
36302
39061
  capScope: "device",
@@ -36345,6 +39104,30 @@ Object.freeze({
36345
39104
  addonId: null,
36346
39105
  access: "create"
36347
39106
  },
39107
+ "ambientLightSensor.getStatus": {
39108
+ capName: "ambient-light-sensor",
39109
+ capScope: "device",
39110
+ addonId: null,
39111
+ access: "view"
39112
+ },
39113
+ "audioAnalysis.applyDeviceSettingsPatch": {
39114
+ capName: "audio-analysis",
39115
+ capScope: "device",
39116
+ addonId: null,
39117
+ access: "create"
39118
+ },
39119
+ "audioAnalysis.getDeviceLiveContribution": {
39120
+ capName: "audio-analysis",
39121
+ capScope: "device",
39122
+ addonId: null,
39123
+ access: "view"
39124
+ },
39125
+ "audioAnalysis.getDeviceSettingsContribution": {
39126
+ capName: "audio-analysis",
39127
+ capScope: "device",
39128
+ addonId: null,
39129
+ access: "view"
39130
+ },
36348
39131
  "audioAnalysis.resolveDeviceSettings": {
36349
39132
  capName: "audio-analysis",
36350
39133
  capScope: "device",
@@ -36507,6 +39290,12 @@ Object.freeze({
36507
39290
  addonId: null,
36508
39291
  access: "create"
36509
39292
  },
39293
+ "automationControl.getStatus": {
39294
+ capName: "automation-control",
39295
+ capScope: "device",
39296
+ addonId: null,
39297
+ access: "view"
39298
+ },
36510
39299
  "automationControl.trigger": {
36511
39300
  capName: "automation-control",
36512
39301
  capScope: "device",
@@ -36603,12 +39392,30 @@ Object.freeze({
36603
39392
  addonId: null,
36604
39393
  access: "create"
36605
39394
  },
39395
+ "battery.getStatus": {
39396
+ capName: "battery",
39397
+ capScope: "device",
39398
+ addonId: null,
39399
+ access: "view"
39400
+ },
36606
39401
  "battery.wakeForStream": {
36607
39402
  capName: "battery",
36608
39403
  capScope: "device",
36609
39404
  addonId: null,
36610
39405
  access: "create"
36611
39406
  },
39407
+ "binary.getStatus": {
39408
+ capName: "binary",
39409
+ capScope: "device",
39410
+ addonId: null,
39411
+ access: "view"
39412
+ },
39413
+ "brightness.getStatus": {
39414
+ capName: "brightness",
39415
+ capScope: "device",
39416
+ addonId: null,
39417
+ access: "view"
39418
+ },
36612
39419
  "brightness.setBrightness": {
36613
39420
  capName: "brightness",
36614
39421
  capScope: "device",
@@ -36723,6 +39530,30 @@ Object.freeze({
36723
39530
  addonId: null,
36724
39531
  access: "view"
36725
39532
  },
39533
+ "cameraCredentials.getStatus": {
39534
+ capName: "camera-credentials",
39535
+ capScope: "device",
39536
+ addonId: null,
39537
+ access: "view"
39538
+ },
39539
+ "cameraGridLayout.applyDeviceSettingsPatch": {
39540
+ capName: "camera-grid-layout",
39541
+ capScope: "device",
39542
+ addonId: null,
39543
+ access: "create"
39544
+ },
39545
+ "cameraGridLayout.getDeviceLiveContribution": {
39546
+ capName: "camera-grid-layout",
39547
+ capScope: "device",
39548
+ addonId: null,
39549
+ access: "view"
39550
+ },
39551
+ "cameraGridLayout.getDeviceSettingsContribution": {
39552
+ capName: "camera-grid-layout",
39553
+ capScope: "device",
39554
+ addonId: null,
39555
+ access: "view"
39556
+ },
36726
39557
  "cameraGridLayout.getLayout": {
36727
39558
  capName: "camera-grid-layout",
36728
39559
  capScope: "device",
@@ -36735,6 +39566,24 @@ Object.freeze({
36735
39566
  addonId: null,
36736
39567
  access: "create"
36737
39568
  },
39569
+ "cameraPipelineConfig.applyDeviceSettingsPatch": {
39570
+ capName: "camera-pipeline-config",
39571
+ capScope: "device",
39572
+ addonId: null,
39573
+ access: "create"
39574
+ },
39575
+ "cameraPipelineConfig.getDeviceLiveContribution": {
39576
+ capName: "camera-pipeline-config",
39577
+ capScope: "device",
39578
+ addonId: null,
39579
+ access: "view"
39580
+ },
39581
+ "cameraPipelineConfig.getDeviceSettingsContribution": {
39582
+ capName: "camera-pipeline-config",
39583
+ capScope: "device",
39584
+ addonId: null,
39585
+ access: "view"
39586
+ },
36738
39587
  "cameraStreams.getBrokerStreams": {
36739
39588
  capName: "camera-streams",
36740
39589
  capScope: "device",
@@ -36765,6 +39614,18 @@ Object.freeze({
36765
39614
  addonId: null,
36766
39615
  access: "view"
36767
39616
  },
39617
+ "carbonMonoxide.getStatus": {
39618
+ capName: "carbon-monoxide",
39619
+ capScope: "device",
39620
+ addonId: null,
39621
+ access: "view"
39622
+ },
39623
+ "climateControl.getStatus": {
39624
+ capName: "climate-control",
39625
+ capScope: "device",
39626
+ addonId: null,
39627
+ access: "view"
39628
+ },
36768
39629
  "climateControl.setFanMode": {
36769
39630
  capName: "climate-control",
36770
39631
  capScope: "device",
@@ -36813,6 +39674,12 @@ Object.freeze({
36813
39674
  addonId: null,
36814
39675
  access: "create"
36815
39676
  },
39677
+ "color.getStatus": {
39678
+ capName: "color",
39679
+ capScope: "device",
39680
+ addonId: null,
39681
+ access: "view"
39682
+ },
36816
39683
  "color.setColor": {
36817
39684
  capName: "color",
36818
39685
  capScope: "device",
@@ -36831,12 +39698,36 @@ Object.freeze({
36831
39698
  addonId: null,
36832
39699
  access: "create"
36833
39700
  },
39701
+ "connectivity.getStatus": {
39702
+ capName: "connectivity",
39703
+ capScope: "device",
39704
+ addonId: null,
39705
+ access: "view"
39706
+ },
39707
+ "consumables.getStatus": {
39708
+ capName: "consumables",
39709
+ capScope: "device",
39710
+ addonId: null,
39711
+ access: "view"
39712
+ },
36834
39713
  "consumables.reset": {
36835
39714
  capName: "consumables",
36836
39715
  capScope: "device",
36837
39716
  addonId: null,
36838
39717
  access: "delete"
36839
39718
  },
39719
+ "contact.getStatus": {
39720
+ capName: "contact",
39721
+ capScope: "device",
39722
+ addonId: null,
39723
+ access: "view"
39724
+ },
39725
+ "control.getStatus": {
39726
+ capName: "control",
39727
+ capScope: "device",
39728
+ addonId: null,
39729
+ access: "view"
39730
+ },
36840
39731
  "control.setValue": {
36841
39732
  capName: "control",
36842
39733
  capScope: "device",
@@ -36903,6 +39794,12 @@ Object.freeze({
36903
39794
  addonId: null,
36904
39795
  access: "create"
36905
39796
  },
39797
+ "cover.getStatus": {
39798
+ capName: "cover",
39799
+ capScope: "device",
39800
+ addonId: null,
39801
+ access: "view"
39802
+ },
36906
39803
  "cover.open": {
36907
39804
  capName: "cover",
36908
39805
  capScope: "device",
@@ -37035,6 +39932,12 @@ Object.freeze({
37035
39932
  addonId: null,
37036
39933
  access: "view"
37037
39934
  },
39935
+ "dayNight.getStatus": {
39936
+ capName: "day-night",
39937
+ capScope: "device",
39938
+ addonId: null,
39939
+ access: "view"
39940
+ },
37038
39941
  "dayNight.setSettings": {
37039
39942
  capName: "day-night",
37040
39943
  capScope: "device",
@@ -37125,6 +40028,30 @@ Object.freeze({
37125
40028
  addonId: null,
37126
40029
  access: "view"
37127
40030
  },
40031
+ "detectionPipeline.applyDeviceSettingsPatch": {
40032
+ capName: "detection-pipeline",
40033
+ capScope: "device",
40034
+ addonId: null,
40035
+ access: "create"
40036
+ },
40037
+ "detectionPipeline.getDeviceLiveContribution": {
40038
+ capName: "detection-pipeline",
40039
+ capScope: "device",
40040
+ addonId: null,
40041
+ access: "view"
40042
+ },
40043
+ "detectionPipeline.getDeviceSettingsContribution": {
40044
+ capName: "detection-pipeline",
40045
+ capScope: "device",
40046
+ addonId: null,
40047
+ access: "view"
40048
+ },
40049
+ "deviceAdminLink.getAdminLink": {
40050
+ capName: "device-admin-link",
40051
+ capScope: "device",
40052
+ addonId: null,
40053
+ access: "view"
40054
+ },
37128
40055
  "deviceAdoption.adopt": {
37129
40056
  capName: "device-adoption",
37130
40057
  capScope: "system",
@@ -37137,6 +40064,12 @@ Object.freeze({
37137
40064
  addonId: null,
37138
40065
  access: "view"
37139
40066
  },
40067
+ "deviceAdoption.getStatus": {
40068
+ capName: "device-adoption",
40069
+ capScope: "system",
40070
+ addonId: null,
40071
+ access: "view"
40072
+ },
37140
40073
  "deviceAdoption.listCandidateFilters": {
37141
40074
  capName: "device-adoption",
37142
40075
  capScope: "system",
@@ -37173,6 +40106,12 @@ Object.freeze({
37173
40106
  addonId: null,
37174
40107
  access: "create"
37175
40108
  },
40109
+ "deviceDiscovery.getStatus": {
40110
+ capName: "device-discovery",
40111
+ capScope: "device",
40112
+ addonId: null,
40113
+ access: "view"
40114
+ },
37176
40115
  "deviceDiscovery.listDiscovered": {
37177
40116
  capName: "device-discovery",
37178
40117
  capScope: "device",
@@ -37191,12 +40130,30 @@ Object.freeze({
37191
40130
  addonId: null,
37192
40131
  access: "create"
37193
40132
  },
40133
+ "deviceExport.applyDeviceSettingsPatch": {
40134
+ capName: "device-export",
40135
+ capScope: "system",
40136
+ addonId: null,
40137
+ access: "create"
40138
+ },
37194
40139
  "deviceExport.exposeDevice": {
37195
40140
  capName: "device-export",
37196
40141
  capScope: "system",
37197
40142
  addonId: null,
37198
40143
  access: "create"
37199
40144
  },
40145
+ "deviceExport.getDeviceLiveContribution": {
40146
+ capName: "device-export",
40147
+ capScope: "system",
40148
+ addonId: null,
40149
+ access: "view"
40150
+ },
40151
+ "deviceExport.getDeviceSettingsContribution": {
40152
+ capName: "device-export",
40153
+ capScope: "system",
40154
+ addonId: null,
40155
+ access: "view"
40156
+ },
37200
40157
  "deviceExport.getStatus": {
37201
40158
  capName: "device-export",
37202
40159
  capScope: "system",
@@ -37293,6 +40250,12 @@ Object.freeze({
37293
40250
  addonId: null,
37294
40251
  access: "create"
37295
40252
  },
40253
+ "deviceManager.applyDeviceSettingsPatch": {
40254
+ capName: "device-manager",
40255
+ capScope: "system",
40256
+ addonId: null,
40257
+ access: "create"
40258
+ },
37296
40259
  "deviceManager.applyInitialMeta": {
37297
40260
  capName: "device-manager",
37298
40261
  capScope: "system",
@@ -37395,6 +40358,12 @@ Object.freeze({
37395
40358
  addonId: null,
37396
40359
  access: "view"
37397
40360
  },
40361
+ "deviceManager.getDeviceLiveContribution": {
40362
+ capName: "device-manager",
40363
+ capScope: "system",
40364
+ addonId: null,
40365
+ access: "view"
40366
+ },
37398
40367
  "deviceManager.getDeviceLiveInfoAggregate": {
37399
40368
  capName: "device-manager",
37400
40369
  capScope: "system",
@@ -37407,6 +40376,12 @@ Object.freeze({
37407
40376
  addonId: null,
37408
40377
  access: "view"
37409
40378
  },
40379
+ "deviceManager.getDeviceSettingsContribution": {
40380
+ capName: "device-manager",
40381
+ capScope: "system",
40382
+ addonId: null,
40383
+ access: "view"
40384
+ },
37410
40385
  "deviceManager.getDeviceStatusAggregate": {
37411
40386
  capName: "device-manager",
37412
40387
  capScope: "system",
@@ -37899,6 +40874,36 @@ Object.freeze({
37899
40874
  addonId: null,
37900
40875
  access: "create"
37901
40876
  },
40877
+ "deviceStatus.getStatus": {
40878
+ capName: "device-status",
40879
+ capScope: "device",
40880
+ addonId: null,
40881
+ access: "view"
40882
+ },
40883
+ "doorbell.applyDeviceSettingsPatch": {
40884
+ capName: "doorbell",
40885
+ capScope: "device",
40886
+ addonId: null,
40887
+ access: "create"
40888
+ },
40889
+ "doorbell.getDeviceLiveContribution": {
40890
+ capName: "doorbell",
40891
+ capScope: "device",
40892
+ addonId: null,
40893
+ access: "view"
40894
+ },
40895
+ "doorbell.getDeviceSettingsContribution": {
40896
+ capName: "doorbell",
40897
+ capScope: "device",
40898
+ addonId: null,
40899
+ access: "view"
40900
+ },
40901
+ "doorbell.getStatus": {
40902
+ capName: "doorbell",
40903
+ capScope: "device",
40904
+ addonId: null,
40905
+ access: "view"
40906
+ },
37902
40907
  "embeddingEncoder.encode": {
37903
40908
  capName: "embedding-encoder",
37904
40909
  capScope: "system",
@@ -37917,6 +40922,18 @@ Object.freeze({
37917
40922
  addonId: null,
37918
40923
  access: "view"
37919
40924
  },
40925
+ "enumSensor.getStatus": {
40926
+ capName: "enum-sensor",
40927
+ capScope: "device",
40928
+ addonId: null,
40929
+ access: "view"
40930
+ },
40931
+ "eventEmitter.getStatus": {
40932
+ capName: "event-emitter",
40933
+ capScope: "device",
40934
+ addonId: null,
40935
+ access: "view"
40936
+ },
37920
40937
  "events.getEventClipUrl": {
37921
40938
  capName: "events",
37922
40939
  capScope: "device",
@@ -38037,6 +41054,12 @@ Object.freeze({
38037
41054
  addonId: null,
38038
41055
  access: "view"
38039
41056
  },
41057
+ "fanControl.getStatus": {
41058
+ capName: "fan-control",
41059
+ capScope: "device",
41060
+ addonId: null,
41061
+ access: "view"
41062
+ },
38040
41063
  "fanControl.setDirection": {
38041
41064
  capName: "fan-control",
38042
41065
  capScope: "device",
@@ -38061,6 +41084,12 @@ Object.freeze({
38061
41084
  addonId: null,
38062
41085
  access: "create"
38063
41086
  },
41087
+ "featureProbe.getStatus": {
41088
+ capName: "feature-probe",
41089
+ capScope: "device",
41090
+ addonId: null,
41091
+ access: "view"
41092
+ },
38064
41093
  "filesystemBrowse.browse": {
38065
41094
  capName: "filesystem-browse",
38066
41095
  capScope: "system",
@@ -38079,6 +41108,24 @@ Object.freeze({
38079
41108
  addonId: null,
38080
41109
  access: "view"
38081
41110
  },
41111
+ "flood.getStatus": {
41112
+ capName: "flood",
41113
+ capScope: "device",
41114
+ addonId: null,
41115
+ access: "view"
41116
+ },
41117
+ "gas.getStatus": {
41118
+ capName: "gas",
41119
+ capScope: "device",
41120
+ addonId: null,
41121
+ access: "view"
41122
+ },
41123
+ "humidifier.getStatus": {
41124
+ capName: "humidifier",
41125
+ capScope: "device",
41126
+ addonId: null,
41127
+ access: "view"
41128
+ },
38082
41129
  "humidifier.setMode": {
38083
41130
  capName: "humidifier",
38084
41131
  capScope: "device",
@@ -38097,12 +41144,30 @@ Object.freeze({
38097
41144
  addonId: null,
38098
41145
  access: "create"
38099
41146
  },
41147
+ "humiditySensor.getStatus": {
41148
+ capName: "humidity-sensor",
41149
+ capScope: "device",
41150
+ addonId: null,
41151
+ access: "view"
41152
+ },
41153
+ "image.getStatus": {
41154
+ capName: "image",
41155
+ capScope: "device",
41156
+ addonId: null,
41157
+ access: "view"
41158
+ },
38100
41159
  "imageSettings.getOptions": {
38101
41160
  capName: "image-settings",
38102
41161
  capScope: "device",
38103
41162
  addonId: null,
38104
41163
  access: "view"
38105
41164
  },
41165
+ "imageSettings.getStatus": {
41166
+ capName: "image-settings",
41167
+ capScope: "device",
41168
+ addonId: null,
41169
+ access: "view"
41170
+ },
38106
41171
  "imageSettings.setSettings": {
38107
41172
  capName: "image-settings",
38108
41173
  capScope: "device",
@@ -38175,6 +41240,12 @@ Object.freeze({
38175
41240
  addonId: null,
38176
41241
  access: "create"
38177
41242
  },
41243
+ "intercom.getStatus": {
41244
+ capName: "intercom",
41245
+ capScope: "device",
41246
+ addonId: null,
41247
+ access: "view"
41248
+ },
38178
41249
  "intercom.handleAnswer": {
38179
41250
  capName: "intercom",
38180
41251
  capScope: "device",
@@ -38211,6 +41282,12 @@ Object.freeze({
38211
41282
  addonId: null,
38212
41283
  access: "create"
38213
41284
  },
41285
+ "lawnMowerControl.getStatus": {
41286
+ capName: "lawn-mower-control",
41287
+ capScope: "device",
41288
+ addonId: null,
41289
+ access: "view"
41290
+ },
38214
41291
  "lawnMowerControl.pause": {
38215
41292
  capName: "lawn-mower-control",
38216
41293
  capScope: "device",
@@ -38493,6 +41570,12 @@ Object.freeze({
38493
41570
  addonId: null,
38494
41571
  access: "create"
38495
41572
  },
41573
+ "lockControl.getStatus": {
41574
+ capName: "lock-control",
41575
+ capScope: "device",
41576
+ addonId: null,
41577
+ access: "view"
41578
+ },
38496
41579
  "lockControl.lock": {
38497
41580
  capName: "lock-control",
38498
41581
  capScope: "device",
@@ -38541,6 +41624,12 @@ Object.freeze({
38541
41624
  addonId: null,
38542
41625
  access: "view"
38543
41626
  },
41627
+ "mediaPlayer.getStatus": {
41628
+ capName: "media-player",
41629
+ capScope: "device",
41630
+ addonId: null,
41631
+ access: "view"
41632
+ },
38544
41633
  "mediaPlayer.next": {
38545
41634
  capName: "media-player",
38546
41635
  capScope: "device",
@@ -38733,6 +41822,12 @@ Object.freeze({
38733
41822
  addonId: null,
38734
41823
  access: "create"
38735
41824
  },
41825
+ "motion.getStatus": {
41826
+ capName: "motion",
41827
+ capScope: "device",
41828
+ addonId: null,
41829
+ access: "view"
41830
+ },
38736
41831
  "motion.isDetected": {
38737
41832
  capName: "motion",
38738
41833
  capScope: "device",
@@ -38745,6 +41840,24 @@ Object.freeze({
38745
41840
  addonId: null,
38746
41841
  access: "create"
38747
41842
  },
41843
+ "motionDetection.applyDeviceSettingsPatch": {
41844
+ capName: "motion-detection",
41845
+ capScope: "device",
41846
+ addonId: null,
41847
+ access: "create"
41848
+ },
41849
+ "motionDetection.getDeviceLiveContribution": {
41850
+ capName: "motion-detection",
41851
+ capScope: "device",
41852
+ addonId: null,
41853
+ access: "view"
41854
+ },
41855
+ "motionDetection.getDeviceSettingsContribution": {
41856
+ capName: "motion-detection",
41857
+ capScope: "device",
41858
+ addonId: null,
41859
+ access: "view"
41860
+ },
38748
41861
  "motionDetection.removeCamera": {
38749
41862
  capName: "motion-detection",
38750
41863
  capScope: "device",
@@ -38757,6 +41870,12 @@ Object.freeze({
38757
41870
  addonId: null,
38758
41871
  access: "delete"
38759
41872
  },
41873
+ "motionTrigger.getStatus": {
41874
+ capName: "motion-trigger",
41875
+ capScope: "device",
41876
+ addonId: null,
41877
+ access: "view"
41878
+ },
38760
41879
  "motionTrigger.setMotionTrigger": {
38761
41880
  capName: "motion-trigger",
38762
41881
  capScope: "device",
@@ -38769,6 +41888,12 @@ Object.freeze({
38769
41888
  addonId: null,
38770
41889
  access: "view"
38771
41890
  },
41891
+ "motionZones.getStatus": {
41892
+ capName: "motion-zones",
41893
+ capScope: "device",
41894
+ addonId: null,
41895
+ access: "view"
41896
+ },
38772
41897
  "motionZones.setZone": {
38773
41898
  capName: "motion-zones",
38774
41899
  capScope: "device",
@@ -38829,6 +41954,12 @@ Object.freeze({
38829
41954
  addonId: null,
38830
41955
  access: "view"
38831
41956
  },
41957
+ "nativeObjectDetection.getStatus": {
41958
+ capName: "native-object-detection",
41959
+ capScope: "device",
41960
+ addonId: null,
41961
+ access: "view"
41962
+ },
38832
41963
  "nativeObjectDetection.setEnabled": {
38833
41964
  capName: "native-object-detection",
38834
41965
  capScope: "device",
@@ -38847,6 +41978,12 @@ Object.freeze({
38847
41978
  addonId: null,
38848
41979
  access: "view"
38849
41980
  },
41981
+ "navigation.getStatus": {
41982
+ capName: "navigation",
41983
+ capScope: "device",
41984
+ addonId: null,
41985
+ access: "view"
41986
+ },
38850
41987
  "navigation.goToPoint": {
38851
41988
  capName: "navigation",
38852
41989
  capScope: "device",
@@ -38931,6 +42068,12 @@ Object.freeze({
38931
42068
  addonId: null,
38932
42069
  access: "create"
38933
42070
  },
42071
+ "networkLink.getStatus": {
42072
+ capName: "network-link",
42073
+ capScope: "device",
42074
+ addonId: null,
42075
+ access: "view"
42076
+ },
38934
42077
  "networkQuality.getAllStats": {
38935
42078
  capName: "network-quality",
38936
42079
  capScope: "system",
@@ -39189,18 +42332,36 @@ Object.freeze({
39189
42332
  addonId: null,
39190
42333
  access: "create"
39191
42334
  },
42335
+ "notifier.getStatus": {
42336
+ capName: "notifier",
42337
+ capScope: "device",
42338
+ addonId: null,
42339
+ access: "view"
42340
+ },
39192
42341
  "notifier.send": {
39193
42342
  capName: "notifier",
39194
42343
  capScope: "device",
39195
42344
  addonId: null,
39196
42345
  access: "create"
39197
42346
  },
42347
+ "numericSensor.getStatus": {
42348
+ capName: "numeric-sensor",
42349
+ capScope: "device",
42350
+ addonId: null,
42351
+ access: "view"
42352
+ },
39198
42353
  "oauthIntegration.getDescriptor": {
39199
42354
  capName: "oauth-integration",
39200
42355
  capScope: "system",
39201
42356
  addonId: null,
39202
42357
  access: "view"
39203
42358
  },
42359
+ "osd.getStatus": {
42360
+ capName: "osd",
42361
+ capScope: "device",
42362
+ addonId: null,
42363
+ access: "view"
42364
+ },
39204
42365
  "osd.setOverlay": {
39205
42366
  capName: "osd",
39206
42367
  capScope: "device",
@@ -39273,6 +42434,12 @@ Object.freeze({
39273
42434
  addonId: null,
39274
42435
  access: "create"
39275
42436
  },
42437
+ "petFeeder.getStatus": {
42438
+ capName: "pet-feeder",
42439
+ capScope: "device",
42440
+ addonId: null,
42441
+ access: "view"
42442
+ },
39276
42443
  "petFeeder.markFoodReplenished": {
39277
42444
  capName: "pet-feeder",
39278
42445
  capScope: "device",
@@ -39315,6 +42482,12 @@ Object.freeze({
39315
42482
  addonId: null,
39316
42483
  access: "create"
39317
42484
  },
42485
+ "pipelineAnalytics.applyDeviceSettingsPatch": {
42486
+ capName: "pipeline-analytics",
42487
+ capScope: "device",
42488
+ addonId: null,
42489
+ access: "create"
42490
+ },
39318
42491
  "pipelineAnalytics.cancelRelocateMedia": {
39319
42492
  capName: "pipeline-analytics",
39320
42493
  capScope: "device",
@@ -39381,6 +42554,18 @@ Object.freeze({
39381
42554
  addonId: null,
39382
42555
  access: "view"
39383
42556
  },
42557
+ "pipelineAnalytics.getDeviceLiveContribution": {
42558
+ capName: "pipeline-analytics",
42559
+ capScope: "device",
42560
+ addonId: null,
42561
+ access: "view"
42562
+ },
42563
+ "pipelineAnalytics.getDeviceSettingsContribution": {
42564
+ capName: "pipeline-analytics",
42565
+ capScope: "device",
42566
+ addonId: null,
42567
+ access: "view"
42568
+ },
39384
42569
  "pipelineAnalytics.getEventDensity": {
39385
42570
  capName: "pipeline-analytics",
39386
42571
  capScope: "device",
@@ -39591,6 +42776,12 @@ Object.freeze({
39591
42776
  addonId: null,
39592
42777
  access: "view"
39593
42778
  },
42779
+ "pipelineAnalytics.ownersWithMedia": {
42780
+ capName: "pipeline-analytics",
42781
+ capScope: "device",
42782
+ addonId: null,
42783
+ access: "view"
42784
+ },
39594
42785
  "pipelineAnalytics.pauseForStorageMigration": {
39595
42786
  capName: "pipeline-analytics",
39596
42787
  capScope: "device",
@@ -39945,6 +43136,12 @@ Object.freeze({
39945
43136
  addonId: null,
39946
43137
  access: "view"
39947
43138
  },
43139
+ "pipelineOrchestrator.applyDeviceSettingsPatch": {
43140
+ capName: "pipeline-orchestrator",
43141
+ capScope: "system",
43142
+ addonId: null,
43143
+ access: "create"
43144
+ },
39948
43145
  "pipelineOrchestrator.assignAudio": {
39949
43146
  capName: "pipeline-orchestrator",
39950
43147
  capScope: "system",
@@ -40035,6 +43232,18 @@ Object.freeze({
40035
43232
  addonId: null,
40036
43233
  access: "view"
40037
43234
  },
43235
+ "pipelineOrchestrator.getDeviceLiveContribution": {
43236
+ capName: "pipeline-orchestrator",
43237
+ capScope: "system",
43238
+ addonId: null,
43239
+ access: "view"
43240
+ },
43241
+ "pipelineOrchestrator.getDeviceSettingsContribution": {
43242
+ capName: "pipeline-orchestrator",
43243
+ capScope: "system",
43244
+ addonId: null,
43245
+ access: "view"
43246
+ },
40038
43247
  "pipelineOrchestrator.getGlobalMetrics": {
40039
43248
  capName: "pipeline-orchestrator",
40040
43249
  capScope: "system",
@@ -40443,12 +43652,36 @@ Object.freeze({
40443
43652
  addonId: null,
40444
43653
  access: "view"
40445
43654
  },
43655
+ "powerMeter.getStatus": {
43656
+ capName: "power-meter",
43657
+ capScope: "device",
43658
+ addonId: null,
43659
+ access: "view"
43660
+ },
43661
+ "presence.getStatus": {
43662
+ capName: "presence",
43663
+ capScope: "device",
43664
+ addonId: null,
43665
+ access: "view"
43666
+ },
43667
+ "pressureSensor.getStatus": {
43668
+ capName: "pressure-sensor",
43669
+ capScope: "device",
43670
+ addonId: null,
43671
+ access: "view"
43672
+ },
40446
43673
  "privacyMask.getOptions": {
40447
43674
  capName: "privacy-mask",
40448
43675
  capScope: "device",
40449
43676
  addonId: null,
40450
43677
  access: "view"
40451
43678
  },
43679
+ "privacyMask.getStatus": {
43680
+ capName: "privacy-mask",
43681
+ capScope: "device",
43682
+ addonId: null,
43683
+ access: "view"
43684
+ },
40452
43685
  "privacyMask.setAudioEnabled": {
40453
43686
  capName: "privacy-mask",
40454
43687
  capScope: "device",
@@ -40509,6 +43742,12 @@ Object.freeze({
40509
43742
  addonId: null,
40510
43743
  access: "view"
40511
43744
  },
43745
+ "ptz.getStatus": {
43746
+ capName: "ptz",
43747
+ capScope: "device",
43748
+ addonId: null,
43749
+ access: "view"
43750
+ },
40512
43751
  "ptz.goHome": {
40513
43752
  capName: "ptz",
40514
43753
  capScope: "device",
@@ -40587,6 +43826,12 @@ Object.freeze({
40587
43826
  addonId: null,
40588
43827
  access: "create"
40589
43828
  },
43829
+ "recording.applyDeviceSettingsPatch": {
43830
+ capName: "recording",
43831
+ capScope: "system",
43832
+ addonId: null,
43833
+ access: "create"
43834
+ },
40590
43835
  "recording.cancelRelocateJob": {
40591
43836
  capName: "recording",
40592
43837
  capScope: "system",
@@ -40635,6 +43880,18 @@ Object.freeze({
40635
43880
  addonId: null,
40636
43881
  access: "view"
40637
43882
  },
43883
+ "recording.getDeviceLiveContribution": {
43884
+ capName: "recording",
43885
+ capScope: "system",
43886
+ addonId: null,
43887
+ access: "view"
43888
+ },
43889
+ "recording.getDeviceSettingsContribution": {
43890
+ capName: "recording",
43891
+ capScope: "system",
43892
+ addonId: null,
43893
+ access: "view"
43894
+ },
40638
43895
  "recording.getPlacement": {
40639
43896
  capName: "recording",
40640
43897
  capScope: "system",
@@ -40653,6 +43910,12 @@ Object.freeze({
40653
43910
  addonId: null,
40654
43911
  access: "view"
40655
43912
  },
43913
+ "recording.getStatus": {
43914
+ capName: "recording",
43915
+ capScope: "system",
43916
+ addonId: null,
43917
+ access: "view"
43918
+ },
40656
43919
  "recording.getStorageMigrationMoveStatus": {
40657
43920
  capName: "recording",
40658
43921
  capScope: "system",
@@ -40827,6 +44090,24 @@ Object.freeze({
40827
44090
  addonId: null,
40828
44091
  access: "view"
40829
44092
  },
44093
+ "recordingOnboard.getOptions": {
44094
+ capName: "recording-onboard",
44095
+ capScope: "device",
44096
+ addonId: null,
44097
+ access: "view"
44098
+ },
44099
+ "recordingOnboard.getStatus": {
44100
+ capName: "recording-onboard",
44101
+ capScope: "device",
44102
+ addonId: null,
44103
+ access: "view"
44104
+ },
44105
+ "recordingOnboard.setSettings": {
44106
+ capName: "recording-onboard",
44107
+ capScope: "device",
44108
+ addonId: null,
44109
+ access: "create"
44110
+ },
40830
44111
  "recordingSignal.getStatus": {
40831
44112
  capName: "recording-signal",
40832
44113
  capScope: "device",
@@ -40857,6 +44138,12 @@ Object.freeze({
40857
44138
  addonId: null,
40858
44139
  access: "delete"
40859
44140
  },
44141
+ "sceneMonitor.getStatus": {
44142
+ capName: "scene-monitor",
44143
+ capScope: "device",
44144
+ addonId: null,
44145
+ access: "view"
44146
+ },
40860
44147
  "sceneMonitor.listScenes": {
40861
44148
  capName: "scene-monitor",
40862
44149
  capScope: "device",
@@ -40887,6 +44174,12 @@ Object.freeze({
40887
44174
  addonId: null,
40888
44175
  access: "create"
40889
44176
  },
44177
+ "scriptRunner.getStatus": {
44178
+ capName: "script-runner",
44179
+ capScope: "device",
44180
+ addonId: null,
44181
+ access: "view"
44182
+ },
40890
44183
  "scriptRunner.run": {
40891
44184
  capName: "script-runner",
40892
44185
  capScope: "device",
@@ -41019,6 +44312,12 @@ Object.freeze({
41019
44312
  addonId: null,
41020
44313
  access: "create"
41021
44314
  },
44315
+ "smoke.getStatus": {
44316
+ capName: "smoke",
44317
+ capScope: "device",
44318
+ addonId: null,
44319
+ access: "view"
44320
+ },
41022
44321
  "smtpProvider.getStatus": {
41023
44322
  capName: "smtp-provider",
41024
44323
  capScope: "system",
@@ -41037,12 +44336,30 @@ Object.freeze({
41037
44336
  addonId: null,
41038
44337
  access: "view"
41039
44338
  },
44339
+ "snapshot.applyDeviceSettingsPatch": {
44340
+ capName: "snapshot",
44341
+ capScope: "device",
44342
+ addonId: null,
44343
+ access: "create"
44344
+ },
41040
44345
  "snapshot.getDebugState": {
41041
44346
  capName: "snapshot",
41042
44347
  capScope: "device",
41043
44348
  addonId: null,
41044
44349
  access: "view"
41045
44350
  },
44351
+ "snapshot.getDeviceLiveContribution": {
44352
+ capName: "snapshot",
44353
+ capScope: "device",
44354
+ addonId: null,
44355
+ access: "view"
44356
+ },
44357
+ "snapshot.getDeviceSettingsContribution": {
44358
+ capName: "snapshot",
44359
+ capScope: "device",
44360
+ addonId: null,
44361
+ access: "view"
44362
+ },
41046
44363
  "snapshot.getSnapshot": {
41047
44364
  capName: "snapshot",
41048
44365
  capScope: "device",
@@ -41061,6 +44378,12 @@ Object.freeze({
41061
44378
  addonId: null,
41062
44379
  access: "view"
41063
44380
  },
44381
+ "snapshot.getStatus": {
44382
+ capName: "snapshot",
44383
+ capScope: "device",
44384
+ addonId: null,
44385
+ access: "view"
44386
+ },
41064
44387
  "snapshot.invalidateCache": {
41065
44388
  capName: "snapshot",
41066
44389
  capScope: "device",
@@ -41397,6 +44720,12 @@ Object.freeze({
41397
44720
  addonId: null,
41398
44721
  access: "create"
41399
44722
  },
44723
+ "streamBroker.applyDeviceSettingsPatch": {
44724
+ capName: "stream-broker",
44725
+ capScope: "system",
44726
+ addonId: null,
44727
+ access: "create"
44728
+ },
41400
44729
  "streamBroker.assignProfile": {
41401
44730
  capName: "stream-broker",
41402
44731
  capScope: "system",
@@ -41433,6 +44762,18 @@ Object.freeze({
41433
44762
  addonId: null,
41434
44763
  access: "view"
41435
44764
  },
44765
+ "streamBroker.getDeviceLiveContribution": {
44766
+ capName: "stream-broker",
44767
+ capScope: "system",
44768
+ addonId: null,
44769
+ access: "view"
44770
+ },
44771
+ "streamBroker.getDeviceSettingsContribution": {
44772
+ capName: "stream-broker",
44773
+ capScope: "system",
44774
+ addonId: null,
44775
+ access: "view"
44776
+ },
41436
44777
  "streamBroker.getPreBufferInfo": {
41437
44778
  capName: "stream-broker",
41438
44779
  capScope: "system",
@@ -41631,6 +44972,12 @@ Object.freeze({
41631
44972
  addonId: null,
41632
44973
  access: "view"
41633
44974
  },
44975
+ "streamParams.getStatus": {
44976
+ capName: "stream-params",
44977
+ capScope: "device",
44978
+ addonId: null,
44979
+ access: "view"
44980
+ },
41634
44981
  "streamParams.setProfile": {
41635
44982
  capName: "stream-params",
41636
44983
  capScope: "device",
@@ -41643,6 +44990,12 @@ Object.freeze({
41643
44990
  addonId: null,
41644
44991
  access: "view"
41645
44992
  },
44993
+ "switch.getStatus": {
44994
+ capName: "switch",
44995
+ capScope: "device",
44996
+ addonId: null,
44997
+ access: "view"
44998
+ },
41646
44999
  "switch.setState": {
41647
45000
  capName: "switch",
41648
45001
  capScope: "device",
@@ -41739,6 +45092,18 @@ Object.freeze({
41739
45092
  addonId: null,
41740
45093
  access: "create"
41741
45094
  },
45095
+ "tamper.getStatus": {
45096
+ capName: "tamper",
45097
+ capScope: "device",
45098
+ addonId: null,
45099
+ access: "view"
45100
+ },
45101
+ "temperatureSensor.getStatus": {
45102
+ capName: "temperature-sensor",
45103
+ capScope: "device",
45104
+ addonId: null,
45105
+ access: "view"
45106
+ },
41742
45107
  "terminalSession.adoptLegacyMonitor": {
41743
45108
  capName: "terminal-session",
41744
45109
  capScope: "system",
@@ -41835,6 +45200,12 @@ Object.freeze({
41835
45200
  addonId: null,
41836
45201
  access: "view"
41837
45202
  },
45203
+ "update.getStatus": {
45204
+ capName: "update",
45205
+ capScope: "device",
45206
+ addonId: null,
45207
+ access: "view"
45208
+ },
41838
45209
  "update.installUpdate": {
41839
45210
  capName: "update",
41840
45211
  capScope: "device",
@@ -42057,6 +45428,12 @@ Object.freeze({
42057
45428
  addonId: null,
42058
45429
  access: "create"
42059
45430
  },
45431
+ "vacuumControl.getStatus": {
45432
+ capName: "vacuum-control",
45433
+ capScope: "device",
45434
+ addonId: null,
45435
+ access: "view"
45436
+ },
42060
45437
  "vacuumControl.locate": {
42061
45438
  capName: "vacuum-control",
42062
45439
  capScope: "device",
@@ -42099,6 +45476,12 @@ Object.freeze({
42099
45476
  addonId: null,
42100
45477
  access: "create"
42101
45478
  },
45479
+ "valve.getStatus": {
45480
+ capName: "valve",
45481
+ capScope: "device",
45482
+ addonId: null,
45483
+ access: "view"
45484
+ },
42102
45485
  "valve.open": {
42103
45486
  capName: "valve",
42104
45487
  capScope: "device",
@@ -42171,6 +45554,18 @@ Object.freeze({
42171
45554
  addonId: null,
42172
45555
  access: "create"
42173
45556
  },
45557
+ "vibration.getStatus": {
45558
+ capName: "vibration",
45559
+ capScope: "device",
45560
+ addonId: null,
45561
+ access: "view"
45562
+ },
45563
+ "videoclips.dialClipStream": {
45564
+ capName: "videoclips",
45565
+ capScope: "device",
45566
+ addonId: null,
45567
+ access: "view"
45568
+ },
42174
45569
  "videoclips.getClipPlayback": {
42175
45570
  capName: "videoclips",
42176
45571
  capScope: "device",
@@ -42183,6 +45578,18 @@ Object.freeze({
42183
45578
  addonId: null,
42184
45579
  access: "view"
42185
45580
  },
45581
+ "videoclips.listSources": {
45582
+ capName: "videoclips",
45583
+ capScope: "device",
45584
+ addonId: null,
45585
+ access: "view"
45586
+ },
45587
+ "videoclips.readClipBytes": {
45588
+ capName: "videoclips",
45589
+ capScope: "device",
45590
+ addonId: null,
45591
+ access: "view"
45592
+ },
42186
45593
  "viewerUi.getStaticDir": {
42187
45594
  capName: "viewer-ui",
42188
45595
  capScope: "system",
@@ -42195,6 +45602,12 @@ Object.freeze({
42195
45602
  addonId: null,
42196
45603
  access: "view"
42197
45604
  },
45605
+ "waterHeater.getStatus": {
45606
+ capName: "water-heater",
45607
+ capScope: "device",
45608
+ addonId: null,
45609
+ access: "view"
45610
+ },
42198
45611
  "waterHeater.setAway": {
42199
45612
  capName: "water-heater",
42200
45613
  capScope: "device",
@@ -42213,6 +45626,12 @@ Object.freeze({
42213
45626
  addonId: null,
42214
45627
  access: "create"
42215
45628
  },
45629
+ "weather.getStatus": {
45630
+ capName: "weather",
45631
+ capScope: "device",
45632
+ addonId: null,
45633
+ access: "view"
45634
+ },
42216
45635
  "webrtcSession.addIceCandidate": {
42217
45636
  capName: "webrtc-session",
42218
45637
  capScope: "device",
@@ -42237,6 +45656,12 @@ Object.freeze({
42237
45656
  addonId: null,
42238
45657
  access: "view"
42239
45658
  },
45659
+ "webrtcSession.getSessionDebug": {
45660
+ capName: "webrtc-session",
45661
+ capScope: "device",
45662
+ addonId: null,
45663
+ access: "view"
45664
+ },
42240
45665
  "webrtcSession.getSessionState": {
42241
45666
  capName: "webrtc-session",
42242
45667
  capScope: "device",
@@ -42569,6 +45994,11 @@ Object.freeze({
42569
45994
  form: "single",
42570
45995
  optional: true
42571
45996
  }],
45997
+ "deviceAdminLink.getAdminLink": [{
45998
+ name: "deviceId",
45999
+ form: "single",
46000
+ optional: false
46001
+ }],
42572
46002
  "deviceAdoption.release": [{
42573
46003
  name: "camDeviceId",
42574
46004
  form: "single",
@@ -43479,6 +46909,11 @@ Object.freeze({
43479
46909
  form: "single",
43480
46910
  optional: false
43481
46911
  }],
46912
+ "pipelineAnalytics.ownersWithMedia": [{
46913
+ name: "deviceId",
46914
+ form: "single",
46915
+ optional: false
46916
+ }],
43482
46917
  "pipelineAnalytics.proposeRetrainAnnotations": [{
43483
46918
  name: "deviceId",
43484
46919
  form: "single",
@@ -43949,6 +47384,16 @@ Object.freeze({
43949
47384
  form: "single",
43950
47385
  optional: true
43951
47386
  }],
47387
+ "recordingOnboard.getOptions": [{
47388
+ name: "deviceId",
47389
+ form: "single",
47390
+ optional: false
47391
+ }],
47392
+ "recordingOnboard.setSettings": [{
47393
+ name: "deviceId",
47394
+ form: "single",
47395
+ optional: false
47396
+ }],
43952
47397
  "recordingSignal.getStatus": [{
43953
47398
  name: "deviceId",
43954
47399
  form: "single",
@@ -44175,6 +47620,11 @@ Object.freeze({
44175
47620
  form: "single",
44176
47621
  optional: false
44177
47622
  }],
47623
+ "videoclips.dialClipStream": [{
47624
+ name: "deviceId",
47625
+ form: "single",
47626
+ optional: false
47627
+ }],
44178
47628
  "videoclips.getClipPlayback": [{
44179
47629
  name: "deviceId",
44180
47630
  form: "single",
@@ -44185,6 +47635,16 @@ Object.freeze({
44185
47635
  form: "single",
44186
47636
  optional: false
44187
47637
  }],
47638
+ "videoclips.listSources": [{
47639
+ name: "deviceId",
47640
+ form: "single",
47641
+ optional: false
47642
+ }],
47643
+ "videoclips.readClipBytes": [{
47644
+ name: "deviceId",
47645
+ form: "single",
47646
+ optional: false
47647
+ }],
44188
47648
  "waterHeater.setAway": [{
44189
47649
  name: "deviceId",
44190
47650
  form: "single",
@@ -44220,6 +47680,11 @@ Object.freeze({
44220
47680
  form: "single",
44221
47681
  optional: false
44222
47682
  }],
47683
+ "webrtcSession.getSessionDebug": [{
47684
+ name: "deviceId",
47685
+ form: "single",
47686
+ optional: false
47687
+ }],
44223
47688
  "webrtcSession.getSessionState": [{
44224
47689
  name: "deviceId",
44225
47690
  form: "single",
@@ -45341,11 +48806,50 @@ var VeluxGatewayDevice = class extends BaseDevice {
45341
48806
  super(ctx, veluxGatewaySchema, { type: DeviceType.Hub });
45342
48807
  this.online = false;
45343
48808
  this.registerDeviceDiscovery();
48809
+ this.registerAdminLinkCap();
45344
48810
  this.updateSourceInfo({
45345
48811
  id: this.stableId,
45346
48812
  system: "velux"
45347
48813
  });
45348
48814
  }
48815
+ /**
48816
+ * device-admin-link — the hub's own management page.
48817
+ *
48818
+ * The KLF-200 serves its web interface over HTTPS only, with a self-signed
48819
+ * certificate — the browser will warn, which is the unit's own behaviour and
48820
+ * not something to paper over. The password printed on the back of the unit
48821
+ * is in the same connection object and is NOT placed in the URL; the page
48822
+ * asks for it.
48823
+ *
48824
+ * Only the hub gets the cap. Its children are radio actuators with no web
48825
+ * server anywhere, and the address they would borrow lives on the hub, which
48826
+ * is where the operator edits it.
48827
+ */
48828
+ registerAdminLinkCap() {
48829
+ this.ctx.registerNativeCap(deviceAdminLinkCapability, { getAdminLink: async ({ deviceId }) => {
48830
+ if (deviceId !== this.id) throw new Error(`VeluxGatewayDevice: deviceId mismatch, expected ${this.id}, got ${deviceId}`);
48831
+ const connection = this.config.values.connection;
48832
+ const built = buildDeviceAdminUrl({
48833
+ host: connection.host,
48834
+ port: null,
48835
+ scheme: "https",
48836
+ path: "/"
48837
+ });
48838
+ if (!built.ok) {
48839
+ this.ctx.logger.debug("velux admin link unavailable", {
48840
+ tags: { deviceId: this.id },
48841
+ meta: { reason: built.reason }
48842
+ });
48843
+ return null;
48844
+ }
48845
+ return {
48846
+ url: built.url,
48847
+ label: "KLF-200 web interface",
48848
+ target: "integration",
48849
+ host: connection.host
48850
+ };
48851
+ } });
48852
+ }
45349
48853
  /** Adopt a pre-built manager (created by `onCreateDevice` so the live client
45350
48854
  * connects once). Published on the resolver so children pick it up. */
45351
48855
  adoptManager(manager) {