@camstack/types 0.1.35 → 0.1.37

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 (95) hide show
  1. package/dist/capabilities/addon-widgets-source.cap.d.ts +73 -5
  2. package/dist/capabilities/addon-widgets-source.cap.d.ts.map +1 -1
  3. package/dist/capabilities/addon-widgets.cap.d.ts +22 -4
  4. package/dist/capabilities/addon-widgets.cap.d.ts.map +1 -1
  5. package/dist/capabilities/audio-analysis.cap.d.ts +7 -4
  6. package/dist/capabilities/audio-analysis.cap.d.ts.map +1 -1
  7. package/dist/capabilities/camera-streams.cap.d.ts +7 -5
  8. package/dist/capabilities/camera-streams.cap.d.ts.map +1 -1
  9. package/dist/capabilities/capability-definition.d.ts +114 -0
  10. package/dist/capabilities/capability-definition.d.ts.map +1 -1
  11. package/dist/capabilities/decoder.cap.d.ts +90 -0
  12. package/dist/capabilities/decoder.cap.d.ts.map +1 -1
  13. package/dist/capabilities/detection-pipeline.cap.d.ts +6 -4
  14. package/dist/capabilities/detection-pipeline.cap.d.ts.map +1 -1
  15. package/dist/capabilities/device-manager.cap.d.ts +3 -3
  16. package/dist/capabilities/device-ops.cap.d.ts +1 -1
  17. package/dist/capabilities/index.d.ts +18 -11
  18. package/dist/capabilities/index.d.ts.map +1 -1
  19. package/dist/capabilities/motion-detection.cap.d.ts +2 -0
  20. package/dist/capabilities/motion-detection.cap.d.ts.map +1 -1
  21. package/dist/capabilities/motion-zones.cap.d.ts +83 -0
  22. package/dist/capabilities/motion-zones.cap.d.ts.map +1 -0
  23. package/dist/capabilities/nodes.cap.d.ts +9 -0
  24. package/dist/capabilities/nodes.cap.d.ts.map +1 -1
  25. package/dist/capabilities/oauth-integration.cap.d.ts +103 -0
  26. package/dist/capabilities/oauth-integration.cap.d.ts.map +1 -0
  27. package/dist/capabilities/pipeline-analytics.cap.d.ts +2 -0
  28. package/dist/capabilities/pipeline-analytics.cap.d.ts.map +1 -1
  29. package/dist/capabilities/ptz-autotrack.cap.d.ts +10 -0
  30. package/dist/capabilities/ptz-autotrack.cap.d.ts.map +1 -1
  31. package/dist/capabilities/ptz.cap.d.ts +57 -1
  32. package/dist/capabilities/ptz.cap.d.ts.map +1 -1
  33. package/dist/capabilities/schemas/streaming-shared.d.ts +110 -3
  34. package/dist/capabilities/schemas/streaming-shared.d.ts.map +1 -1
  35. package/dist/capabilities/snapshot.cap.d.ts +2 -0
  36. package/dist/capabilities/snapshot.cap.d.ts.map +1 -1
  37. package/dist/capabilities/sso-bridge.cap.d.ts +120 -0
  38. package/dist/capabilities/sso-bridge.cap.d.ts.map +1 -1
  39. package/dist/capabilities/stream-broker.cap.d.ts +97 -4
  40. package/dist/capabilities/stream-broker.cap.d.ts.map +1 -1
  41. package/dist/capabilities/stream-params-config-schema.d.ts +56 -0
  42. package/dist/capabilities/stream-params-config-schema.d.ts.map +1 -0
  43. package/dist/capabilities/stream-params.cap.d.ts +482 -0
  44. package/dist/capabilities/stream-params.cap.d.ts.map +1 -0
  45. package/dist/capabilities/user-management.cap.d.ts +198 -1
  46. package/dist/capabilities/user-management.cap.d.ts.map +1 -1
  47. package/dist/capabilities/webrtc-session.cap.d.ts +2 -0
  48. package/dist/capabilities/webrtc-session.cap.d.ts.map +1 -1
  49. package/dist/generated/addon-api.d.ts +1175 -51
  50. package/dist/generated/addon-api.d.ts.map +1 -1
  51. package/dist/generated/cap-status-types.d.ts +7 -3
  52. package/dist/generated/cap-status-types.d.ts.map +1 -1
  53. package/dist/generated/capability-router-map.d.ts +13 -4
  54. package/dist/generated/capability-router-map.d.ts.map +1 -1
  55. package/dist/generated/device-local-state.d.ts +6 -0
  56. package/dist/generated/device-local-state.d.ts.map +1 -1
  57. package/dist/generated/device-proxy.d.ts +6 -0
  58. package/dist/generated/device-proxy.d.ts.map +1 -1
  59. package/dist/generated/method-access-map.d.ts +1 -1
  60. package/dist/generated/method-access-map.d.ts.map +1 -1
  61. package/dist/generated/system-proxy.d.ts +4 -4
  62. package/dist/generated/system-proxy.d.ts.map +1 -1
  63. package/dist/{index-BkSgJYP7.js → index-BblD92Si.js} +600 -98
  64. package/dist/index-BblD92Si.js.map +1 -0
  65. package/dist/{index-CWhQOnm9.mjs → index-CgPd35k5.mjs} +949 -447
  66. package/dist/index-CgPd35k5.mjs.map +1 -0
  67. package/dist/index.d.ts +2 -1
  68. package/dist/index.d.ts.map +1 -1
  69. package/dist/index.js +313 -7
  70. package/dist/index.js.map +1 -1
  71. package/dist/index.mjs +587 -281
  72. package/dist/index.mjs.map +1 -1
  73. package/dist/interfaces/addon.d.ts +123 -29
  74. package/dist/interfaces/addon.d.ts.map +1 -1
  75. package/dist/interfaces/capability.d.ts +6 -23
  76. package/dist/interfaces/capability.d.ts.map +1 -1
  77. package/dist/interfaces/config-ui.d.ts +4 -101
  78. package/dist/interfaces/config-ui.d.ts.map +1 -1
  79. package/dist/interfaces/decoder.d.ts +12 -0
  80. package/dist/interfaces/decoder.d.ts.map +1 -1
  81. package/dist/interfaces/device-provider.d.ts +0 -4
  82. package/dist/interfaces/device-provider.d.ts.map +1 -1
  83. package/dist/interfaces/event-bus.d.ts +15 -0
  84. package/dist/interfaces/event-bus.d.ts.map +1 -1
  85. package/dist/interfaces/frame-handle.d.ts +40 -0
  86. package/dist/interfaces/frame-handle.d.ts.map +1 -0
  87. package/dist/interfaces/kernel-abstractions.d.ts +6 -0
  88. package/dist/interfaces/kernel-abstractions.d.ts.map +1 -1
  89. package/dist/interfaces/stream-broker.d.ts +40 -21
  90. package/dist/interfaces/stream-broker.d.ts.map +1 -1
  91. package/dist/node.js +1 -1
  92. package/dist/node.mjs +1 -1
  93. package/package.json +1 -1
  94. package/dist/index-BkSgJYP7.js.map +0 -1
  95. package/dist/index-CWhQOnm9.mjs.map +0 -1
@@ -12,6 +12,7 @@ const WELL_KNOWN_TABS = [
12
12
  { id: "osd", label: "OSD", icon: "type", order: 18 },
13
13
  { id: "stream-broker", label: "Stream Broker", icon: "radio", order: 20 },
14
14
  { id: "streaming", label: "Streaming", icon: "video", order: 35 },
15
+ { id: "ptz", label: "PTZ", icon: "move", order: 40 },
15
16
  { id: "pipeline", label: "Detection Pipeline", icon: "cpu", order: 39 },
16
17
  { id: "zones", label: "Detection", icon: "shapes", order: 38 },
17
18
  { id: "live-stats", label: "Live Stats", icon: "activity", order: 39 },
@@ -79,6 +80,9 @@ function hydrateField(field, values) {
79
80
  return { ...field, value: items };
80
81
  }
81
82
  const rawValue = storedValue !== void 0 ? storedValue : defaultValue !== void 0 ? defaultValue : null;
83
+ if (field.type === "password") {
84
+ return { ...field, value: "" };
85
+ }
82
86
  const value = field.type === "textarea" && field.isJson && rawValue !== null && typeof rawValue === "object" ? JSON.stringify(rawValue, null, 2) : rawValue;
83
87
  const hydrated = { ...field, value };
84
88
  return hydrated;
@@ -181,7 +185,19 @@ const DecoderSessionConfigSchema = z.object({
181
185
  * on every line so `grep tag=broker:5/high` filters one camera
182
186
  * profile cleanly.
183
187
  */
184
- tag: z.string().optional()
188
+ tag: z.string().optional(),
189
+ /**
190
+ * Where the session delivers decoded frames (Phase 5 / D9):
191
+ *
192
+ * - `'callback'` (default) — the legacy pixel path: decoded frames are
193
+ * buffered as `DecodedFrame`s and drained via `pullFrames`.
194
+ * - `'shm'` — the shared-memory frame plane: decoded frames are written
195
+ * into an OS shared-memory ring and drained as zero-pixel
196
+ * `FrameHandle`s via `pullHandles`. A session is one mode or the
197
+ * other — `pullFrames` returns nothing for an `'shm'` session and
198
+ * `pullHandles` returns nothing for a `'callback'` session.
199
+ */
200
+ frameSink: z.enum(["callback", "shm"]).default("callback")
185
201
  });
186
202
  function errMsg(err) {
187
203
  if (err instanceof Error) return err.message;
@@ -767,6 +783,9 @@ function method(input, output, options) {
767
783
  function event(data) {
768
784
  return { data };
769
785
  }
786
+ function isDeviceConfigCap(def) {
787
+ return def?.deviceConfig !== void 0;
788
+ }
770
789
  const AudioClassSummarySchema = z.object({
771
790
  className: z.string(),
772
791
  /** Number of windows (chunks) where this class was the top hit. */
@@ -1069,6 +1088,53 @@ const DecodedFrameSchema = z.object({
1069
1088
  format: z.enum(["jpeg", "rgb", "bgr", "yuv420", "gray"]),
1070
1089
  timestamp: z.number()
1071
1090
  });
1091
+ const FrameHandleSchema = z.object({
1092
+ shmId: z.string(),
1093
+ slot: z.number().int().nonnegative(),
1094
+ seq: z.number().int().nonnegative(),
1095
+ width: z.number().int().positive(),
1096
+ height: z.number().int().positive(),
1097
+ format: z.enum(["jpeg", "rgb", "bgr", "yuv420", "gray"]),
1098
+ pts: z.number(),
1099
+ byteLength: z.number().int().nonnegative(),
1100
+ nodeId: z.string(),
1101
+ slotCount: z.number().int().positive()
1102
+ });
1103
+ const FrameHandleFormatSchema = z.enum(["rgb", "bgr", "yuv420", "gray"]);
1104
+ const SubscribeFramesInputSchema = z.object({
1105
+ brokerId: z.string(),
1106
+ format: FrameHandleFormatSchema,
1107
+ /**
1108
+ * Optional reader-side cadence hint in frames per second. The broker does
1109
+ * NOT throttle — latest-wins ring reads drop frames implicitly for a slow
1110
+ * consumer. The value is echoed back in `SubscribeFramesResult.maxFps` so
1111
+ * the consumer can pace its own `pullFrameHandles` polling.
1112
+ */
1113
+ maxFps: z.number().positive().optional(),
1114
+ /** Short caller-identity tag (`motion`, `detection`, …) for diagnostics. */
1115
+ tag: z.string().optional()
1116
+ });
1117
+ const SubscribeFramesResultSchema = z.object({
1118
+ /** Opaque id the consumer passes to `pullFrameHandles` / `unsubscribeFrames`. */
1119
+ subscriptionId: z.string(),
1120
+ /** Reader-side cadence hint (frames/s) — echoes `SubscribeFramesInput.maxFps`. */
1121
+ maxFps: z.number().nonnegative()
1122
+ });
1123
+ const DecodedAudioChunkSchema = z.object({
1124
+ data: z.instanceof(Uint8Array),
1125
+ sampleRate: z.number().int().positive(),
1126
+ channels: z.number().int().positive(),
1127
+ timestamp: z.number()
1128
+ });
1129
+ const SubscribeAudioChunksInputSchema = z.object({
1130
+ brokerId: z.string(),
1131
+ /** Short caller-identity tag (`audio-analyzer`, …) for `listClients`. */
1132
+ tag: z.string().optional()
1133
+ });
1134
+ const SubscribeAudioChunksResultSchema = z.object({
1135
+ /** Opaque id passed to `pullAudioChunks` / `unsubscribeAudioChunks`. */
1136
+ subscriptionId: z.string()
1137
+ });
1072
1138
  const BrokerStatusSchema$1 = z.enum(["idle", "connecting", "streaming", "error", "stopped"]);
1073
1139
  const BrokerStatsSchema = z.object({
1074
1140
  status: BrokerStatusSchema$1,
@@ -1298,9 +1364,76 @@ const streamBrokerCapability = {
1298
1364
  z.object({ released: z.boolean(), refcount: z.number().int().nonnegative() }),
1299
1365
  { kind: "mutation", auth: "admin" }
1300
1366
  ),
1301
- getBroker: method(
1302
- z.object({ brokerId: z.string() }),
1303
- z.custom()
1367
+ /**
1368
+ * ── Decoded audio-chunk plane (Phase 5 / D9) ──────────────────────
1369
+ *
1370
+ * The serialisable replacement for the live-object `IStreamBroker.
1371
+ * onDecodedAudioChunk` callback path. Unlike the video frame plane,
1372
+ * audio chunks are tiny (a ~500ms PCM window is a few KB) so they ship
1373
+ * their bytes INLINE over tRPC — no shared-memory ring. A consumer:
1374
+ *
1375
+ * 1. `subscribeAudioChunks({ brokerId, tag })` — the broker registers
1376
+ * a per-subscription bounded FIFO queue and returns a
1377
+ * `subscriptionId`.
1378
+ * 2. polls `pullAudioChunks({ subscriptionId, maxCount })` — drains
1379
+ * `DecodedAudioChunk[]` in arrival order (FIFO, no latest-wins
1380
+ * drop: an audio gap is audible / breaks an analysis window). The
1381
+ * queue is generously sized; it only drops its oldest chunk if a
1382
+ * truly stalled consumer lets it overflow.
1383
+ * 3. `unsubscribeAudioChunks({ subscriptionId })` on teardown.
1384
+ */
1385
+ subscribeAudioChunks: method(
1386
+ SubscribeAudioChunksInputSchema,
1387
+ SubscribeAudioChunksResultSchema,
1388
+ { kind: "mutation" }
1389
+ ),
1390
+ pullAudioChunks: method(
1391
+ z.object({
1392
+ subscriptionId: z.string(),
1393
+ maxCount: z.number().int().positive().default(8)
1394
+ }),
1395
+ z.array(DecodedAudioChunkSchema).readonly()
1396
+ ),
1397
+ unsubscribeAudioChunks: method(
1398
+ z.object({ subscriptionId: z.string() }),
1399
+ z.object({ released: z.boolean() }),
1400
+ { kind: "mutation" }
1401
+ ),
1402
+ /**
1403
+ * ── Shared-memory frame plane (Phase 5 / D9) ──────────────────────
1404
+ *
1405
+ * The handle-based replacement for the live-object `IStreamBroker.
1406
+ * onDecodedFrame` callback path. A consumer:
1407
+ *
1408
+ * 1. `subscribeFrames({ brokerId, format })` — the broker spins up
1409
+ * (or reuses) a `frameSink: 'shm'` decoder session producing that
1410
+ * `format` and returns a `subscriptionId`.
1411
+ * 2. polls `pullFrameHandles({ subscriptionId, maxCount })` — drains
1412
+ * zero-pixel `FrameHandle[]`; each handle is fed to a
1413
+ * `FrameRingReader` that opens the named shm segment and reads the
1414
+ * pixels back zero-copy.
1415
+ * 3. `unsubscribeFrames({ subscriptionId })` on teardown.
1416
+ *
1417
+ * The broker keeps one shm ring per `(brokerId, format)` actually
1418
+ * requested — no broker-side `sharp` conversion. fps throttling is
1419
+ * implicit (latest-wins ring reads drop frames for a slow consumer).
1420
+ */
1421
+ subscribeFrames: method(
1422
+ SubscribeFramesInputSchema,
1423
+ SubscribeFramesResultSchema,
1424
+ { kind: "mutation" }
1425
+ ),
1426
+ pullFrameHandles: method(
1427
+ z.object({
1428
+ subscriptionId: z.string(),
1429
+ maxCount: z.number().int().positive().default(4)
1430
+ }),
1431
+ z.array(FrameHandleSchema).readonly()
1432
+ ),
1433
+ unsubscribeFrames: method(
1434
+ z.object({ subscriptionId: z.string() }),
1435
+ z.object({ released: z.boolean() }),
1436
+ { kind: "mutation" }
1304
1437
  ),
1305
1438
  setPreBufferDuration: method(
1306
1439
  z.object({ brokerId: z.string(), seconds: z.number().min(0).max(30) }),
@@ -1356,6 +1489,8 @@ const cameraStreamsCapability = {
1356
1489
  name: "camera-streams",
1357
1490
  scope: "device",
1358
1491
  mode: "singleton",
1492
+ kind: "wrapper",
1493
+ defaultActive: true,
1359
1494
  deviceTypes: [DeviceType.Camera],
1360
1495
  methods: {
1361
1496
  getCameraStreams: method(
@@ -1651,6 +1786,8 @@ const motionDetectionCapability = {
1651
1786
  name: "motion-detection",
1652
1787
  scope: "device",
1653
1788
  mode: "singleton",
1789
+ kind: "wrapper",
1790
+ defaultActive: true,
1654
1791
  exposesDeviceSettings: true,
1655
1792
  methods: {
1656
1793
  analyze: method(
@@ -2522,6 +2659,42 @@ const motionTriggerCapability = {
2522
2659
  },
2523
2660
  runtimeState: MotionTriggerRuntimeStateSchema
2524
2661
  };
2662
+ const MotionZoneStatusSchema = z.object({
2663
+ enabled: z.boolean(),
2664
+ sensitivity: z.number(),
2665
+ /** Row-major active-cell grid. Length = gridWidth*gridHeight (see getOptions). */
2666
+ cells: z.array(z.boolean()),
2667
+ lastFetchedAt: z.number()
2668
+ });
2669
+ const MotionZoneOptionsSchema = z.object({
2670
+ gridWidth: z.number(),
2671
+ gridHeight: z.number(),
2672
+ sensitivity: z.object({ min: z.number(), max: z.number(), step: z.number() })
2673
+ });
2674
+ const MotionZonePatchSchema = z.object({
2675
+ enabled: z.boolean().optional(),
2676
+ sensitivity: z.number().optional(),
2677
+ cells: z.array(z.boolean()).optional()
2678
+ });
2679
+ const motionZonesCapability = {
2680
+ name: "motion-zones",
2681
+ scope: "device",
2682
+ mode: "singleton",
2683
+ deviceTypes: [DeviceType.Camera],
2684
+ deviceConfig: {
2685
+ ui: { kind: "widget", widgetId: "host/motion-zones-grid", tab: "motion", label: "Motion Zones" }
2686
+ },
2687
+ methods: {
2688
+ getOptions: method(z.object({ deviceId: z.number() }), MotionZoneOptionsSchema),
2689
+ setZone: method(
2690
+ z.object({ deviceId: z.number(), patch: MotionZonePatchSchema }),
2691
+ z.void(),
2692
+ { kind: "mutation", auth: "admin" }
2693
+ )
2694
+ },
2695
+ status: { schema: MotionZoneStatusSchema, kind: "poll" },
2696
+ runtimeState: MotionZoneStatusSchema
2697
+ };
2525
2698
  const AutotrackTargetTypeSchema = z.string().describe("Vendor target string (people/vehicle/pet); empty = camera default");
2526
2699
  const PtzAutotrackSettingsSchema = z.object({
2527
2700
  targetType: AutotrackTargetTypeSchema,
@@ -2560,6 +2733,9 @@ const ptzAutotrackCapability = {
2560
2733
  scope: "device",
2561
2734
  mode: "singleton",
2562
2735
  deviceTypes: [DeviceType.Camera],
2736
+ deviceConfig: {
2737
+ ui: { kind: "widget", widgetId: "host/ptz-autotrack", tab: "ptz", topTab: true, label: "Auto-Tracking", order: 5 }
2738
+ },
2563
2739
  methods: {
2564
2740
  /**
2565
2741
  * Read the current on/off state + last-applied settings.
@@ -2626,6 +2802,111 @@ const ptzAutotrackCapability = {
2626
2802
  */
2627
2803
  runtimeState: PtzAutotrackRuntimeStateSchema
2628
2804
  };
2805
+ const StreamProfileSchema = z.enum(["main", "sub", "ext"]);
2806
+ const StreamProfileConfigSchema = z.object({
2807
+ width: z.number(),
2808
+ height: z.number(),
2809
+ codec: z.enum(["h264", "h265"]),
2810
+ framerate: z.number(),
2811
+ bitrate: z.number(),
2812
+ // kbps
2813
+ bitrateMode: z.enum(["vbr", "cbr"]).optional(),
2814
+ encoderProfile: z.enum(["high", "main", "baseline"]).optional(),
2815
+ gop: z.number().optional(),
2816
+ audio: z.boolean().optional()
2817
+ });
2818
+ const StreamParamsStatusSchema = z.object({
2819
+ /** Per-profile current config. A profile absent = the camera doesn't have it. */
2820
+ main: StreamProfileConfigSchema.optional(),
2821
+ sub: StreamProfileConfigSchema.optional(),
2822
+ ext: StreamProfileConfigSchema.optional(),
2823
+ lastFetchedAt: z.number()
2824
+ });
2825
+ const StreamProfileOptionsSchema = z.object({
2826
+ resolutions: z.array(z.object({ width: z.number(), height: z.number() })),
2827
+ codecs: z.array(z.enum(["h264", "h265"])),
2828
+ framerates: z.array(z.number()),
2829
+ /** Allowed bitrate values (kbps). Empty if the camera takes a free range. */
2830
+ bitrates: z.array(z.number()),
2831
+ /** Optional [min,max] kbps when the camera accepts a continuous range. */
2832
+ bitrateRange: z.tuple([z.number(), z.number()]).optional(),
2833
+ supportsBitrateMode: z.boolean(),
2834
+ supportsEncoderProfile: z.boolean(),
2835
+ supportsGop: z.boolean(),
2836
+ /** Allowed GOP / keyframe-interval range, in seconds — drives the
2837
+ * I-frame-interval selector. Absent when the camera advertises GOP
2838
+ * support but no concrete range (callers then fall back to a free
2839
+ * numeric input). `{ min, max, step }` per the getOptions convention. */
2840
+ gop: z.object({ min: z.number(), max: z.number(), step: z.number() }).optional()
2841
+ });
2842
+ const StreamParamsOptionsSchema = z.object({
2843
+ main: StreamProfileOptionsSchema.optional(),
2844
+ sub: StreamProfileOptionsSchema.optional(),
2845
+ ext: StreamProfileOptionsSchema.optional()
2846
+ });
2847
+ const StreamProfilePatchSchema = z.object({
2848
+ width: z.number().optional(),
2849
+ height: z.number().optional(),
2850
+ codec: z.enum(["h264", "h265"]).optional(),
2851
+ framerate: z.number().optional(),
2852
+ bitrate: z.number().optional(),
2853
+ bitrateMode: z.enum(["vbr", "cbr"]).optional(),
2854
+ encoderProfile: z.enum(["high", "main", "baseline"]).optional(),
2855
+ gop: z.number().optional(),
2856
+ audio: z.boolean().optional()
2857
+ });
2858
+ const streamParamsCapability = {
2859
+ name: "stream-params",
2860
+ scope: "device",
2861
+ mode: "singleton",
2862
+ deviceTypes: [DeviceType.Camera],
2863
+ deviceConfig: {
2864
+ ui: { kind: "derived-form", builderId: "stream-params", tab: "streaming" }
2865
+ },
2866
+ methods: {
2867
+ getOptions: method(
2868
+ z.object({ deviceId: z.number() }),
2869
+ StreamParamsOptionsSchema
2870
+ ),
2871
+ setProfile: method(
2872
+ z.object({
2873
+ deviceId: z.number(),
2874
+ profile: StreamProfileSchema,
2875
+ patch: StreamProfilePatchSchema
2876
+ }),
2877
+ z.void(),
2878
+ { kind: "mutation", auth: "admin" }
2879
+ ),
2880
+ /**
2881
+ * Build the `ConfigUISchema` (admin-ui `ConfigFormBuilder` input
2882
+ * shape) for this camera's stream-encoder settings — one section per
2883
+ * profile (main / sub / ext) with the resolution / codec / framerate
2884
+ * / bitrate / bitrate-mode / encoder-profile / GOP controls the
2885
+ * firmware actually exposes.
2886
+ *
2887
+ * Driven by `getOptions` (camera-probed availability) + `getStatus`
2888
+ * (current per-profile config); each field's `default` is seeded
2889
+ * from the live config so the form renders the camera state in one
2890
+ * pass. Returns `null` when the camera exposes no configurable
2891
+ * stream property — the renderer then shows the unsupported message.
2892
+ *
2893
+ * Output is `z.unknown().nullable()` — the same convention every
2894
+ * other `ConfigUISchema`-returning cap method uses (`device-ops`,
2895
+ * `device-manager`); `ConfigUISchema` is a TS-only type with no
2896
+ * companion Zod schema, and a concrete object would collapse
2897
+ * unrelated AppRouter branches to `unknown` during codegen.
2898
+ */
2899
+ getConfigSchema: method(
2900
+ z.object({ deviceId: z.number() }),
2901
+ z.unknown().nullable()
2902
+ )
2903
+ },
2904
+ status: {
2905
+ schema: StreamParamsStatusSchema,
2906
+ kind: "poll"
2907
+ },
2908
+ runtimeState: StreamParamsStatusSchema
2909
+ };
2629
2910
  const SwitchStatusSchema = z.object({
2630
2911
  on: z.boolean(),
2631
2912
  /** Ms epoch of the last state change. Useful for UI "X minutes ago". */
@@ -3630,6 +3911,83 @@ const adminUiCapability = {
3630
3911
  getVersion: method(z.void(), VersionOutputSchema)
3631
3912
  }
3632
3913
  };
3914
+ const MethodAccessSchema = z.enum(["view", "create", "delete"]);
3915
+ const AllowedProviderSchema = z.union([z.literal("*"), z.array(z.string())]);
3916
+ const AllowedDevicesSchema = z.record(z.string(), z.union([z.literal("*"), z.array(z.string())]));
3917
+ const CapScopeSchema = z.enum(["device", "system"]);
3918
+ const TokenScopeSchema = z.discriminatedUnion("type", [
3919
+ z.object({
3920
+ type: z.literal("category"),
3921
+ target: CapScopeSchema,
3922
+ access: z.array(MethodAccessSchema).min(1)
3923
+ }),
3924
+ z.object({
3925
+ type: z.literal("capability"),
3926
+ target: z.string(),
3927
+ access: z.array(MethodAccessSchema).min(1)
3928
+ }),
3929
+ z.object({
3930
+ type: z.literal("addon"),
3931
+ target: z.string(),
3932
+ access: z.array(MethodAccessSchema).min(1)
3933
+ }),
3934
+ z.object({
3935
+ type: z.literal("device"),
3936
+ /**
3937
+ * One or more deviceIds (serialised as strings for wire-format
3938
+ * consistency with the rest of the union). Matcher accepts if
3939
+ * `input.deviceId` ∈ `targets`. Array shape avoids the row-explosion
3940
+ * of one scope-per-device when granting access to a set of cameras.
3941
+ */
3942
+ targets: z.array(z.string()).min(1),
3943
+ access: z.array(MethodAccessSchema).min(1)
3944
+ })
3945
+ ]);
3946
+ const UserRecordSchema = z.object({
3947
+ id: z.string(),
3948
+ username: z.string(),
3949
+ passwordHash: z.string(),
3950
+ /**
3951
+ * Admin bypass. When true, the middleware skips the scope-access
3952
+ * check entirely. There is no other axis of privilege; the legacy
3953
+ * role enum collapsed onto this boolean in v2.
3954
+ */
3955
+ isAdmin: z.boolean().default(false),
3956
+ allowedProviders: AllowedProviderSchema,
3957
+ allowedDevices: AllowedDevicesSchema,
3958
+ /**
3959
+ * Scopes granted to this user. Admins bypass; their `scopes` is
3960
+ * ignored. Non-admins without scopes are locked out of every
3961
+ * protected call.
3962
+ */
3963
+ scopes: z.array(TokenScopeSchema).default([]),
3964
+ createdAt: z.number(),
3965
+ updatedAt: z.number()
3966
+ });
3967
+ const ApiKeyRecordSchema = z.object({
3968
+ id: z.string(),
3969
+ label: z.string(),
3970
+ isAdmin: z.boolean().default(false),
3971
+ allowedProviders: AllowedProviderSchema,
3972
+ allowedDevices: AllowedDevicesSchema,
3973
+ tokenHash: z.string(),
3974
+ tokenPrefix: z.string(),
3975
+ createdAt: z.number(),
3976
+ lastUsedAt: z.number().optional()
3977
+ });
3978
+ const ScopedTokenSchema = z.object({
3979
+ id: z.string(),
3980
+ userId: z.string(),
3981
+ name: z.string(),
3982
+ tokenHash: z.string(),
3983
+ tokenPrefix: z.string(),
3984
+ scopes: z.array(TokenScopeSchema),
3985
+ // SQLite/JSON storage round-trips undefined → null. Use `nullish` so the
3986
+ // schema accepts both `null` (read from disk) and `undefined` (in-memory).
3987
+ expiresAt: z.number().nullish(),
3988
+ lastUsedAt: z.number().nullish(),
3989
+ createdAt: z.number()
3990
+ });
3633
3991
  const SsoBridgeClaimsSchema = z.object({
3634
3992
  userId: z.string(),
3635
3993
  username: z.string(),
@@ -3645,7 +4003,18 @@ const SsoBridgeClaimsSchema = z.object({
3645
4003
  * JWT WITHOUT verifying the signature — the hub re-verifies on every
3646
4004
  * inbound call so trust still rests with the signing hub.
3647
4005
  */
3648
- hubUrl: z.string().optional()
4006
+ hubUrl: z.string().optional(),
4007
+ /** Permission scopes baked into the token. Set by the OAuth
4008
+ * account-linking grant; absent on ordinary SSO-login tokens. */
4009
+ scopes: z.array(TokenScopeSchema).optional(),
4010
+ /** OAuth authorization-code binding — set only on `oauth-code` tokens. */
4011
+ redirectUri: z.string().optional(),
4012
+ integrationId: z.string().optional(),
4013
+ /** JWT ID — unique per issued code; consumed-set enforces single-use. */
4014
+ jti: z.string().optional(),
4015
+ /** OAuth session registry id — set on `oauth-access`/`oauth-refresh`
4016
+ * tokens so the verify path can check the session is not revoked. */
4017
+ sessionId: z.string().optional()
3649
4018
  });
3650
4019
  const ssoBridgeCapability = {
3651
4020
  name: "sso-bridge",
@@ -3666,6 +4035,27 @@ const ssoBridgeCapability = {
3666
4035
  )
3667
4036
  }
3668
4037
  };
4038
+ const OauthIntegrationDescriptorSchema = z.object({
4039
+ /** Stable id used as the `integration=` query param, e.g. 'export-alexa'. */
4040
+ integrationId: z.string(),
4041
+ /** Human label rendered on the consent page. */
4042
+ displayName: z.string(),
4043
+ /** Scopes baked into every token issued for this integration. */
4044
+ requestedScopes: z.array(TokenScopeSchema),
4045
+ /** Allowed redirect_uri prefixes. /api/oauth2/authorize rejects any
4046
+ * redirect_uri that does not start with one of these. Required —
4047
+ * an empty list means the integration can never complete linking. */
4048
+ allowedRedirectPrefixes: z.array(z.string()).min(1)
4049
+ });
4050
+ const oauthIntegrationCapability = {
4051
+ name: "oauth-integration",
4052
+ scope: "system",
4053
+ mode: "collection",
4054
+ internal: true,
4055
+ methods: {
4056
+ getDescriptor: method(z.void(), OauthIntegrationDescriptorSchema)
4057
+ }
4058
+ };
3669
4059
  const PasskeySummarySchema = z.object({
3670
4060
  credentialId: z.string(),
3671
4061
  label: z.string(),
@@ -3981,21 +4371,30 @@ const addonPagesSourceCapability = {
3981
4371
  };
3982
4372
  const WidgetHostEnum = z.enum(["device-tab", "dashboard", "integration-detail"]);
3983
4373
  const WidgetSizeEnum = z.enum(["xs", "sm", "md", "lg", "xl"]);
4374
+ const WidgetRemoteSchema = z.object({
4375
+ remoteName: z.string(),
4376
+ exposedModule: z.string(),
4377
+ componentKey: z.string().optional()
4378
+ });
3984
4379
  const WidgetMetadataSchema = z.object({
3985
- /** Stable id within the addon — kebab-case. */
3986
- stableId: z.string(),
4380
+ // ── UiContribution core (kind:'remote') ──────────────────────────
4381
+ /** Primary host tab — `'dashboard'`, `'device-tab'`, or a device-detail tab id. */
4382
+ tab: z.string(),
4383
+ /** Optional sub-tab within `tab`. */
4384
+ subTab: z.string().optional(),
3987
4385
  /** Operator-facing label. */
3988
4386
  label: z.string(),
4387
+ /** Ordering within `(tab, subTab)`, ascending. */
4388
+ order: z.number().optional(),
4389
+ /** Always `'remote'` — a widget is a Module Federation remote. */
4390
+ kind: z.literal("remote"),
4391
+ /** MF remote descriptor. */
4392
+ remote: WidgetRemoteSchema,
4393
+ // ── Widget-only metadata ─────────────────────────────────────────
4394
+ /** Stable id within the addon — kebab-case. Equals `remote.componentKey`. */
4395
+ stableId: z.string(),
3989
4396
  description: z.string().optional(),
3990
4397
  icon: z.string().optional(),
3991
- /**
3992
- * Module Federation remote name — must match the `name` field on the
3993
- * widget addon's `federation()` plugin config. Used by the host's
3994
- * `<WidgetRegistryProvider>` to call `loadRemote('<remoteName>/widgets')`.
3995
- * Conventionally `addon_<addonid>_widgets` (snake_case; MF names
3996
- * cannot contain hyphens).
3997
- */
3998
- remoteName: z.string(),
3999
4398
  /**
4000
4399
  * Bundle filename inside the addon's `dist/` dir served at
4001
4400
  * `/api/addon-widgets/<addonId>/<bundle>`. With Module Federation
@@ -4004,9 +4403,9 @@ const WidgetMetadataSchema = z.object({
4004
4403
  * cache-buster URL without a separate filesystem stat.
4005
4404
  */
4006
4405
  bundle: z.string(),
4007
- /** Where the widget makes sense to render. */
4406
+ /** Every host the widget supports. The picker filters on this set. */
4008
4407
  hosts: z.array(WidgetHostEnum).readonly(),
4009
- /** Required props the host must supply. Validated at <WidgetSlot> mount. */
4408
+ /** Required props the host must supply. Validated at `<WidgetSlot>` mount. */
4010
4409
  requires: z.object({
4011
4410
  deviceContext: z.boolean().default(false),
4012
4411
  integrationContext: z.boolean().default(false)
@@ -4106,6 +4505,16 @@ const DEFAULT_DECODER_HWACCEL_CONFIG = {
4106
4505
  hwaccel: "auto",
4107
4506
  probedBestHwaccel: ""
4108
4507
  };
4508
+ const ShmRingStatsSchema = z.object({
4509
+ sessionId: z.string(),
4510
+ slotCount: z.number().int(),
4511
+ slotByteLength: z.number().int(),
4512
+ segmentBytes: z.number().int(),
4513
+ budgetMb: z.number().int(),
4514
+ framesWritten: z.number().int(),
4515
+ getFrameHits: z.number().int(),
4516
+ getFrameMisses: z.number().int()
4517
+ });
4109
4518
  const decoderCapability = {
4110
4519
  name: "decoder",
4111
4520
  scope: "system",
@@ -4142,10 +4551,27 @@ const decoderCapability = {
4142
4551
  url: z.string()
4143
4552
  }), z.void()),
4144
4553
  // ── Output — polling-based frame retrieval ────────────────────
4554
+ // `pullFrames` drains the pixel `DecodedFrame[]` of a `frameSink:
4555
+ // 'callback'` session. `pullHandles` (Phase 5 / D9) drains the
4556
+ // zero-pixel `FrameHandle[]` of a `frameSink: 'shm'` session — the
4557
+ // broker hands each handle to a `FrameRingReader` that opens the
4558
+ // named segment and reads the pixels back zero-copy. A session is
4559
+ // one mode or the other; the unmatched method returns an empty
4560
+ // array.
4145
4561
  pullFrames: method(z.object({
4146
4562
  sessionId: z.string(),
4147
4563
  maxCount: z.number().default(1)
4148
4564
  }), z.array(DecodedFrameSchema)),
4565
+ pullHandles: method(z.object({
4566
+ sessionId: z.string(),
4567
+ maxCount: z.number().default(1)
4568
+ }), z.array(FrameHandleSchema)),
4569
+ // ── Frame fetch (Phase 5 / D9 downstream access) ──────────────
4570
+ // Read the pixels a FrameHandle refers to from this node's shm ring.
4571
+ // Returns null when the slot was already recycled (latest-wins).
4572
+ getFrame: method(z.object({ handle: FrameHandleSchema }), DecodedFrameSchema.nullable()),
4573
+ // shm ring usage stats for a session.
4574
+ getShmStats: method(z.object({ sessionId: z.string() }), ShmRingStatsSchema.nullable()),
4149
4575
  // ── Control ───────────────────────────────────────────────────
4150
4576
  updateConfig: method(z.object({
4151
4577
  sessionId: z.string(),
@@ -4298,6 +4724,8 @@ const webrtcSessionCapability = {
4298
4724
  name: "webrtc-session",
4299
4725
  scope: "device",
4300
4726
  mode: "singleton",
4727
+ kind: "wrapper",
4728
+ defaultActive: true,
4301
4729
  deviceTypes: [DeviceType.Camera],
4302
4730
  methods: {
4303
4731
  /**
@@ -4816,6 +5244,8 @@ const audioAnalysisCapability = {
4816
5244
  name: "audio-analysis",
4817
5245
  scope: "device",
4818
5246
  mode: "singleton",
5247
+ kind: "wrapper",
5248
+ defaultActive: true,
4819
5249
  deviceTypes: [DeviceType.Camera],
4820
5250
  exposesDeviceSettings: true,
4821
5251
  methods: {
@@ -5355,8 +5785,8 @@ const deviceManagerCapability = {
5355
5785
  /**
5356
5786
  * Return the addon ids that declared a wrapper provider for `capName`.
5357
5787
  * Backs the device-bindings UI's wrapper-picker dropdown. Entries are
5358
- * sourced from `CapabilityRegistry.wrapperProviders`, populated at
5359
- * `ProviderRegistration.kind === 'wrapper'` time.
5788
+ * sourced from `CapabilityRegistry.wrapperProviders`, populated when
5789
+ * the cap definition declares `kind: 'wrapper'`.
5360
5790
  */
5361
5791
  listWrappersForCap: method(
5362
5792
  z.object({ capName: z.string() }),
@@ -5751,6 +6181,8 @@ const snapshotCapability = {
5751
6181
  name: "snapshot",
5752
6182
  scope: "device",
5753
6183
  mode: "singleton",
6184
+ kind: "wrapper",
6185
+ defaultActive: true,
5754
6186
  deviceTypes: [DeviceType.Camera],
5755
6187
  // Owns per-device snapshot settings (preferred stream, debug logging).
5756
6188
  // The three DeviceSettingsContribution methods are auto-added to the
@@ -6100,6 +6532,8 @@ const detectionPipelineCapability = {
6100
6532
  name: "detection-pipeline",
6101
6533
  scope: "device",
6102
6534
  mode: "singleton",
6535
+ kind: "wrapper",
6536
+ defaultActive: true,
6103
6537
  deviceTypes: [DeviceType.Camera],
6104
6538
  exposesDeviceSettings: true,
6105
6539
  methods: {}
@@ -6208,6 +6642,8 @@ const pipelineAnalyticsCapability = {
6208
6642
  name: "pipeline-analytics",
6209
6643
  scope: "device",
6210
6644
  mode: "singleton",
6645
+ kind: "wrapper",
6646
+ defaultActive: true,
6211
6647
  deviceTypes: [DeviceType.Camera],
6212
6648
  exposesDeviceSettings: true,
6213
6649
  methods: {
@@ -6497,11 +6933,26 @@ const PtzMoveCommandSchema = z.object({
6497
6933
  zoom: z.number().optional(),
6498
6934
  speed: z.number().optional()
6499
6935
  });
6936
+ const PtzStatusSchema = PtzPositionSchema.extend({ autofocus: z.boolean() });
6937
+ const PtzOptionsSchema = z.object({
6938
+ hasPan: z.boolean(),
6939
+ hasTilt: z.boolean(),
6940
+ hasZoom: z.boolean(),
6941
+ supportsPresets: z.boolean(),
6942
+ /** Max number of named presets the camera supports, when known. */
6943
+ maxPresets: z.number().optional(),
6944
+ /** Whether the camera exposes a controllable autofocus toggle
6945
+ * (boolean `hasX` per the getOptions availability convention). */
6946
+ hasAutofocus: z.boolean()
6947
+ });
6500
6948
  const ptzCapability = {
6501
6949
  name: "ptz",
6502
6950
  scope: "device",
6503
6951
  mode: "singleton",
6504
6952
  deviceTypes: [DeviceType.Camera],
6953
+ deviceConfig: {
6954
+ ui: { kind: "widget", widgetId: "host/ptz-panel", tab: "ptz", topTab: true, label: "PTZ", order: 0 }
6955
+ },
6505
6956
  methods: {
6506
6957
  move: method(
6507
6958
  PtzMoveCommandSchema.extend({ deviceId: z.number() }),
@@ -6527,6 +6978,20 @@ const ptzCapability = {
6527
6978
  z.void(),
6528
6979
  { kind: "mutation" }
6529
6980
  ),
6981
+ savePreset: method(
6982
+ z.object({ deviceId: z.number(), presetId: z.string(), name: z.string() }),
6983
+ z.void(),
6984
+ { kind: "mutation", auth: "admin" }
6985
+ ),
6986
+ deletePreset: method(
6987
+ z.object({ deviceId: z.number(), presetId: z.string() }),
6988
+ z.void(),
6989
+ { kind: "mutation", auth: "admin" }
6990
+ ),
6991
+ getOptions: method(
6992
+ z.object({ deviceId: z.number() }),
6993
+ PtzOptionsSchema
6994
+ ),
6530
6995
  goHome: method(
6531
6996
  z.object({ deviceId: z.number() }),
6532
6997
  z.void(),
@@ -6541,10 +7006,17 @@ const ptzCapability = {
6541
7006
  getPosition: method(
6542
7007
  z.object({ deviceId: z.number() }),
6543
7008
  PtzPositionSchema
7009
+ ),
7010
+ /** Toggle the camera's autofocus. Only meaningful when
7011
+ * `getOptions().hasAutofocus` is true. */
7012
+ setAutofocus: method(
7013
+ z.object({ deviceId: z.number(), enabled: z.boolean() }),
7014
+ z.void(),
7015
+ { kind: "mutation" }
6544
7016
  )
6545
7017
  },
6546
7018
  status: {
6547
- schema: PtzPositionSchema,
7019
+ schema: PtzStatusSchema,
6548
7020
  kind: "command-driven"
6549
7021
  }
6550
7022
  };
@@ -7568,83 +8040,6 @@ const meshNetworkCapability = {
7568
8040
  // tabs driven by this cap.
7569
8041
  }
7570
8042
  };
7571
- const MethodAccessSchema = z.enum(["view", "create", "delete"]);
7572
- const AllowedProviderSchema = z.union([z.literal("*"), z.array(z.string())]);
7573
- const AllowedDevicesSchema = z.record(z.string(), z.union([z.literal("*"), z.array(z.string())]));
7574
- const CapScopeSchema = z.enum(["device", "system"]);
7575
- const TokenScopeSchema = z.discriminatedUnion("type", [
7576
- z.object({
7577
- type: z.literal("category"),
7578
- target: CapScopeSchema,
7579
- access: z.array(MethodAccessSchema).min(1)
7580
- }),
7581
- z.object({
7582
- type: z.literal("capability"),
7583
- target: z.string(),
7584
- access: z.array(MethodAccessSchema).min(1)
7585
- }),
7586
- z.object({
7587
- type: z.literal("addon"),
7588
- target: z.string(),
7589
- access: z.array(MethodAccessSchema).min(1)
7590
- }),
7591
- z.object({
7592
- type: z.literal("device"),
7593
- /**
7594
- * One or more deviceIds (serialised as strings for wire-format
7595
- * consistency with the rest of the union). Matcher accepts if
7596
- * `input.deviceId` ∈ `targets`. Array shape avoids the row-explosion
7597
- * of one scope-per-device when granting access to a set of cameras.
7598
- */
7599
- targets: z.array(z.string()).min(1),
7600
- access: z.array(MethodAccessSchema).min(1)
7601
- })
7602
- ]);
7603
- const UserRecordSchema = z.object({
7604
- id: z.string(),
7605
- username: z.string(),
7606
- passwordHash: z.string(),
7607
- /**
7608
- * Admin bypass. When true, the middleware skips the scope-access
7609
- * check entirely. There is no other axis of privilege; the legacy
7610
- * role enum collapsed onto this boolean in v2.
7611
- */
7612
- isAdmin: z.boolean().default(false),
7613
- allowedProviders: AllowedProviderSchema,
7614
- allowedDevices: AllowedDevicesSchema,
7615
- /**
7616
- * Scopes granted to this user. Admins bypass; their `scopes` is
7617
- * ignored. Non-admins without scopes are locked out of every
7618
- * protected call.
7619
- */
7620
- scopes: z.array(TokenScopeSchema).default([]),
7621
- createdAt: z.number(),
7622
- updatedAt: z.number()
7623
- });
7624
- const ApiKeyRecordSchema = z.object({
7625
- id: z.string(),
7626
- label: z.string(),
7627
- isAdmin: z.boolean().default(false),
7628
- allowedProviders: AllowedProviderSchema,
7629
- allowedDevices: AllowedDevicesSchema,
7630
- tokenHash: z.string(),
7631
- tokenPrefix: z.string(),
7632
- createdAt: z.number(),
7633
- lastUsedAt: z.number().optional()
7634
- });
7635
- const ScopedTokenSchema = z.object({
7636
- id: z.string(),
7637
- userId: z.string(),
7638
- name: z.string(),
7639
- tokenHash: z.string(),
7640
- tokenPrefix: z.string(),
7641
- scopes: z.array(TokenScopeSchema),
7642
- // SQLite/JSON storage round-trips undefined → null. Use `nullish` so the
7643
- // schema accepts both `null` (read from disk) and `undefined` (in-memory).
7644
- expiresAt: z.number().nullish(),
7645
- lastUsedAt: z.number().nullish(),
7646
- createdAt: z.number()
7647
- });
7648
8043
  const UserSummarySchema = z.object({
7649
8044
  id: z.string(),
7650
8045
  username: z.string(),
@@ -7717,6 +8112,16 @@ const CreateScopedTokenResultSchema = z.object({
7717
8112
  token: z.string(),
7718
8113
  record: ScopedTokenSummarySchema
7719
8114
  });
8115
+ const OauthSessionSummarySchema = z.object({
8116
+ id: z.string(),
8117
+ userId: z.string(),
8118
+ username: z.string(),
8119
+ integrationId: z.string(),
8120
+ scopes: z.array(TokenScopeSchema),
8121
+ createdAt: z.number(),
8122
+ lastUsedAt: z.number(),
8123
+ revokedAt: z.number().nullable()
8124
+ });
7720
8125
  const TotpSetupResultSchema = z.object({
7721
8126
  secret: z.string(),
7722
8127
  otpauthUrl: z.string()
@@ -7795,6 +8200,66 @@ const userManagementCapability = {
7795
8200
  z.object({ userId: z.string(), code: z.string() }),
7796
8201
  z.object({ valid: z.boolean() }),
7797
8202
  { kind: "mutation", access: "view" }
8203
+ ),
8204
+ // ── OAuth account-linking grant ────────────────────────────────
8205
+ //
8206
+ // Core's /oauth2/* endpoints delegate here. Tokens are sso-bridge
8207
+ // JWTs (kinds oauth-code / oauth-access / oauth-refresh) and ALWAYS
8208
+ // carry isAdmin:false — the operator login proves hub control; the
8209
+ // issued token is minimal (device scope only).
8210
+ oauthIssueCode: method(
8211
+ z.object({
8212
+ integrationId: z.string(),
8213
+ userId: z.string(),
8214
+ username: z.string(),
8215
+ scopes: z.array(TokenScopeSchema),
8216
+ redirectUri: z.string(),
8217
+ hubUrl: z.string()
8218
+ }),
8219
+ z.object({ code: z.string() }),
8220
+ { kind: "mutation", access: "create" }
8221
+ ),
8222
+ oauthExchangeCode: method(
8223
+ z.object({ code: z.string(), redirectUri: z.string() }),
8224
+ z.object({
8225
+ accessToken: z.string(),
8226
+ refreshToken: z.string(),
8227
+ expiresIn: z.number()
8228
+ }).nullable(),
8229
+ { kind: "mutation", access: "view" }
8230
+ ),
8231
+ oauthRefresh: method(
8232
+ z.object({ refreshToken: z.string() }),
8233
+ z.object({
8234
+ accessToken: z.string(),
8235
+ refreshToken: z.string(),
8236
+ expiresIn: z.number()
8237
+ }).nullable(),
8238
+ { kind: "mutation", access: "view" }
8239
+ ),
8240
+ oauthVerifyAccessToken: method(
8241
+ z.object({ token: z.string() }),
8242
+ z.object({
8243
+ userId: z.string(),
8244
+ username: z.string(),
8245
+ scopes: z.array(TokenScopeSchema)
8246
+ }).nullable(),
8247
+ { access: "view" }
8248
+ ),
8249
+ // ── OAuth linked-session management (Phase D) ──────────────────
8250
+ //
8251
+ // The admin UI lists active account-linking sessions and revokes
8252
+ // them; revocation makes the linked integration's tokens fail
8253
+ // verification immediately.
8254
+ listOauthSessions: method(
8255
+ z.void(),
8256
+ z.array(OauthSessionSummarySchema),
8257
+ { auth: "admin" }
8258
+ ),
8259
+ revokeOauthSession: method(
8260
+ z.object({ id: z.string() }),
8261
+ z.object({ success: z.boolean() }),
8262
+ { kind: "mutation", auth: "admin", access: "delete" }
7798
8263
  )
7799
8264
  }
7800
8265
  };
@@ -8024,6 +8489,19 @@ const nodesCapability = {
8024
8489
  z.record(z.string(), ClusterAddonStatusEntrySchema),
8025
8490
  { auth: "admin" }
8026
8491
  ),
8492
+ getCapUsageGraph: method(
8493
+ z.object({
8494
+ windowSeconds: z.number().int().positive().max(300).default(60)
8495
+ }),
8496
+ z.array(z.object({
8497
+ callerAddonId: z.string(),
8498
+ providerAddonId: z.string(),
8499
+ capName: z.string(),
8500
+ callsPerMin: z.number(),
8501
+ lastCallAtMs: z.number()
8502
+ })).readonly(),
8503
+ { auth: "admin" }
8504
+ ),
8027
8505
  /**
8028
8506
  * Direct per-node addon listing — calls `$agent.status` on the target
8029
8507
  * node (or returns the hub registry for `nodeId === 'hub'`) and surfaces
@@ -8585,361 +9063,385 @@ const PIPELINE_OWNER_CAPABILITY_NAMES = [
8585
9063
  "pipeline-runner"
8586
9064
  ];
8587
9065
  export {
8588
- networkQualityCapability as $,
8589
- adminUiCapability as A,
8590
- advancedNotifierCapability as B,
8591
- alertsCapability as C,
8592
- audioAnalysisCapability as D,
8593
- audioAnalyzerCapability as E,
8594
- audioCodecCapability as F,
8595
- authProviderCapability as G,
8596
- backupCapability as H,
8597
- cameraCredentialsCapability as I,
8598
- decoderCapability as J,
8599
- detectionPipelineCapability as K,
8600
- deviceExportCapability as L,
8601
- deviceManagerCapability as M,
8602
- deviceOpsCapability as N,
8603
- deviceStateCapability as O,
8604
- embeddingEncoderCapability as P,
8605
- eventsCapability as Q,
8606
- integrationsCapability as R,
8607
- intercomCapability as S,
8608
- localNetworkCapability as T,
8609
- logDestinationCapability as U,
8610
- meshNetworkCapability as V,
8611
- metricsProviderCapability as W,
8612
- motionDetectionCapability as X,
8613
- mqttBrokerCapability as Y,
8614
- nativeObjectDetectionCapability as Z,
8615
- networkAccessCapability as _,
9066
+ nativeObjectDetectionCapability as $,
9067
+ addonWidgetsSourceCapability as A,
9068
+ addonsCapability as B,
9069
+ adminUiCapability as C,
9070
+ advancedNotifierCapability as D,
9071
+ alertsCapability as E,
9072
+ audioAnalysisCapability as F,
9073
+ audioAnalyzerCapability as G,
9074
+ audioCodecCapability as H,
9075
+ authProviderCapability as I,
9076
+ backupCapability as J,
9077
+ cameraCredentialsCapability as K,
9078
+ decoderCapability as L,
9079
+ detectionPipelineCapability as M,
9080
+ deviceExportCapability as N,
9081
+ deviceManagerCapability as O,
9082
+ deviceOpsCapability as P,
9083
+ deviceStateCapability as Q,
9084
+ embeddingEncoderCapability as R,
9085
+ eventsCapability as S,
9086
+ integrationsCapability as T,
9087
+ intercomCapability as U,
9088
+ localNetworkCapability as V,
9089
+ logDestinationCapability as W,
9090
+ meshNetworkCapability as X,
9091
+ metricsProviderCapability as Y,
9092
+ motionDetectionCapability as Z,
9093
+ mqttBrokerCapability as _,
8616
9094
  zoneRulesCapability as a,
8617
- AudioMetricsSnapshotSchema as a$,
8618
- nodesCapability as a0,
8619
- notificationOutputCapability as a1,
8620
- osdCapability as a2,
8621
- pipelineAnalyticsCapability as a3,
8622
- pipelineExecutorCapability as a4,
8623
- pipelineOrchestratorCapability as a5,
8624
- pipelineRunnerCapability as a6,
8625
- platformProbeCapability as a7,
8626
- ptzCapability as a8,
8627
- rebootCapability as a9,
8628
- AddonAutoUpdateSchema as aA,
8629
- AddonListItemSchema as aB,
8630
- AddonPageDeclarationSchema as aC,
8631
- AddonPageInfoSchema as aD,
8632
- AgentLoadSummarySchema as aE,
8633
- AlertSchema as aF,
8634
- AlertSeveritySchema as aG,
8635
- AlertSourceSchema as aH,
8636
- AlertStatusSchema as aI,
8637
- ApiKeyRecordSchema as aJ,
8638
- ApiKeySummarySchema as aK,
8639
- ArchiveEntrySchema as aL,
8640
- ArchiveManifestSchema as aM,
8641
- AudioAnalysisResultSchema as aN,
8642
- AudioAnalysisSettingsSchema as aO,
8643
- AudioChunkInputSchema as aP,
8644
- AudioClassSummarySchema as aQ,
8645
- AudioClassificationLabelSchema as aR,
8646
- AudioClassificationResultSchema as aS,
8647
- AudioCodecInfoSchema as aT,
8648
- AudioDecodeSessionConfigSchema as aU,
8649
- AudioEncodeSessionConfigSchema as aV,
8650
- AudioEncodedChunkSchema as aW,
8651
- AudioEventSchema as aX,
8652
- AudioLevelSchema as aY,
8653
- AudioMetricsHistoryPointSchema as aZ,
8654
- AudioMetricsHistorySchema as a_,
8655
- recordingCapability as aa,
8656
- recordingEngineCapability as ab,
8657
- restreamerCapability as ac,
8658
- settingsStoreCapability as ad,
8659
- smtpProviderCapability as ae,
8660
- snapshotCapability as af,
8661
- snapshotProviderCapability as ag,
8662
- ssoBridgeCapability as ah,
8663
- storageCapability as ai,
8664
- storageProviderCapability as aj,
8665
- streamBrokerCapability as ak,
8666
- streamingEngineCapability as al,
8667
- systemCapability as am,
8668
- toastCapability as an,
8669
- turnProviderCapability as ao,
8670
- userManagementCapability as ap,
8671
- userPasskeysCapability as aq,
8672
- webrtcCapability as ar,
8673
- webrtcSessionCapability as as,
8674
- ACCESSORY_LABEL as at,
8675
- APPLE_SA_TO_MACRO as au,
8676
- AUDIO_BACKEND_CHOICES as av,
8677
- AUDIO_MACRO_LABELS as aw,
8678
- AccessoriesStatusSchema as ax,
8679
- AccessoryKind as ay,
8680
- AddBrokerInputSchema as az,
9095
+ AudioLevelSchema as a$,
9096
+ networkAccessCapability as a0,
9097
+ networkQualityCapability as a1,
9098
+ nodesCapability as a2,
9099
+ notificationOutputCapability as a3,
9100
+ oauthIntegrationCapability as a4,
9101
+ osdCapability as a5,
9102
+ pipelineAnalyticsCapability as a6,
9103
+ pipelineExecutorCapability as a7,
9104
+ pipelineOrchestratorCapability as a8,
9105
+ pipelineRunnerCapability as a9,
9106
+ AccessoriesStatusSchema as aA,
9107
+ AccessoryKind as aB,
9108
+ AddBrokerInputSchema as aC,
9109
+ AddonAutoUpdateSchema as aD,
9110
+ AddonListItemSchema as aE,
9111
+ AddonPageDeclarationSchema as aF,
9112
+ AddonPageInfoSchema as aG,
9113
+ AgentLoadSummarySchema as aH,
9114
+ AlertSchema as aI,
9115
+ AlertSeveritySchema as aJ,
9116
+ AlertSourceSchema as aK,
9117
+ AlertStatusSchema as aL,
9118
+ ApiKeyRecordSchema as aM,
9119
+ ApiKeySummarySchema as aN,
9120
+ ArchiveEntrySchema as aO,
9121
+ ArchiveManifestSchema as aP,
9122
+ AudioAnalysisResultSchema as aQ,
9123
+ AudioAnalysisSettingsSchema as aR,
9124
+ AudioChunkInputSchema as aS,
9125
+ AudioClassSummarySchema as aT,
9126
+ AudioClassificationLabelSchema as aU,
9127
+ AudioClassificationResultSchema as aV,
9128
+ AudioCodecInfoSchema as aW,
9129
+ AudioDecodeSessionConfigSchema as aX,
9130
+ AudioEncodeSessionConfigSchema as aY,
9131
+ AudioEncodedChunkSchema as aZ,
9132
+ AudioEventSchema as a_,
9133
+ platformProbeCapability as aa,
9134
+ ptzCapability as ab,
9135
+ rebootCapability as ac,
9136
+ recordingCapability as ad,
9137
+ recordingEngineCapability as ae,
9138
+ restreamerCapability as af,
9139
+ settingsStoreCapability as ag,
9140
+ smtpProviderCapability as ah,
9141
+ snapshotCapability as ai,
9142
+ snapshotProviderCapability as aj,
9143
+ ssoBridgeCapability as ak,
9144
+ storageCapability as al,
9145
+ storageProviderCapability as am,
9146
+ streamBrokerCapability as an,
9147
+ streamingEngineCapability as ao,
9148
+ systemCapability as ap,
9149
+ toastCapability as aq,
9150
+ turnProviderCapability as ar,
9151
+ userManagementCapability as as,
9152
+ userPasskeysCapability as at,
9153
+ webrtcCapability as au,
9154
+ webrtcSessionCapability as av,
9155
+ ACCESSORY_LABEL as aw,
9156
+ APPLE_SA_TO_MACRO as ax,
9157
+ AUDIO_BACKEND_CHOICES as ay,
9158
+ AUDIO_MACRO_LABELS as az,
8681
9159
  zoneAnalyticsCapability as b,
8682
- DeviceRole as b$,
8683
- AudioPcmChunkSchema as b0,
8684
- AuthResultSchema as b1,
8685
- AutoUpdateSettingsSchema as b2,
8686
- AvailableIntegrationTypeSchema as b3,
8687
- BATTERY_DEVICE_PROFILE as b4,
8688
- BackupDestinationInfoSchema as b5,
8689
- BackupEntrySchema as b6,
8690
- BatteryStatusSchema as b7,
8691
- BoundingBoxSchema as b8,
8692
- BrightnessStatusSchema as b9,
8693
- ConfigSectionWithValuesSchema as bA,
8694
- ConfigTabDeclarationSchema as bB,
8695
- CreateApiKeyInputSchema as bC,
8696
- CreateApiKeyResultSchema as bD,
8697
- CreateIntegrationInputSchema as bE,
8698
- CreateScopedTokenInputSchema as bF,
8699
- CreateScopedTokenResultSchema as bG,
8700
- CreateUserInputSchema as bH,
8701
- CustomActionInputSchema as bI,
8702
- DEFAULT_AUDIO_ANALYZER_CONFIG as bJ,
8703
- DEFAULT_DECODER_HWACCEL_CONFIG as bK,
8704
- DEVICE_PROFILES as bL,
8705
- DEVICE_SETTINGS_CONTRIBUTION_METHODS as bM,
8706
- DEVICE_STATUS_METHOD as bN,
8707
- DecodedFrameSchema as bO,
8708
- DecoderAssignmentSchema as bP,
8709
- DecoderSessionConfigSchema as bQ,
8710
- DecoderStatsSchema as bR,
8711
- DeleteIntegrationResultSchema as bS,
8712
- DetectorOutputSchema as bT,
8713
- DeviceDiscoveryStatusSchema as bU,
8714
- ExposeInputSchema as bV,
8715
- DeviceExportStatusSchema as bW,
8716
- UnexposeInputSchema as bX,
8717
- DeviceFeature as bY,
8718
- DeviceInfoSchema as bZ,
8719
- DeviceNetworkStatsSchema as b_,
8720
- BrokerAudioClientSchema as ba,
8721
- BrokerClientsSchema as bb,
8722
- BrokerConnectionDetailsSchema as bc,
8723
- BrokerDecodedClientSchema as bd,
8724
- BrokerInfoSchema as be,
8725
- BrokerRtspClientSchema as bf,
8726
- BrokerStatsSchema as bg,
8727
- BrokerStatusSchema$1 as bh,
8728
- CAM_PROFILE_ORDER as bi,
8729
- CamProfileSchema as bj,
8730
- CamStreamKindSchema as bk,
8731
- CamStreamResolutionSchema as bl,
8732
- CameraCredentialsSchema as bm,
8733
- CameraCredentialsStatusSchema as bn,
8734
- CameraMetricsSchema as bo,
8735
- CameraMetricsWithDeviceIdSchema as bp,
8736
- CameraStreamSchema as bq,
8737
- CapScopeSchema as br,
8738
- CapabilityBindingsSchema as bs,
8739
- ChargingStatus as bt,
8740
- ClientNetworkStatsSchema as bu,
8741
- ClusterAddonNodeDeploymentSchema as bv,
8742
- ClusterAddonStatusEntrySchema as bw,
8743
- CollectionColumnSchema as bx,
8744
- CollectionIndexSchema as by,
8745
- ConfigEntrySchema$1 as bz,
8746
- motionCapability as c,
8747
- OsdOverlaySchema as c$,
8748
- DeviceStatusSchema as c0,
8749
- DeviceType as c1,
8750
- DiscoveredChildDeviceSchema as c2,
8751
- DiscoveredChildStatusSchema as c3,
8752
- DiscoveredDeviceSchema as c4,
8753
- DoorbellPressEventSchema as c5,
8754
- DoorbellStatusSchema as c6,
8755
- EmbeddingInfoSchema as c7,
8756
- EmbeddingResultSchema as c8,
8757
- EncodedPacketSchema as c9,
8758
- MediaFileSchema as cA,
8759
- MeshPeerSchema as cB,
8760
- MeshStatusSchema as cC,
8761
- MethodAccessSchema as cD,
8762
- MotionAnalysisResultSchema as cE,
8763
- MotionEventSchema as cF,
8764
- MotionOnMotionChangedDataSchema as cG,
8765
- MotionRegionSchema as cH,
8766
- MotionSourceEnum as cI,
8767
- MotionSourcesSchema as cJ,
8768
- MotionStatusSchema as cK,
8769
- MotionTriggerRuntimeStateSchema as cL,
8770
- MotionTriggerStatusSchema as cM,
8771
- StatusSchema as cN,
8772
- NativeDetectionSchema as cO,
8773
- NativeObjectClassEnum as cP,
8774
- NativeObjectDetectionStatusSchema as cQ,
8775
- NetworkAccessStatusSchema as cR,
8776
- NetworkAddressSchema as cS,
8777
- NetworkEndpointSchema as cT,
8778
- NotificationHistoryEntrySchema as cU,
8779
- NotificationRuleSchema as cV,
8780
- NotificationSchema as cW,
8781
- ObjectEventSchema as cX,
8782
- OrchestratorMetricsSchema as cY,
8783
- OsdOverlayKindEnum as cZ,
8784
- OsdOverlayPatchSchema as c_,
8785
- EnrichedWidgetMetadataSchema as ca,
8786
- EventItemSchema as cb,
8787
- EventKindSchema as cc,
8788
- ExportSetupFieldSchema as cd,
8789
- ExportSetupSchema as ce,
8790
- ExposedDeviceSchema as cf,
8791
- ExposedResourceSchema as cg,
8792
- FeatureManifestSchema as ch,
8793
- FeatureProbeStatusSchema as ci,
8794
- FrameInputSchema as cj,
8795
- GetStreamWithCodecInputSchema as ck,
8796
- GlobalMetricsSchema as cl,
8797
- HWACCEL_OPTIONS as cm,
8798
- HealthStatusSchema as cn,
8799
- HistoryPointSchema as co,
8800
- HistoryResolutionEnum as cp,
8801
- InstalledPackageSchema as cq,
8802
- IntegrationLiteSchema as cr,
8803
- IntegrationWithStateSchema as cs,
8804
- IntercomAbilitySchema as ct,
8805
- IntercomStatusSchema as cu,
8806
- LocationStatSchema as cv,
8807
- LogEntrySchema as cw,
8808
- LogLevelSchema$1 as cx,
8809
- LogStreamEntrySchema as cy,
8810
- MODEL_FORMATS as cz,
8811
- doorbellCapability as d,
8812
- ReadChunkInputSchema as d$,
8813
- OsdPositionEnum as d0,
8814
- OsdStatusSchema as d1,
8815
- PIPELINE_FLOW_CAPABILITY_NAMES as d2,
8816
- PIPELINE_OWNER_CAPABILITY_NAMES as d3,
8817
- PackageUpdateSchema as d4,
8818
- PackageVersionInfoSchema as d5,
8819
- PasskeySummarySchema as d6,
8820
- PcmSampleFormatSchema as d7,
8821
- PerScopeBreakdownSchema as d8,
8822
- PipelineAssignmentSchema as d9,
8823
- STORAGE_LOCATION_CARDINALITY as dA,
8824
- ScopedTokenSchema as dB,
8825
- ScopedTokenSummarySchema as dC,
8826
- SearchResultSchema as dD,
8827
- SegmentSchema as dE,
8828
- SendEmailInputSchema as dF,
8829
- SendEmailResultSchema as dG,
8830
- SettingsPatchSchema as dH,
8831
- SettingsRecordSchema as dI,
8832
- SettingsSchemaWithValuesSchema as dJ,
8833
- SettingsUpdateResultSchema as dK,
8834
- SmtpStatusSchema as dL,
8835
- SnapshotImageSchema as dM,
8836
- SpatialDetectionSchema as dN,
8837
- SsoBridgeClaimsSchema as dO,
8838
- StartEmbeddedInputSchema as dP,
8839
- AbortUploadInputSchema as dQ,
8840
- BeginDownloadInputSchema as dR,
8841
- BeginDownloadResultSchema as dS,
8842
- BeginUploadInputSchema as dT,
8843
- BeginUploadResultSchema as dU,
8844
- EndDownloadInputSchema as dV,
8845
- FinalizeUploadInputSchema as dW,
8846
- StorageLocationRefSchema as dX,
8847
- StorageLocationSchema as dY,
8848
- StorageLocationTypeSchema as dZ,
8849
- ProviderInfoSchema as d_,
8850
- PipelineDefaultStepSchema as da,
8851
- PipelineEngineChoiceSchema as db,
8852
- PipelineRunResultBridge as dc,
8853
- PipelineStepInputSchema as dd,
8854
- PlaceholderReasonSchema as de,
8855
- PolygonPointSchema as df,
8856
- ProfileSlotSchema as dg,
8857
- ProfileSlotStatusSchema as dh,
8858
- ProviderStatusSchema as di,
8859
- PtzAutotrackRuntimeStateSchema as dj,
8860
- PtzAutotrackSettingsSchema as dk,
8861
- PtzAutotrackStatusSchema as dl,
8862
- PtzAutotrackTargetOptionSchema as dm,
8863
- PtzMoveCommandSchema as dn,
8864
- PtzPositionSchema as dp,
8865
- PtzPresetSchema as dq,
8866
- QueryFilterSchema as dr,
8867
- RegisteredStreamSchema as ds,
8868
- ReportMotionInputSchema as dt,
8869
- RtpSourceSchema as du,
8870
- RtspRestreamEntrySchema as dv,
8871
- RunnerCameraConfigSchema as dw,
8872
- RunnerCameraDeviceUIFields as dx,
8873
- RunnerLocalLoadSchema as dy,
8874
- RunnerLocalMetricsSchema as dz,
9160
+ UnexposeInputSchema as b$,
9161
+ AudioMetricsHistoryPointSchema as b0,
9162
+ AudioMetricsHistorySchema as b1,
9163
+ AudioMetricsSnapshotSchema as b2,
9164
+ AudioPcmChunkSchema as b3,
9165
+ AuthResultSchema as b4,
9166
+ AutoUpdateSettingsSchema as b5,
9167
+ AvailableIntegrationTypeSchema as b6,
9168
+ BATTERY_DEVICE_PROFILE as b7,
9169
+ BackupDestinationInfoSchema as b8,
9170
+ BackupEntrySchema as b9,
9171
+ CollectionColumnSchema as bA,
9172
+ CollectionIndexSchema as bB,
9173
+ ConfigEntrySchema$1 as bC,
9174
+ ConfigSectionWithValuesSchema as bD,
9175
+ ConfigTabDeclarationSchema as bE,
9176
+ CreateApiKeyInputSchema as bF,
9177
+ CreateApiKeyResultSchema as bG,
9178
+ CreateIntegrationInputSchema as bH,
9179
+ CreateScopedTokenInputSchema as bI,
9180
+ CreateScopedTokenResultSchema as bJ,
9181
+ CreateUserInputSchema as bK,
9182
+ CustomActionInputSchema as bL,
9183
+ DEFAULT_AUDIO_ANALYZER_CONFIG as bM,
9184
+ DEFAULT_DECODER_HWACCEL_CONFIG as bN,
9185
+ DEVICE_PROFILES as bO,
9186
+ DEVICE_SETTINGS_CONTRIBUTION_METHODS as bP,
9187
+ DEVICE_STATUS_METHOD as bQ,
9188
+ DecodedAudioChunkSchema as bR,
9189
+ DecodedFrameSchema as bS,
9190
+ DecoderAssignmentSchema as bT,
9191
+ DecoderSessionConfigSchema as bU,
9192
+ DecoderStatsSchema as bV,
9193
+ DeleteIntegrationResultSchema as bW,
9194
+ DetectorOutputSchema as bX,
9195
+ DeviceDiscoveryStatusSchema as bY,
9196
+ ExposeInputSchema as bZ,
9197
+ DeviceExportStatusSchema as b_,
9198
+ BatteryStatusSchema as ba,
9199
+ BoundingBoxSchema as bb,
9200
+ BrightnessStatusSchema as bc,
9201
+ BrokerAudioClientSchema as bd,
9202
+ BrokerClientsSchema as be,
9203
+ BrokerConnectionDetailsSchema as bf,
9204
+ BrokerDecodedClientSchema as bg,
9205
+ BrokerInfoSchema as bh,
9206
+ BrokerRtspClientSchema as bi,
9207
+ BrokerStatsSchema as bj,
9208
+ BrokerStatusSchema$1 as bk,
9209
+ CAM_PROFILE_ORDER as bl,
9210
+ CamProfileSchema as bm,
9211
+ CamStreamKindSchema as bn,
9212
+ CamStreamResolutionSchema as bo,
9213
+ CameraCredentialsSchema as bp,
9214
+ CameraCredentialsStatusSchema as bq,
9215
+ CameraMetricsSchema as br,
9216
+ CameraMetricsWithDeviceIdSchema as bs,
9217
+ CameraStreamSchema as bt,
9218
+ CapScopeSchema as bu,
9219
+ CapabilityBindingsSchema as bv,
9220
+ ChargingStatus as bw,
9221
+ ClientNetworkStatsSchema as bx,
9222
+ ClusterAddonNodeDeploymentSchema as by,
9223
+ ClusterAddonStatusEntrySchema as bz,
9224
+ streamParamsCapability as c,
9225
+ NetworkAddressSchema as c$,
9226
+ DeviceFeature as c0,
9227
+ DeviceInfoSchema as c1,
9228
+ DeviceNetworkStatsSchema as c2,
9229
+ DeviceRole as c3,
9230
+ DeviceStatusSchema as c4,
9231
+ DeviceType as c5,
9232
+ DiscoveredChildDeviceSchema as c6,
9233
+ DiscoveredChildStatusSchema as c7,
9234
+ DiscoveredDeviceSchema as c8,
9235
+ DoorbellPressEventSchema as c9,
9236
+ IntercomStatusSchema as cA,
9237
+ LocationStatSchema as cB,
9238
+ LogEntrySchema as cC,
9239
+ LogLevelSchema$1 as cD,
9240
+ LogStreamEntrySchema as cE,
9241
+ MODEL_FORMATS as cF,
9242
+ MediaFileSchema as cG,
9243
+ MeshPeerSchema as cH,
9244
+ MeshStatusSchema as cI,
9245
+ MethodAccessSchema as cJ,
9246
+ MotionAnalysisResultSchema as cK,
9247
+ MotionEventSchema as cL,
9248
+ MotionOnMotionChangedDataSchema as cM,
9249
+ MotionRegionSchema as cN,
9250
+ MotionSourceEnum as cO,
9251
+ MotionSourcesSchema as cP,
9252
+ MotionStatusSchema as cQ,
9253
+ MotionTriggerRuntimeStateSchema as cR,
9254
+ MotionTriggerStatusSchema as cS,
9255
+ MotionZoneOptionsSchema as cT,
9256
+ MotionZonePatchSchema as cU,
9257
+ MotionZoneStatusSchema as cV,
9258
+ StatusSchema as cW,
9259
+ NativeDetectionSchema as cX,
9260
+ NativeObjectClassEnum as cY,
9261
+ NativeObjectDetectionStatusSchema as cZ,
9262
+ NetworkAccessStatusSchema as c_,
9263
+ DoorbellStatusSchema as ca,
9264
+ EmbeddingInfoSchema as cb,
9265
+ EmbeddingResultSchema as cc,
9266
+ EncodedPacketSchema as cd,
9267
+ EnrichedWidgetMetadataSchema as ce,
9268
+ EventItemSchema as cf,
9269
+ EventKindSchema as cg,
9270
+ ExportSetupFieldSchema as ch,
9271
+ ExportSetupSchema as ci,
9272
+ ExposedDeviceSchema as cj,
9273
+ ExposedResourceSchema as ck,
9274
+ FeatureManifestSchema as cl,
9275
+ FeatureProbeStatusSchema as cm,
9276
+ FrameHandleFormatSchema as cn,
9277
+ FrameHandleSchema as co,
9278
+ FrameInputSchema as cp,
9279
+ GetStreamWithCodecInputSchema as cq,
9280
+ GlobalMetricsSchema as cr,
9281
+ HWACCEL_OPTIONS as cs,
9282
+ HealthStatusSchema as ct,
9283
+ HistoryPointSchema as cu,
9284
+ HistoryResolutionEnum as cv,
9285
+ InstalledPackageSchema as cw,
9286
+ IntegrationLiteSchema as cx,
9287
+ IntegrationWithStateSchema as cy,
9288
+ IntercomAbilitySchema as cz,
9289
+ motionTriggerCapability as d,
9290
+ StartEmbeddedInputSchema as d$,
9291
+ NetworkEndpointSchema as d0,
9292
+ NotificationHistoryEntrySchema as d1,
9293
+ NotificationRuleSchema as d2,
9294
+ NotificationSchema as d3,
9295
+ OauthIntegrationDescriptorSchema as d4,
9296
+ ObjectEventSchema as d5,
9297
+ OrchestratorMetricsSchema as d6,
9298
+ OsdOverlayKindEnum as d7,
9299
+ OsdOverlayPatchSchema as d8,
9300
+ OsdOverlaySchema as d9,
9301
+ PtzPresetSchema as dA,
9302
+ PtzStatusSchema as dB,
9303
+ QueryFilterSchema as dC,
9304
+ RegisteredStreamSchema as dD,
9305
+ ReportMotionInputSchema as dE,
9306
+ RtpSourceSchema as dF,
9307
+ RtspRestreamEntrySchema as dG,
9308
+ RunnerCameraConfigSchema as dH,
9309
+ RunnerCameraDeviceUIFields as dI,
9310
+ RunnerLocalLoadSchema as dJ,
9311
+ RunnerLocalMetricsSchema as dK,
9312
+ STORAGE_LOCATION_CARDINALITY as dL,
9313
+ ScopedTokenSchema as dM,
9314
+ ScopedTokenSummarySchema as dN,
9315
+ SearchResultSchema as dO,
9316
+ SegmentSchema as dP,
9317
+ SendEmailInputSchema as dQ,
9318
+ SendEmailResultSchema as dR,
9319
+ SettingsPatchSchema as dS,
9320
+ SettingsRecordSchema as dT,
9321
+ SettingsSchemaWithValuesSchema as dU,
9322
+ SettingsUpdateResultSchema as dV,
9323
+ ShmRingStatsSchema as dW,
9324
+ SmtpStatusSchema as dX,
9325
+ SnapshotImageSchema as dY,
9326
+ SpatialDetectionSchema as dZ,
9327
+ SsoBridgeClaimsSchema as d_,
9328
+ OsdPositionEnum as da,
9329
+ OsdStatusSchema as db,
9330
+ PIPELINE_FLOW_CAPABILITY_NAMES as dc,
9331
+ PIPELINE_OWNER_CAPABILITY_NAMES as dd,
9332
+ PackageUpdateSchema as de,
9333
+ PackageVersionInfoSchema as df,
9334
+ PasskeySummarySchema as dg,
9335
+ PcmSampleFormatSchema as dh,
9336
+ PerScopeBreakdownSchema as di,
9337
+ PipelineAssignmentSchema as dj,
9338
+ PipelineDefaultStepSchema as dk,
9339
+ PipelineEngineChoiceSchema as dl,
9340
+ PipelineRunResultBridge as dm,
9341
+ PipelineStepInputSchema as dn,
9342
+ PlaceholderReasonSchema as dp,
9343
+ PolygonPointSchema as dq,
9344
+ ProfileSlotSchema as dr,
9345
+ ProfileSlotStatusSchema as ds,
9346
+ ProviderStatusSchema as dt,
9347
+ PtzAutotrackRuntimeStateSchema as du,
9348
+ PtzAutotrackSettingsSchema as dv,
9349
+ PtzAutotrackStatusSchema as dw,
9350
+ PtzAutotrackTargetOptionSchema as dx,
9351
+ PtzMoveCommandSchema as dy,
9352
+ PtzPositionSchema as dz,
8875
9353
  errMsg as e,
8876
- TestLocationResultSchema as e0,
8877
- WriteChunkInputSchema as e1,
8878
- StreamFormatSchema as e2,
8879
- StreamInfoSchema as e3,
8880
- StreamNetworkStatsSchema as e4,
8881
- StreamSourceEntrySchema$1 as e5,
8882
- StreamSourceSchema as e6,
8883
- SwitchStatusSchema as e7,
8884
- SystemMetricsSchema as e8,
8885
- TestConnectionResultSchema as e9,
8886
- ZoneSchema as eA,
8887
- ZoneScopeBreakdownSchema as eB,
8888
- accessoryStableId as eC,
8889
- deviceMatchesProfile as eD,
8890
- event as eE,
8891
- expandCapMethods as eF,
8892
- getAudioMacroClassIds as eG,
8893
- mapAudioLabelToMacro as eH,
8894
- method as eI,
8895
- resolveDeviceProfile as eJ,
8896
- webrtcClientHintsSchema as eK,
8897
- ToastSchema as ea,
8898
- TokenScopeSchema as eb,
8899
- TopologyNodeSchema as ec,
8900
- TopologyProcessSchema as ed,
8901
- TopologyServiceSchema as ee,
8902
- TrackSchema as ef,
8903
- TrackStateSchema as eg,
8904
- TrackedDetectionSchema as eh,
8905
- TurnServerSchema as ei,
8906
- UpdateIntegrationInputSchema as ej,
8907
- UpdateUserInputSchema as ek,
8908
- UserRecordSchema as el,
8909
- UserSummarySchema as em,
8910
- WELL_KNOWN_TABS as en,
8911
- WELL_KNOWN_TAB_MAP as eo,
8912
- WebrtcStreamChoiceSchema as ep,
8913
- WebrtcStreamTargetSchema as eq,
8914
- WidgetHostEnum as er,
8915
- WidgetMetadataSchema as es,
8916
- WidgetSizeEnum as et,
8917
- YAMNET_TO_MACRO as eu,
8918
- ZoneKindEnum as ev,
8919
- ZoneRuleModeEnum as ew,
8920
- ZoneRuleSchema as ex,
8921
- ZoneRuleStageEnum as ey,
8922
- ZoneRulesArraySchema as ez,
8923
- featureProbeCapability as f,
8924
- deviceStatusCapability as g,
9354
+ event as e$,
9355
+ AbortUploadInputSchema as e0,
9356
+ BeginDownloadInputSchema as e1,
9357
+ BeginDownloadResultSchema as e2,
9358
+ BeginUploadInputSchema as e3,
9359
+ BeginUploadResultSchema as e4,
9360
+ EndDownloadInputSchema as e5,
9361
+ FinalizeUploadInputSchema as e6,
9362
+ StorageLocationRefSchema as e7,
9363
+ StorageLocationSchema as e8,
9364
+ StorageLocationTypeSchema as e9,
9365
+ TopologyServiceSchema as eA,
9366
+ TrackSchema as eB,
9367
+ TrackStateSchema as eC,
9368
+ TrackedDetectionSchema as eD,
9369
+ TurnServerSchema as eE,
9370
+ UpdateIntegrationInputSchema as eF,
9371
+ UpdateUserInputSchema as eG,
9372
+ UserRecordSchema as eH,
9373
+ UserSummarySchema as eI,
9374
+ WELL_KNOWN_TABS as eJ,
9375
+ WELL_KNOWN_TAB_MAP as eK,
9376
+ WebrtcStreamChoiceSchema as eL,
9377
+ WebrtcStreamTargetSchema as eM,
9378
+ WidgetHostEnum as eN,
9379
+ WidgetMetadataSchema as eO,
9380
+ WidgetRemoteSchema as eP,
9381
+ WidgetSizeEnum as eQ,
9382
+ YAMNET_TO_MACRO as eR,
9383
+ ZoneKindEnum as eS,
9384
+ ZoneRuleModeEnum as eT,
9385
+ ZoneRuleSchema as eU,
9386
+ ZoneRuleStageEnum as eV,
9387
+ ZoneRulesArraySchema as eW,
9388
+ ZoneSchema as eX,
9389
+ ZoneScopeBreakdownSchema as eY,
9390
+ accessoryStableId as eZ,
9391
+ deviceMatchesProfile as e_,
9392
+ ProviderInfoSchema as ea,
9393
+ ReadChunkInputSchema as eb,
9394
+ TestLocationResultSchema as ec,
9395
+ WriteChunkInputSchema as ed,
9396
+ StreamFormatSchema as ee,
9397
+ StreamInfoSchema as ef,
9398
+ StreamNetworkStatsSchema as eg,
9399
+ StreamParamsOptionsSchema as eh,
9400
+ StreamParamsStatusSchema as ei,
9401
+ StreamProfileConfigSchema as ej,
9402
+ StreamProfileOptionsSchema as ek,
9403
+ StreamProfilePatchSchema as el,
9404
+ StreamProfileSchema as em,
9405
+ StreamSourceEntrySchema$1 as en,
9406
+ StreamSourceSchema as eo,
9407
+ SubscribeAudioChunksInputSchema as ep,
9408
+ SubscribeAudioChunksResultSchema as eq,
9409
+ SubscribeFramesInputSchema as er,
9410
+ SubscribeFramesResultSchema as es,
9411
+ SwitchStatusSchema as et,
9412
+ SystemMetricsSchema as eu,
9413
+ TestConnectionResultSchema as ev,
9414
+ ToastSchema as ew,
9415
+ TokenScopeSchema as ex,
9416
+ TopologyNodeSchema as ey,
9417
+ TopologyProcessSchema as ez,
9418
+ motionCapability as f,
9419
+ expandCapMethods as f0,
9420
+ getAudioMacroClassIds as f1,
9421
+ isDeviceConfigCap as f2,
9422
+ mapAudioLabelToMacro as f3,
9423
+ method as f4,
9424
+ resolveDeviceProfile as f5,
9425
+ webrtcClientHintsSchema as f6,
9426
+ featureProbeCapability as g,
8925
9427
  hydrateSchema as h,
8926
- deviceDiscoveryCapability as i,
8927
- cameraStreamsCapability as j,
8928
- brightnessCapability as k,
8929
- batteryCapability as l,
8930
- motionTriggerCapability as m,
8931
- audioMetricsCapability as n,
8932
- deviceProviderCapability as o,
9428
+ doorbellCapability as i,
9429
+ deviceStatusCapability as j,
9430
+ deviceDiscoveryCapability as k,
9431
+ cameraStreamsCapability as l,
9432
+ motionZonesCapability as m,
9433
+ brightnessCapability as n,
9434
+ batteryCapability as o,
8933
9435
  ptzAutotrackCapability as p,
8934
- accessoriesCapability as q,
8935
- addonPagesCapability as r,
9436
+ audioMetricsCapability as q,
9437
+ deviceProviderCapability as r,
8936
9438
  switchCapability as s,
8937
- addonPagesSourceCapability as t,
8938
- addonRoutesCapability as u,
8939
- addonSettingsCapability as v,
8940
- addonWidgetsCapability as w,
8941
- addonWidgetsSourceCapability as x,
8942
- addonsCapability as y,
9439
+ accessoriesCapability as t,
9440
+ addonPagesCapability as u,
9441
+ addonPagesSourceCapability as v,
9442
+ addonRoutesCapability as w,
9443
+ addonSettingsCapability as x,
9444
+ addonWidgetsCapability as y,
8943
9445
  zonesCapability as z
8944
9446
  };
8945
- //# sourceMappingURL=index-CWhQOnm9.mjs.map
9447
+ //# sourceMappingURL=index-CgPd35k5.mjs.map