@camstack/types 1.2.182 → 1.2.183

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/addon.js CHANGED
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_sleep = require("./sleep-B1ZwxAhh.js");
3
- const require_event_category = require("./event-category-BNJ9EE5B.js");
2
+ const require_sleep = require("./sleep-CfDqEZrs.js");
3
+ const require_event_category = require("./event-category-yW4s1MGD.js");
4
4
  const require_err_msg = require("./err-msg-COpsHMw2.js");
5
5
  //#region src/generated/cap-input-defaults.ts
6
6
  /**
package/dist/addon.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { D as adminUiCapability, E as DeviceType, G as scopeKey, H as ReadinessTimeoutError, M as expandCapMethods, R as nodePin, S as DEVICE_CHILDREN_BATCH_MAX, St as normalizeAddonInitResult, Tt as emitReadiness, V as ReadinessRegistry, a as asJsonObject, b as deviceOpsCapability, bt as DisposerChain, d as BOOT_RECOVERY_BACKOFF_MS, f as DEVICE_SCOPED_CAPS, h as createEventBusSliceSource, m as createDeviceProxy, p as isDeviceScopedCap, s as asString, t as sleep, u as parseJsonUnknown, vt as DATAPLANE_SECRET_HEADER, x as viewerUiCapability, xt as BaseAddon, z as readNodePin } from "./sleep-BnujYGPe.mjs";
2
- import { t as EventCategory } from "./event-category-DAXzJeTX.mjs";
1
+ import { D as adminUiCapability, E as DeviceType, G as scopeKey, H as ReadinessTimeoutError, M as expandCapMethods, R as nodePin, S as DEVICE_CHILDREN_BATCH_MAX, St as normalizeAddonInitResult, Tt as emitReadiness, V as ReadinessRegistry, a as asJsonObject, b as deviceOpsCapability, bt as DisposerChain, d as BOOT_RECOVERY_BACKOFF_MS, f as DEVICE_SCOPED_CAPS, h as createEventBusSliceSource, m as createDeviceProxy, p as isDeviceScopedCap, s as asString, t as sleep, u as parseJsonUnknown, vt as DATAPLANE_SECRET_HEADER, x as viewerUiCapability, xt as BaseAddon, z as readNodePin } from "./sleep-CnLyvg3w.mjs";
2
+ import { t as EventCategory } from "./event-category-ZyX6jcse.mjs";
3
3
  import { t as errMsg } from "./err-msg-IQTHeDzc.mjs";
4
4
  //#region src/generated/cap-input-defaults.ts
5
5
  /**
@@ -120,6 +120,22 @@ export declare const dataStoreProviderCapability: {
120
120
  }, z.core.$strip>, z.ZodObject<{
121
121
  id: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
122
122
  }, z.core.$strip>, "mutation">;
123
+ /**
124
+ * Make a slot hold this row, and answer with the id the row HAS. The
125
+ * engine half of `settings-store.upsert` — read that docblock for why the
126
+ * store needed a slot that is not the primary key (D482).
127
+ */
128
+ readonly upsert: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
129
+ namespace: z.ZodOptional<z.ZodString>;
130
+ collection: z.ZodString;
131
+ conflict: z.ZodReadonly<z.ZodArray<z.ZodString>>;
132
+ record: z.ZodObject<{
133
+ id: z.ZodOptional<z.ZodString>;
134
+ data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
135
+ }, z.core.$strip>;
136
+ }, z.core.$strip>, z.ZodObject<{
137
+ id: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
138
+ }, z.core.$strip>, "mutation">;
123
139
  /** Insert many records in ONE transaction. All or nothing. */
124
140
  readonly insertMany: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
125
141
  namespace: z.ZodOptional<z.ZodString>;
@@ -4,7 +4,7 @@ declare const IdentitySchema: z.ZodObject<{
4
4
  id: z.ZodString;
5
5
  name: z.ZodString;
6
6
  sampleCount: z.ZodNumber;
7
- coverMediaKey: z.ZodOptional<z.ZodString>;
7
+ coverMediaId: z.ZodOptional<z.ZodNumber>;
8
8
  coverBase64: z.ZodOptional<z.ZodString>;
9
9
  }, z.core.$strip>;
10
10
  export type Identity = z.infer<typeof IdentitySchema>;
@@ -37,7 +37,7 @@ declare const IdentitySampleAuditRowSchema: z.ZodObject<{
37
37
  detected: "detected";
38
38
  photo: "photo";
39
39
  }>;
40
- mediaKey: z.ZodOptional<z.ZodString>;
40
+ mediaId: z.ZodOptional<z.ZodNumber>;
41
41
  comparable: z.ZodBoolean;
42
42
  selfMean: z.ZodNullable<z.ZodNumber>;
43
43
  bestForeign: z.ZodOptional<z.ZodObject<{
@@ -64,7 +64,7 @@ declare const IdentitySampleAuditSchema: z.ZodObject<{
64
64
  detected: "detected";
65
65
  photo: "photo";
66
66
  }>;
67
- mediaKey: z.ZodOptional<z.ZodString>;
67
+ mediaId: z.ZodOptional<z.ZodNumber>;
68
68
  comparable: z.ZodBoolean;
69
69
  selfMean: z.ZodNullable<z.ZodNumber>;
70
70
  bestForeign: z.ZodOptional<z.ZodObject<{
@@ -92,7 +92,7 @@ declare const FaceInfoSchema: z.ZodObject<{
92
92
  w: z.ZodNumber;
93
93
  h: z.ZodNumber;
94
94
  }, z.core.$strip>>;
95
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
95
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
96
96
  bestMatchScore: z.ZodOptional<z.ZodNumber>;
97
97
  nativeFaceShortSidePx: z.ZodOptional<z.ZodNumber>;
98
98
  suggestedIdentityId: z.ZodOptional<z.ZodString>;
@@ -148,7 +148,7 @@ export declare const faceGalleryCapability: {
148
148
  id: z.ZodString;
149
149
  name: z.ZodString;
150
150
  sampleCount: z.ZodNumber;
151
- coverMediaKey: z.ZodOptional<z.ZodString>;
151
+ coverMediaId: z.ZodOptional<z.ZodNumber>;
152
152
  coverBase64: z.ZodOptional<z.ZodString>;
153
153
  }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
154
154
  readonly createIdentity: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
@@ -157,7 +157,7 @@ export declare const faceGalleryCapability: {
157
157
  id: z.ZodString;
158
158
  name: z.ZodString;
159
159
  sampleCount: z.ZodNumber;
160
- coverMediaKey: z.ZodOptional<z.ZodString>;
160
+ coverMediaId: z.ZodOptional<z.ZodNumber>;
161
161
  coverBase64: z.ZodOptional<z.ZodString>;
162
162
  }, z.core.$strip>, "mutation">;
163
163
  readonly renameIdentity: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
@@ -209,7 +209,7 @@ export declare const faceGalleryCapability: {
209
209
  detected: "detected";
210
210
  photo: "photo";
211
211
  }>;
212
- mediaKey: z.ZodOptional<z.ZodString>;
212
+ mediaId: z.ZodOptional<z.ZodNumber>;
213
213
  comparable: z.ZodBoolean;
214
214
  selfMean: z.ZodNullable<z.ZodNumber>;
215
215
  bestForeign: z.ZodOptional<z.ZodObject<{
@@ -261,7 +261,7 @@ export declare const faceGalleryCapability: {
261
261
  w: z.ZodNumber;
262
262
  h: z.ZodNumber;
263
263
  }, z.core.$strip>>;
264
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
264
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
265
265
  bestMatchScore: z.ZodOptional<z.ZodNumber>;
266
266
  nativeFaceShortSidePx: z.ZodOptional<z.ZodNumber>;
267
267
  suggestedIdentityId: z.ZodOptional<z.ZodString>;
@@ -286,7 +286,7 @@ export declare const faceGalleryCapability: {
286
286
  w: z.ZodNumber;
287
287
  h: z.ZodNumber;
288
288
  }, z.core.$strip>>;
289
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
289
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
290
290
  bestMatchScore: z.ZodOptional<z.ZodNumber>;
291
291
  nativeFaceShortSidePx: z.ZodOptional<z.ZodNumber>;
292
292
  suggestedIdentityId: z.ZodOptional<z.ZodString>;
@@ -295,7 +295,7 @@ export declare const faceGalleryCapability: {
295
295
  readonly getFaceMedia: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
296
296
  faceId: z.ZodString;
297
297
  }, z.core.$strip>, z.ZodReadonly<z.ZodArray<z.ZodObject<{
298
- key: z.ZodString;
298
+ mediaId: z.ZodNumber;
299
299
  kind: z.ZodString;
300
300
  url: z.ZodString;
301
301
  sizeBytes: z.ZodNumber;
@@ -468,7 +468,7 @@ declare const TrackSchema: z.ZodObject<{
468
468
  }>>;
469
469
  score: z.ZodOptional<z.ZodNumber>;
470
470
  }, z.core.$strip>;
471
- mediaKey: z.ZodString;
471
+ mediaId: z.ZodNumber;
472
472
  }, z.core.$strip>>>;
473
473
  zonesVisited: z.ZodReadonly<z.ZodArray<z.ZodString>>;
474
474
  zoneNames: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
@@ -637,8 +637,8 @@ declare const ObjectEventSchema: z.ZodObject<{
637
637
  }, z.core.$strip>>;
638
638
  frameWidth: z.ZodOptional<z.ZodNumber>;
639
639
  frameHeight: z.ZodOptional<z.ZodNumber>;
640
- mediaKey: z.ZodOptional<z.ZodString>;
641
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
640
+ mediaId: z.ZodOptional<z.ZodNumber>;
641
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
642
642
  mediaUrl: z.ZodOptional<z.ZodString>;
643
643
  importance: z.ZodOptional<z.ZodNumber>;
644
644
  label: z.ZodOptional<z.ZodString>;
@@ -724,7 +724,7 @@ export type MediaFileKind = z.infer<typeof MediaFileKindEnum>;
724
724
  * plus the bytes.
725
725
  */
726
726
  declare const MediaFileRefSchema: z.ZodObject<{
727
- key: z.ZodString;
727
+ mediaId: z.ZodNumber;
728
728
  kind: z.ZodEnum<{
729
729
  crop: "crop";
730
730
  snapshot: "snapshot";
@@ -771,7 +771,7 @@ export interface MediaFileBytes extends MediaFileRef {
771
771
  * hub-main's heap on the way past — for an `<img>` that would have cached it.
772
772
  *
773
773
  * `url` points at the `event-media` data plane
774
- * (`/addon/<addonId>/event-media/<storedKey>`), which serves the same blob
774
+ * (`/addon/<addonId>/event-media/m/<mediaId>` — D482), which serves the same blob
775
775
  * with an ETag and `Cache-Control: immutable`, honours conditional GETs, can
776
776
  * render a `?variant=thumb`, and streams. The hub gate in front of it requires
777
777
  * a bearer or the session cookie (`access: 'authenticated'`), so the bytes are
@@ -779,10 +779,13 @@ export interface MediaFileBytes extends MediaFileRef {
779
779
  * `data-plane-access.ts` for the rule and the one gap it does not close
780
780
  * (per-device scoping).
781
781
  *
782
- * The URL is built from the row's **stored** key, which is not always its
783
- * published `kind`: a track's face/plate crop is stored as `crop` under
782
+ * The URL is built from the row's own id, which since D482 says nothing about
783
+ * the row's owner or kind — and that is the point. The published `kind` is not
784
+ * the stored one (a track's face/plate crop is stored as `crop` under
784
785
  * `('face'|'plate', '<prefix>-<trackId>')` and published as
785
- * `faceCrop`/`plateCrop`. `MediaStore.getByKey` knows only the stored key.
786
+ * `faceCrop`/`plateCrop`), and under the old composite key the URL had to be
787
+ * taken from `row.key` verbatim or it 404'd exactly those two rows. An id
788
+ * cannot be mis-reconstructed, because there is nothing in it to reconstruct.
786
789
  *
787
790
  * ## `base64` is TRANSITIONAL and is going away
788
791
  *
@@ -795,7 +798,7 @@ export interface MediaFileBytes extends MediaFileRef {
795
798
  * `analytics-query-facade.ts`; nothing else reads it.
796
799
  */
797
800
  declare const MediaFileSchema: z.ZodObject<{
798
- key: z.ZodString;
801
+ mediaId: z.ZodNumber;
799
802
  kind: z.ZodEnum<{
800
803
  crop: "crop";
801
804
  snapshot: "snapshot";
@@ -832,7 +835,6 @@ export type MediaFile = z.infer<typeof MediaFileSchema>;
832
835
  * copy of a route — the embed, the viewer and the admin UI each grew one.
833
836
  */
834
837
  declare const MediaFileInfoSchema: z.ZodObject<{
835
- key: z.ZodString;
836
838
  timestamp: z.ZodNumber;
837
839
  kind: z.ZodEnum<{
838
840
  crop: "crop";
@@ -851,6 +853,7 @@ declare const MediaFileInfoSchema: z.ZodObject<{
851
853
  }>;
852
854
  url: z.ZodString;
853
855
  sizeBytes: z.ZodNumber;
856
+ mediaId: z.ZodNumber;
854
857
  }, z.core.$strip>;
855
858
  export type MediaFileInfo = z.infer<typeof MediaFileInfoSchema>;
856
859
  /**
@@ -972,7 +975,7 @@ export declare const RetrainTrackSchema: z.ZodObject<{
972
975
  export type RetrainTrack = z.infer<typeof RetrainTrackSchema>;
973
976
  /** A frame the picker may offer — an index row, no blob was read to produce it. */
974
977
  export declare const RetrainFrameCandidateSchema: z.ZodObject<{
975
- mediaKey: z.ZodString;
978
+ mediaId: z.ZodNumber;
976
979
  kind: z.ZodEnum<{
977
980
  crop: "crop";
978
981
  snapshot: "snapshot";
@@ -998,7 +1001,7 @@ export declare const RetrainFrameSchema: z.ZodObject<{
998
1001
  frameId: z.ZodString;
999
1002
  deviceId: z.ZodNumber;
1000
1003
  trackId: z.ZodString;
1001
- sourceMediaKey: z.ZodString;
1004
+ sourceMediaId: z.ZodNumber;
1002
1005
  sourceKind: z.ZodEnum<{
1003
1006
  crop: "crop";
1004
1007
  snapshot: "snapshot";
@@ -1031,7 +1034,7 @@ export declare const RetrainFrameSelectionSchema: z.ZodObject<{
1031
1034
  frameId: z.ZodString;
1032
1035
  deviceId: z.ZodNumber;
1033
1036
  trackId: z.ZodString;
1034
- sourceMediaKey: z.ZodString;
1037
+ sourceMediaId: z.ZodNumber;
1035
1038
  sourceKind: z.ZodEnum<{
1036
1039
  crop: "crop";
1037
1040
  snapshot: "snapshot";
@@ -1053,7 +1056,7 @@ export declare const RetrainFrameSelectionSchema: z.ZodObject<{
1053
1056
  copiedAt: z.ZodNumber;
1054
1057
  }, z.core.$strip>>>;
1055
1058
  refused: z.ZodReadonly<z.ZodArray<z.ZodObject<{
1056
- sourceMediaKey: z.ZodString;
1059
+ sourceMediaId: z.ZodNumber;
1057
1060
  reason: z.ZodEnum<{
1058
1061
  "source-missing": "source-missing";
1059
1062
  "unreadable-image": "unreadable-image";
@@ -1064,7 +1067,7 @@ export declare const RetrainFrameSelectionSchema: z.ZodObject<{
1064
1067
  export type RetrainFrameSelection = z.infer<typeof RetrainFrameSelectionSchema>;
1065
1068
  export declare const RetrainFrameListSchema: z.ZodObject<{
1066
1069
  candidates: z.ZodReadonly<z.ZodArray<z.ZodObject<{
1067
- mediaKey: z.ZodString;
1070
+ mediaId: z.ZodNumber;
1068
1071
  kind: z.ZodEnum<{
1069
1072
  crop: "crop";
1070
1073
  snapshot: "snapshot";
@@ -1088,7 +1091,7 @@ export declare const RetrainFrameListSchema: z.ZodObject<{
1088
1091
  frameId: z.ZodString;
1089
1092
  deviceId: z.ZodNumber;
1090
1093
  trackId: z.ZodString;
1091
- sourceMediaKey: z.ZodString;
1094
+ sourceMediaId: z.ZodNumber;
1092
1095
  sourceKind: z.ZodEnum<{
1093
1096
  crop: "crop";
1094
1097
  snapshot: "snapshot";
@@ -1109,7 +1112,7 @@ export declare const RetrainFrameListSchema: z.ZodObject<{
1109
1112
  height: z.ZodNumber;
1110
1113
  copiedAt: z.ZodNumber;
1111
1114
  }, z.core.$strip>>>;
1112
- autoPickMediaKey: z.ZodOptional<z.ZodString>;
1115
+ autoPickMediaId: z.ZodOptional<z.ZodNumber>;
1113
1116
  }, z.core.$strip>;
1114
1117
  export type RetrainFrameList = z.infer<typeof RetrainFrameListSchema>;
1115
1118
  /** What the operator asked the assist to look for. */
@@ -1210,9 +1213,11 @@ declare const RecentTracksQueryInput: z.ZodObject<{
1210
1213
  export type RecentTracksQuery = z.infer<typeof RecentTracksQueryInput>;
1211
1214
  /**
1212
1215
  * A Summary (D359): the per-camera session envelope that references tracks.
1213
- * `groupShotKey` is the media key of its group shot (`ownerKind: 'summary'`,
1214
- * served by the event-media plane by key), null until the first frame with a
1215
- * member visible has been materialised.
1216
+ * `groupShotMediaId` is the media ROW id of its group shot (`ownerKind:
1217
+ * 'summary'`, served by the event-media plane at `/m/<id>`), null until the
1218
+ * first frame with a member visible has been materialised (D482 — it was the
1219
+ * row's composite key, which embedded the owner and could name another table's
1220
+ * row once event ids became per-table rowids).
1216
1221
  */
1217
1222
  export declare const SummarySchema: z.ZodObject<{
1218
1223
  id: z.ZodString;
@@ -1221,7 +1226,7 @@ export declare const SummarySchema: z.ZodObject<{
1221
1226
  lastActiveAt: z.ZodNumber;
1222
1227
  sealedAt: z.ZodNullable<z.ZodNumber>;
1223
1228
  memberCount: z.ZodNumber;
1224
- groupShotKey: z.ZodNullable<z.ZodString>;
1229
+ groupShotMediaId: z.ZodNullable<z.ZodNumber>;
1225
1230
  }, z.core.$strip>;
1226
1231
  export type Summary = z.infer<typeof SummarySchema>;
1227
1232
  export declare const SUMMARIES_MAX_LIMIT = 200;
@@ -1234,7 +1239,7 @@ declare const SummariesPageSchema: z.ZodObject<{
1234
1239
  lastActiveAt: z.ZodNumber;
1235
1240
  sealedAt: z.ZodNullable<z.ZodNumber>;
1236
1241
  memberCount: z.ZodNumber;
1237
- groupShotKey: z.ZodNullable<z.ZodString>;
1242
+ groupShotMediaId: z.ZodNullable<z.ZodNumber>;
1238
1243
  }, z.core.$strip>>>;
1239
1244
  }, z.core.$strip>;
1240
1245
  export type SummariesPage = z.infer<typeof SummariesPageSchema>;
@@ -1246,7 +1251,7 @@ declare const SummaryDetailSchema: z.ZodObject<{
1246
1251
  lastActiveAt: z.ZodNumber;
1247
1252
  sealedAt: z.ZodNullable<z.ZodNumber>;
1248
1253
  memberCount: z.ZodNumber;
1249
- groupShotKey: z.ZodNullable<z.ZodString>;
1254
+ groupShotMediaId: z.ZodNullable<z.ZodNumber>;
1250
1255
  }, z.core.$strip>;
1251
1256
  trackIds: z.ZodReadonly<z.ZodArray<z.ZodString>>;
1252
1257
  }, z.core.$strip>;
@@ -1304,7 +1309,7 @@ declare const RecentTracksPageSchema: z.ZodObject<{
1304
1309
  }>>;
1305
1310
  score: z.ZodOptional<z.ZodNumber>;
1306
1311
  }, z.core.$strip>;
1307
- mediaKey: z.ZodString;
1312
+ mediaId: z.ZodNumber;
1308
1313
  }, z.core.$strip>>>;
1309
1314
  zonesVisited: z.ZodReadonly<z.ZodArray<z.ZodString>>;
1310
1315
  zoneNames: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
@@ -1550,8 +1555,8 @@ export declare const ScoredObjectEventSchema: z.ZodObject<{
1550
1555
  }, z.core.$strip>>;
1551
1556
  frameWidth: z.ZodOptional<z.ZodNumber>;
1552
1557
  frameHeight: z.ZodOptional<z.ZodNumber>;
1553
- mediaKey: z.ZodOptional<z.ZodString>;
1554
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
1558
+ mediaId: z.ZodOptional<z.ZodNumber>;
1559
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
1555
1560
  mediaUrl: z.ZodOptional<z.ZodString>;
1556
1561
  importance: z.ZodOptional<z.ZodNumber>;
1557
1562
  label: z.ZodOptional<z.ZodString>;
@@ -1788,7 +1793,7 @@ export declare const pipelineAnalyticsCapability: {
1788
1793
  }>>;
1789
1794
  score: z.ZodOptional<z.ZodNumber>;
1790
1795
  }, z.core.$strip>;
1791
- mediaKey: z.ZodString;
1796
+ mediaId: z.ZodNumber;
1792
1797
  }, z.core.$strip>>>;
1793
1798
  zonesVisited: z.ZodReadonly<z.ZodArray<z.ZodString>>;
1794
1799
  zoneNames: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
@@ -1897,7 +1902,7 @@ export declare const pipelineAnalyticsCapability: {
1897
1902
  }>>;
1898
1903
  score: z.ZodOptional<z.ZodNumber>;
1899
1904
  }, z.core.$strip>;
1900
- mediaKey: z.ZodString;
1905
+ mediaId: z.ZodNumber;
1901
1906
  }, z.core.$strip>>>;
1902
1907
  zonesVisited: z.ZodReadonly<z.ZodArray<z.ZodString>>;
1903
1908
  zoneNames: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
@@ -2035,7 +2040,7 @@ export declare const pipelineAnalyticsCapability: {
2035
2040
  }>>;
2036
2041
  score: z.ZodOptional<z.ZodNumber>;
2037
2042
  }, z.core.$strip>;
2038
- mediaKey: z.ZodString;
2043
+ mediaId: z.ZodNumber;
2039
2044
  }, z.core.$strip>>>;
2040
2045
  zonesVisited: z.ZodReadonly<z.ZodArray<z.ZodString>>;
2041
2046
  zoneNames: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
@@ -2169,7 +2174,7 @@ export declare const pipelineAnalyticsCapability: {
2169
2174
  }>>;
2170
2175
  score: z.ZodOptional<z.ZodNumber>;
2171
2176
  }, z.core.$strip>;
2172
- mediaKey: z.ZodString;
2177
+ mediaId: z.ZodNumber;
2173
2178
  }, z.core.$strip>>>;
2174
2179
  zonesVisited: z.ZodReadonly<z.ZodArray<z.ZodString>>;
2175
2180
  zoneNames: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
@@ -2239,7 +2244,7 @@ export declare const pipelineAnalyticsCapability: {
2239
2244
  lastActiveAt: z.ZodNumber;
2240
2245
  sealedAt: z.ZodNullable<z.ZodNumber>;
2241
2246
  memberCount: z.ZodNumber;
2242
- groupShotKey: z.ZodNullable<z.ZodString>;
2247
+ groupShotMediaId: z.ZodNullable<z.ZodNumber>;
2243
2248
  }, z.core.$strip>>>;
2244
2249
  }, z.core.$strip>, import("./capability-definition.js").CapabilityMethodKind>;
2245
2250
  /** One summary with its member track ids; `null` for an id nobody wrote. */
@@ -2253,7 +2258,7 @@ export declare const pipelineAnalyticsCapability: {
2253
2258
  lastActiveAt: z.ZodNumber;
2254
2259
  sealedAt: z.ZodNullable<z.ZodNumber>;
2255
2260
  memberCount: z.ZodNumber;
2256
- groupShotKey: z.ZodNullable<z.ZodString>;
2261
+ groupShotMediaId: z.ZodNullable<z.ZodNumber>;
2257
2262
  }, z.core.$strip>;
2258
2263
  trackIds: z.ZodReadonly<z.ZodArray<z.ZodString>>;
2259
2264
  }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
@@ -2333,8 +2338,8 @@ export declare const pipelineAnalyticsCapability: {
2333
2338
  }, z.core.$strip>>;
2334
2339
  frameWidth: z.ZodOptional<z.ZodNumber>;
2335
2340
  frameHeight: z.ZodOptional<z.ZodNumber>;
2336
- mediaKey: z.ZodOptional<z.ZodString>;
2337
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
2341
+ mediaId: z.ZodOptional<z.ZodNumber>;
2342
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
2338
2343
  mediaUrl: z.ZodOptional<z.ZodString>;
2339
2344
  importance: z.ZodOptional<z.ZodNumber>;
2340
2345
  label: z.ZodOptional<z.ZodString>;
@@ -3344,7 +3349,7 @@ export declare const pipelineAnalyticsCapability: {
3344
3349
  trackId: z.ZodString;
3345
3350
  }, z.core.$strip>, z.ZodObject<{
3346
3351
  candidates: z.ZodReadonly<z.ZodArray<z.ZodObject<{
3347
- mediaKey: z.ZodString;
3352
+ mediaId: z.ZodNumber;
3348
3353
  kind: z.ZodEnum<{
3349
3354
  crop: "crop";
3350
3355
  snapshot: "snapshot";
@@ -3368,7 +3373,7 @@ export declare const pipelineAnalyticsCapability: {
3368
3373
  frameId: z.ZodString;
3369
3374
  deviceId: z.ZodNumber;
3370
3375
  trackId: z.ZodString;
3371
- sourceMediaKey: z.ZodString;
3376
+ sourceMediaId: z.ZodNumber;
3372
3377
  sourceKind: z.ZodEnum<{
3373
3378
  crop: "crop";
3374
3379
  snapshot: "snapshot";
@@ -3389,7 +3394,7 @@ export declare const pipelineAnalyticsCapability: {
3389
3394
  height: z.ZodNumber;
3390
3395
  copiedAt: z.ZodNumber;
3391
3396
  }, z.core.$strip>>>;
3392
- autoPickMediaKey: z.ZodOptional<z.ZodString>;
3397
+ autoPickMediaId: z.ZodOptional<z.ZodNumber>;
3393
3398
  }, z.core.$strip>, "query">;
3394
3399
  /**
3395
3400
  * COPY-ON-SELECT — the write that makes `trained` safe to evict.
@@ -3408,13 +3413,13 @@ export declare const pipelineAnalyticsCapability: {
3408
3413
  readonly selectRetrainFrames: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
3409
3414
  deviceId: z.ZodNumber;
3410
3415
  trackId: z.ZodString;
3411
- mediaKeys: z.ZodArray<z.ZodString>;
3416
+ mediaIds: z.ZodArray<z.ZodNumber>;
3412
3417
  }, z.core.$strip>, z.ZodObject<{
3413
3418
  copied: z.ZodReadonly<z.ZodArray<z.ZodObject<{
3414
3419
  frameId: z.ZodString;
3415
3420
  deviceId: z.ZodNumber;
3416
3421
  trackId: z.ZodString;
3417
- sourceMediaKey: z.ZodString;
3422
+ sourceMediaId: z.ZodNumber;
3418
3423
  sourceKind: z.ZodEnum<{
3419
3424
  crop: "crop";
3420
3425
  snapshot: "snapshot";
@@ -3436,7 +3441,7 @@ export declare const pipelineAnalyticsCapability: {
3436
3441
  copiedAt: z.ZodNumber;
3437
3442
  }, z.core.$strip>>>;
3438
3443
  refused: z.ZodReadonly<z.ZodArray<z.ZodObject<{
3439
- sourceMediaKey: z.ZodString;
3444
+ sourceMediaId: z.ZodNumber;
3440
3445
  reason: z.ZodEnum<{
3441
3446
  "source-missing": "source-missing";
3442
3447
  "unreadable-image": "unreadable-image";
@@ -3800,8 +3805,31 @@ export declare const pipelineAnalyticsCapability: {
3800
3805
  }, z.core.$strip>, z.ZodObject<{
3801
3806
  url: z.ZodString;
3802
3807
  }, z.core.$strip>, "query">;
3808
+ /**
3809
+ * The media an EVENT owns.
3810
+ *
3811
+ * `ownerType` is REQUIRED, and that is the whole correction (D482). An
3812
+ * event is a row in ONE of three tables, and since D474 each numbers from
3813
+ * 1 independently: `motion:101314` and `object:101314` both exist. This
3814
+ * method took a bare `eventId` and the provider probed motion → object →
3815
+ * audio, stopping at the first hit — so on the live hub, where object
3816
+ * events own no media of their own and 299 883 of 300 559 media rows are
3817
+ * motion-owned, EVERY object event resolved to its motion namesake. A
3818
+ * track from 17:34 on camera 615 was served a snapshot from 22:35 eleven
3819
+ * days earlier, silently.
3820
+ *
3821
+ * D476 had already disambiguated the KEY (`motion:` vs `object:`); this is
3822
+ * the API catching up to it. Naming the table is not a "qualification" of
3823
+ * the ambiguity — a listing BY OWNER has no address to make surrogate: the
3824
+ * owner IS (table, id), and half of it is not a question.
3825
+ */
3803
3826
  readonly getEventMedia: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
3804
- eventId: z.ZodString;
3827
+ ownerType: z.ZodEnum<{
3828
+ motion: "motion";
3829
+ object: "object";
3830
+ audio: "audio";
3831
+ }>;
3832
+ eventId: z.ZodNumber;
3805
3833
  kind: z.ZodOptional<z.ZodEnum<{
3806
3834
  crop: "crop";
3807
3835
  snapshot: "snapshot";
@@ -3819,7 +3847,7 @@ export declare const pipelineAnalyticsCapability: {
3819
3847
  }>>;
3820
3848
  deviceId: z.ZodNumber;
3821
3849
  }, z.core.$strip>, z.ZodReadonly<z.ZodArray<z.ZodObject<{
3822
- key: z.ZodString;
3850
+ mediaId: z.ZodNumber;
3823
3851
  kind: z.ZodEnum<{
3824
3852
  crop: "crop";
3825
3853
  snapshot: "snapshot";
@@ -3863,7 +3891,7 @@ export declare const pipelineAnalyticsCapability: {
3863
3891
  }>>>;
3864
3892
  deviceId: z.ZodNumber;
3865
3893
  }, z.core.$strip>, z.ZodReadonly<z.ZodArray<z.ZodObject<{
3866
- key: z.ZodString;
3894
+ mediaId: z.ZodNumber;
3867
3895
  kind: z.ZodEnum<{
3868
3896
  crop: "crop";
3869
3897
  snapshot: "snapshot";
@@ -3903,7 +3931,6 @@ export declare const pipelineAnalyticsCapability: {
3903
3931
  trackId: z.ZodString;
3904
3932
  deviceId: z.ZodNumber;
3905
3933
  }, z.core.$strip>, z.ZodReadonly<z.ZodArray<z.ZodObject<{
3906
- key: z.ZodString;
3907
3934
  timestamp: z.ZodNumber;
3908
3935
  kind: z.ZodEnum<{
3909
3936
  crop: "crop";
@@ -3922,6 +3949,7 @@ export declare const pipelineAnalyticsCapability: {
3922
3949
  }>;
3923
3950
  url: z.ZodString;
3924
3951
  sizeBytes: z.ZodNumber;
3952
+ mediaId: z.ZodNumber;
3925
3953
  }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
3926
3954
  /**
3927
3955
  * What media an EVENT has, without any of it — the twin `getEventMedia`
@@ -3936,14 +3964,20 @@ export declare const pipelineAnalyticsCapability: {
3936
3964
  * the live hub: one event's `fullFrameBoxed` is 2 824 077 B, base64'd to
3937
3965
  * ~3.8 MB, allocated whole in hub-main's heap, for a list of keys.
3938
3966
  *
3939
- * Same `deviceId` authorization subject as `getEventMedia`, and the same
3940
- * rows — this is a projection of that method, never a different question.
3967
+ * Same `deviceId` authorization subject as `getEventMedia`, the same
3968
+ * REQUIRED `ownerType` (read that method's docblock for the night-time
3969
+ * thumbnail this closes — D482), and the same rows: this is a projection
3970
+ * of that method, never a different question.
3941
3971
  */
3942
3972
  readonly listEventMedia: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
3943
- eventId: z.ZodString;
3973
+ ownerType: z.ZodEnum<{
3974
+ motion: "motion";
3975
+ object: "object";
3976
+ audio: "audio";
3977
+ }>;
3978
+ eventId: z.ZodNumber;
3944
3979
  deviceId: z.ZodNumber;
3945
3980
  }, z.core.$strip>, z.ZodReadonly<z.ZodArray<z.ZodObject<{
3946
- key: z.ZodString;
3947
3981
  timestamp: z.ZodNumber;
3948
3982
  kind: z.ZodEnum<{
3949
3983
  crop: "crop";
@@ -3962,6 +3996,7 @@ export declare const pipelineAnalyticsCapability: {
3962
3996
  }>;
3963
3997
  url: z.ZodString;
3964
3998
  sizeBytes: z.ZodNumber;
3999
+ mediaId: z.ZodNumber;
3965
4000
  }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
3966
4001
  /**
3967
4002
  * Search object events by text query using CLIP cosine similarity.
@@ -4011,8 +4046,8 @@ export declare const pipelineAnalyticsCapability: {
4011
4046
  }, z.core.$strip>>;
4012
4047
  frameWidth: z.ZodOptional<z.ZodNumber>;
4013
4048
  frameHeight: z.ZodOptional<z.ZodNumber>;
4014
- mediaKey: z.ZodOptional<z.ZodString>;
4015
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
4049
+ mediaId: z.ZodOptional<z.ZodNumber>;
4050
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
4016
4051
  mediaUrl: z.ZodOptional<z.ZodString>;
4017
4052
  importance: z.ZodOptional<z.ZodNumber>;
4018
4053
  label: z.ZodOptional<z.ZodString>;
@@ -4,7 +4,7 @@ declare const VehicleSchema: z.ZodObject<{
4
4
  id: z.ZodString;
5
5
  name: z.ZodString;
6
6
  sampleCount: z.ZodNumber;
7
- coverMediaKey: z.ZodOptional<z.ZodString>;
7
+ coverMediaId: z.ZodOptional<z.ZodNumber>;
8
8
  coverBase64: z.ZodOptional<z.ZodString>;
9
9
  }, z.core.$strip>;
10
10
  export type Vehicle = z.infer<typeof VehicleSchema>;
@@ -34,7 +34,7 @@ declare const PlateInfoSchema: z.ZodObject<{
34
34
  w: z.ZodNumber;
35
35
  h: z.ZodNumber;
36
36
  }, z.core.$strip>>;
37
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
37
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
38
38
  base64: z.ZodOptional<z.ZodString>;
39
39
  cropUrl: z.ZodOptional<z.ZodString>;
40
40
  }, z.core.$strip>;
@@ -73,7 +73,7 @@ export declare const plateGalleryCapability: {
73
73
  w: z.ZodNumber;
74
74
  h: z.ZodNumber;
75
75
  }, z.core.$strip>>;
76
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
76
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
77
77
  base64: z.ZodOptional<z.ZodString>;
78
78
  cropUrl: z.ZodOptional<z.ZodString>;
79
79
  }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
@@ -97,14 +97,14 @@ export declare const plateGalleryCapability: {
97
97
  w: z.ZodNumber;
98
98
  h: z.ZodNumber;
99
99
  }, z.core.$strip>>;
100
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
100
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
101
101
  base64: z.ZodOptional<z.ZodString>;
102
102
  cropUrl: z.ZodOptional<z.ZodString>;
103
103
  }, z.core.$strip>>, import("./capability-definition.js").CapabilityMethodKind>;
104
104
  readonly getPlateMedia: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
105
105
  plateId: z.ZodString;
106
106
  }, z.core.$strip>, z.ZodReadonly<z.ZodArray<z.ZodObject<{
107
- key: z.ZodString;
107
+ mediaId: z.ZodNumber;
108
108
  kind: z.ZodString;
109
109
  url: z.ZodString;
110
110
  sizeBytes: z.ZodNumber;
@@ -133,7 +133,7 @@ export declare const plateGalleryCapability: {
133
133
  w: z.ZodNumber;
134
134
  h: z.ZodNumber;
135
135
  }, z.core.$strip>>;
136
- keyFrameMediaKey: z.ZodOptional<z.ZodString>;
136
+ keyFrameMediaId: z.ZodOptional<z.ZodNumber>;
137
137
  base64: z.ZodOptional<z.ZodString>;
138
138
  cropUrl: z.ZodOptional<z.ZodString>;
139
139
  }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
@@ -163,7 +163,7 @@ export declare const plateGalleryCapability: {
163
163
  id: z.ZodString;
164
164
  name: z.ZodString;
165
165
  sampleCount: z.ZodNumber;
166
- coverMediaKey: z.ZodOptional<z.ZodString>;
166
+ coverMediaId: z.ZodOptional<z.ZodNumber>;
167
167
  coverBase64: z.ZodOptional<z.ZodString>;
168
168
  }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
169
169
  readonly createVehicle: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
@@ -172,7 +172,7 @@ export declare const plateGalleryCapability: {
172
172
  id: z.ZodString;
173
173
  name: z.ZodString;
174
174
  sampleCount: z.ZodNumber;
175
- coverMediaKey: z.ZodOptional<z.ZodString>;
175
+ coverMediaId: z.ZodOptional<z.ZodNumber>;
176
176
  coverBase64: z.ZodOptional<z.ZodString>;
177
177
  }, z.core.$strip>, "mutation">;
178
178
  readonly renameVehicle: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{