@camstack/addon-export-google 0.1.11 → 0.1.12

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.
@@ -19035,6 +19035,50 @@ var EventStoreFootprintSchema = object({
19035
19035
  totalBytes: number().int(),
19036
19036
  devices: array(EventStoreDeviceFootprintSchema).readonly()
19037
19037
  });
19038
+ /** Event-media footprint for one {@link MediaFileKind}. */
19039
+ var EventMediaKindFootprintSchema = object({
19040
+ kind: MediaFileKindEnum,
19041
+ /** Media rows of this kind. */
19042
+ rows: number().int(),
19043
+ /** Bytes on disk held by those rows. */
19044
+ bytes: number().int()
19045
+ });
19046
+ /**
19047
+ * The media footprint broken down by KIND — the axis a deletion decision
19048
+ * actually turns on.
19049
+ *
19050
+ * A byte total says how much there is; it cannot say what is safe to remove.
19051
+ * The deletable set (the periodic `snapshot` filmstrip, the surplus per-edge
19052
+ * motion stills) and the keep set (`firstFrame`, rolling `lastFrame`,
19053
+ * `thumbnail`/`thumbnailSmall`, `keyFrame`/`keyFrameSmall`, the face/plate
19054
+ * buffers, gallery media, the CLIP `crop`) are distinguished by `kind` and by
19055
+ * nothing else, so sizing a deletion means summing per kind.
19056
+ *
19057
+ * ## Why `unaccounted*` exists
19058
+ *
19059
+ * `kinds` is enumerated from {@link MediaFileKindEnum} — the closed set the
19060
+ * writers use — and summed one kind at a time. `totalRows` / `totalBytes` come
19061
+ * from a SEPARATE unfiltered aggregate over the same rows, never from adding
19062
+ * `kinds` up. A row whose stored `kind` is not in the enum (written by a
19063
+ * retired code path, or by a version that knew a kind this one does not) would
19064
+ * otherwise vanish from the total silently, and an operator would delete
19065
+ * against a denominator smaller than the disk.
19066
+ *
19067
+ * `unaccountedRows` / `unaccountedBytes` are the difference. They are normally
19068
+ * zero; a non-zero value is a real finding and must be shown, not rounded away.
19069
+ */
19070
+ var EventMediaKindBreakdownSchema = object({
19071
+ /** Every media row in scope, from one unfiltered aggregate. */
19072
+ totalRows: number().int(),
19073
+ /** Every media byte in scope, from that same aggregate. */
19074
+ totalBytes: number().int(),
19075
+ /** Per-kind footprint, ordered by bytes descending. */
19076
+ kinds: array(EventMediaKindFootprintSchema).readonly(),
19077
+ /** `totalRows` minus the summed `kinds` rows — see the schema note. */
19078
+ unaccountedRows: number().int(),
19079
+ /** `totalBytes` minus the summed `kinds` bytes — see the schema note. */
19080
+ unaccountedBytes: number().int()
19081
+ });
19038
19082
  /** Per-kind counts returned by the event-prune / device-delete mutations. */
19039
19083
  var EventPruneCountsSchema = object({
19040
19084
  motion: number().int(),
@@ -19238,6 +19282,9 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
19238
19282
  }), TrackFlagsSchema, { kind: "mutation" }), method(object({}), EventStoreFootprintSchema, {
19239
19283
  kind: "query",
19240
19284
  auth: "admin"
19285
+ }), method(object({ deviceId: number().int().optional() }), EventMediaKindBreakdownSchema, {
19286
+ kind: "query",
19287
+ auth: "admin"
19241
19288
  }), method(object({
19242
19289
  olderThanMs: number(),
19243
19290
  reason: OpsLogReasonSchema.optional()
@@ -21189,6 +21236,20 @@ method(object({
21189
21236
  error: string().optional()
21190
21237
  }), { auth: "admin" }), method(_void(), array(ProviderListEntrySchema).readonly()), method(object({
21191
21238
  providerId: string(),
21239
+ /**
21240
+ * The location this config is an UNSAVED edit of, when there is one.
21241
+ *
21242
+ * `listLocations` replaces every declared secret with the redaction
21243
+ * sentinel, so the edit modal's form state holds the sentinel for any
21244
+ * credential the operator did not retype — and posting that here
21245
+ * without a way to resolve it makes the provider try to authenticate
21246
+ * as `__camstack_redacted__` and report the operator's own working
21247
+ * password as wrong. Given this id, the orchestrator restores each
21248
+ * sentinel from the stored config (same rule as `upsertLocation`)
21249
+ * before dispatching. Omitted by the "Add location" wizard, where
21250
+ * every value was typed just now and nothing is stored yet.
21251
+ */
21252
+ locationId: string().optional(),
21192
21253
  config: record(string(), unknown())
21193
21254
  }), object({
21194
21255
  ok: boolean(),
@@ -31862,6 +31923,12 @@ Object.freeze({
31862
31923
  addonId: null,
31863
31924
  access: "view"
31864
31925
  },
31926
+ "pipelineAnalytics.getEventMediaFootprintByKind": {
31927
+ capName: "pipeline-analytics",
31928
+ capScope: "device",
31929
+ addonId: null,
31930
+ access: "view"
31931
+ },
31865
31932
  "pipelineAnalytics.getEventStoreFootprint": {
31866
31933
  capName: "pipeline-analytics",
31867
31934
  capScope: "device",
@@ -35527,6 +35594,11 @@ Object.freeze({
35527
35594
  form: "single",
35528
35595
  optional: false
35529
35596
  }],
35597
+ "pipelineAnalytics.getEventMediaFootprintByKind": [{
35598
+ name: "deviceId",
35599
+ form: "single",
35600
+ optional: true
35601
+ }],
35530
35602
  "pipelineAnalytics.getGroup": [{
35531
35603
  name: "deviceId",
35532
35604
  form: "single",
@@ -19031,6 +19031,50 @@ var EventStoreFootprintSchema = object({
19031
19031
  totalBytes: number().int(),
19032
19032
  devices: array(EventStoreDeviceFootprintSchema).readonly()
19033
19033
  });
19034
+ /** Event-media footprint for one {@link MediaFileKind}. */
19035
+ var EventMediaKindFootprintSchema = object({
19036
+ kind: MediaFileKindEnum,
19037
+ /** Media rows of this kind. */
19038
+ rows: number().int(),
19039
+ /** Bytes on disk held by those rows. */
19040
+ bytes: number().int()
19041
+ });
19042
+ /**
19043
+ * The media footprint broken down by KIND — the axis a deletion decision
19044
+ * actually turns on.
19045
+ *
19046
+ * A byte total says how much there is; it cannot say what is safe to remove.
19047
+ * The deletable set (the periodic `snapshot` filmstrip, the surplus per-edge
19048
+ * motion stills) and the keep set (`firstFrame`, rolling `lastFrame`,
19049
+ * `thumbnail`/`thumbnailSmall`, `keyFrame`/`keyFrameSmall`, the face/plate
19050
+ * buffers, gallery media, the CLIP `crop`) are distinguished by `kind` and by
19051
+ * nothing else, so sizing a deletion means summing per kind.
19052
+ *
19053
+ * ## Why `unaccounted*` exists
19054
+ *
19055
+ * `kinds` is enumerated from {@link MediaFileKindEnum} — the closed set the
19056
+ * writers use — and summed one kind at a time. `totalRows` / `totalBytes` come
19057
+ * from a SEPARATE unfiltered aggregate over the same rows, never from adding
19058
+ * `kinds` up. A row whose stored `kind` is not in the enum (written by a
19059
+ * retired code path, or by a version that knew a kind this one does not) would
19060
+ * otherwise vanish from the total silently, and an operator would delete
19061
+ * against a denominator smaller than the disk.
19062
+ *
19063
+ * `unaccountedRows` / `unaccountedBytes` are the difference. They are normally
19064
+ * zero; a non-zero value is a real finding and must be shown, not rounded away.
19065
+ */
19066
+ var EventMediaKindBreakdownSchema = object({
19067
+ /** Every media row in scope, from one unfiltered aggregate. */
19068
+ totalRows: number().int(),
19069
+ /** Every media byte in scope, from that same aggregate. */
19070
+ totalBytes: number().int(),
19071
+ /** Per-kind footprint, ordered by bytes descending. */
19072
+ kinds: array(EventMediaKindFootprintSchema).readonly(),
19073
+ /** `totalRows` minus the summed `kinds` rows — see the schema note. */
19074
+ unaccountedRows: number().int(),
19075
+ /** `totalBytes` minus the summed `kinds` bytes — see the schema note. */
19076
+ unaccountedBytes: number().int()
19077
+ });
19034
19078
  /** Per-kind counts returned by the event-prune / device-delete mutations. */
19035
19079
  var EventPruneCountsSchema = object({
19036
19080
  motion: number().int(),
@@ -19234,6 +19278,9 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
19234
19278
  }), TrackFlagsSchema, { kind: "mutation" }), method(object({}), EventStoreFootprintSchema, {
19235
19279
  kind: "query",
19236
19280
  auth: "admin"
19281
+ }), method(object({ deviceId: number().int().optional() }), EventMediaKindBreakdownSchema, {
19282
+ kind: "query",
19283
+ auth: "admin"
19237
19284
  }), method(object({
19238
19285
  olderThanMs: number(),
19239
19286
  reason: OpsLogReasonSchema.optional()
@@ -21185,6 +21232,20 @@ method(object({
21185
21232
  error: string().optional()
21186
21233
  }), { auth: "admin" }), method(_void(), array(ProviderListEntrySchema).readonly()), method(object({
21187
21234
  providerId: string(),
21235
+ /**
21236
+ * The location this config is an UNSAVED edit of, when there is one.
21237
+ *
21238
+ * `listLocations` replaces every declared secret with the redaction
21239
+ * sentinel, so the edit modal's form state holds the sentinel for any
21240
+ * credential the operator did not retype — and posting that here
21241
+ * without a way to resolve it makes the provider try to authenticate
21242
+ * as `__camstack_redacted__` and report the operator's own working
21243
+ * password as wrong. Given this id, the orchestrator restores each
21244
+ * sentinel from the stored config (same rule as `upsertLocation`)
21245
+ * before dispatching. Omitted by the "Add location" wizard, where
21246
+ * every value was typed just now and nothing is stored yet.
21247
+ */
21248
+ locationId: string().optional(),
21188
21249
  config: record(string(), unknown())
21189
21250
  }), object({
21190
21251
  ok: boolean(),
@@ -31858,6 +31919,12 @@ Object.freeze({
31858
31919
  addonId: null,
31859
31920
  access: "view"
31860
31921
  },
31922
+ "pipelineAnalytics.getEventMediaFootprintByKind": {
31923
+ capName: "pipeline-analytics",
31924
+ capScope: "device",
31925
+ addonId: null,
31926
+ access: "view"
31927
+ },
31861
31928
  "pipelineAnalytics.getEventStoreFootprint": {
31862
31929
  capName: "pipeline-analytics",
31863
31930
  capScope: "device",
@@ -35523,6 +35590,11 @@ Object.freeze({
35523
35590
  form: "single",
35524
35591
  optional: false
35525
35592
  }],
35593
+ "pipelineAnalytics.getEventMediaFootprintByKind": [{
35594
+ name: "deviceId",
35595
+ form: "single",
35596
+ optional: true
35597
+ }],
35526
35598
  "pipelineAnalytics.getGroup": [{
35527
35599
  name: "deviceId",
35528
35600
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-export-google",
3
- "version": "0.1.11",
3
+ "version": "0.1.12",
4
4
  "description": "Google Home export — hub-side smart-home fulfillment (SYNC / QUERY / EXECUTE / DISCONNECT) for the non-camera fleet, served over the hub's own OAuth account link. No Google credential is stored, sent or required.",
5
5
  "keywords": [
6
6
  "camstack",