@awarevue/api-types 2.0.43 → 2.0.45

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.
@@ -6,9 +6,10 @@ export declare const sMediaSearchArgs: z.ZodObject<{
6
6
  q: z.ZodOptional<z.ZodString>;
7
7
  similarTo: z.ZodOptional<z.ZodOptional<z.ZodString>>;
8
8
  label: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
9
+ subLabel: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
9
10
  timeFrom: z.ZodOptional<z.ZodNumber>;
10
11
  timeTo: z.ZodOptional<z.ZodNumber>;
11
- sortBy: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"time_asc">, z.ZodLiteral<"time_desc">]>>;
12
+ sortBy: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"time_asc">, z.ZodLiteral<"time_desc">, z.ZodLiteral<"relevance">]>>;
12
13
  }, "strip", z.ZodTypeAny, {
13
14
  label?: string[] | undefined;
14
15
  q?: string | undefined;
@@ -17,7 +18,8 @@ export declare const sMediaSearchArgs: z.ZodObject<{
17
18
  timeFrom?: number | undefined;
18
19
  timeTo?: number | undefined;
19
20
  similarTo?: string | undefined;
20
- sortBy?: "time_asc" | "time_desc" | undefined;
21
+ subLabel?: string[] | undefined;
22
+ sortBy?: "time_asc" | "time_desc" | "relevance" | undefined;
21
23
  }, {
22
24
  label?: string[] | undefined;
23
25
  q?: string | undefined;
@@ -26,7 +28,8 @@ export declare const sMediaSearchArgs: z.ZodObject<{
26
28
  timeFrom?: number | undefined;
27
29
  timeTo?: number | undefined;
28
30
  similarTo?: string | undefined;
29
- sortBy?: "time_asc" | "time_desc" | undefined;
31
+ subLabel?: string[] | undefined;
32
+ sortBy?: "time_asc" | "time_desc" | "relevance" | undefined;
30
33
  }>;
31
34
  export declare const sMediaSearchMatch: z.ZodObject<{
32
35
  relevance: z.ZodNumber;
@@ -35,6 +38,7 @@ export declare const sMediaSearchMatch: z.ZodObject<{
35
38
  provider: z.ZodString;
36
39
  probability: z.ZodNumber;
37
40
  objectKind: z.ZodString;
41
+ subLabel: z.ZodString;
38
42
  startTime: z.ZodNumber;
39
43
  endTime: z.ZodNullable<z.ZodNumber>;
40
44
  }, "strip", z.ZodTypeAny, {
@@ -46,6 +50,7 @@ export declare const sMediaSearchMatch: z.ZodObject<{
46
50
  probability: number;
47
51
  providerAssignedRef: string;
48
52
  relevance: number;
53
+ subLabel: string;
49
54
  }, {
50
55
  endTime: number | null;
51
56
  startTime: number;
@@ -55,6 +60,7 @@ export declare const sMediaSearchMatch: z.ZodObject<{
55
60
  probability: number;
56
61
  providerAssignedRef: string;
57
62
  relevance: number;
63
+ subLabel: string;
58
64
  }>;
59
65
  export declare const sMediaSearchResponse: z.ZodArray<z.ZodObject<{
60
66
  relevance: z.ZodNumber;
@@ -63,6 +69,7 @@ export declare const sMediaSearchResponse: z.ZodArray<z.ZodObject<{
63
69
  provider: z.ZodString;
64
70
  probability: z.ZodNumber;
65
71
  objectKind: z.ZodString;
72
+ subLabel: z.ZodString;
66
73
  startTime: z.ZodNumber;
67
74
  endTime: z.ZodNullable<z.ZodNumber>;
68
75
  }, "strip", z.ZodTypeAny, {
@@ -74,6 +81,7 @@ export declare const sMediaSearchResponse: z.ZodArray<z.ZodObject<{
74
81
  probability: number;
75
82
  providerAssignedRef: string;
76
83
  relevance: number;
84
+ subLabel: string;
77
85
  }, {
78
86
  endTime: number | null;
79
87
  startTime: number;
@@ -83,6 +91,7 @@ export declare const sMediaSearchResponse: z.ZodArray<z.ZodObject<{
83
91
  probability: number;
84
92
  providerAssignedRef: string;
85
93
  relevance: number;
94
+ subLabel: string;
86
95
  }>, "many">;
87
96
  export type MediaSearchArgs = z.infer<typeof sMediaSearchArgs>;
88
97
  export type MediaSearchMatch = z.infer<typeof sMediaSearchMatch>;
@@ -164,6 +173,148 @@ export declare const sObjectLabelsArgs: z.ZodObject<{}, "strip", z.ZodTypeAny, {
164
173
  export type ObjectLabelsArgs = z.infer<typeof sObjectLabelsArgs>;
165
174
  export declare const sObjectLabelResponse: z.ZodArray<z.ZodString, "many">;
166
175
  export type ObjectLabelsResponse = z.infer<typeof sObjectLabelResponse>;
176
+ export declare const QUERY_MEDIA_FACES = "cctv:media-faces";
177
+ export declare const sMediaFacesArgs: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
178
+ export type MediaFacesArgs = z.infer<typeof sMediaFacesArgs>;
179
+ export declare const sMediaFacesResponse: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>;
180
+ export type MediaFacesResponse = z.infer<typeof sMediaFacesResponse>;
181
+ export declare const QUERY_MEDIA_FACE_PEOPLE = "cctv:media-face-people";
182
+ export declare const sMediaFacePeopleArgs: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
183
+ export type MediaFacePeopleArgs = z.infer<typeof sMediaFacePeopleArgs>;
184
+ export declare const sMediaFacePeopleResponse: z.ZodArray<z.ZodString, "many">;
185
+ export type MediaFacePeopleResponse = z.infer<typeof sMediaFacePeopleResponse>;
186
+ export declare const QUERY_MEDIA_FACE_PERSON_CREATE = "cctv:media-face-person-create";
187
+ export declare const sMediaFacePersonCreateArgs: z.ZodObject<{
188
+ id: z.ZodString;
189
+ }, "strip", z.ZodTypeAny, {
190
+ id: string;
191
+ }, {
192
+ id: string;
193
+ }>;
194
+ export type MediaFacePersonCreateArgs = z.infer<typeof sMediaFacePersonCreateArgs>;
195
+ export declare const sMediaFacePersonCreateResponse: z.ZodObject<{
196
+ success: z.ZodBoolean;
197
+ message: z.ZodString;
198
+ }, "strip", z.ZodTypeAny, {
199
+ message: string;
200
+ success: boolean;
201
+ }, {
202
+ message: string;
203
+ success: boolean;
204
+ }>;
205
+ export type MediaFacePersonCreateResponse = z.infer<typeof sMediaFacePersonCreateResponse>;
206
+ export declare const QUERY_MEDIA_FACE_PERSON_DELETE = "cctv:media-face-person-delete";
207
+ export declare const sMediaFacePersonDeleteArgs: z.ZodObject<{
208
+ id: z.ZodString;
209
+ }, "strip", z.ZodTypeAny, {
210
+ id: string;
211
+ }, {
212
+ id: string;
213
+ }>;
214
+ export type MediaFacePersonDeleteArgs = z.infer<typeof sMediaFacePersonDeleteArgs>;
215
+ export declare const sMediaFacePersonDeleteResponse: z.ZodObject<{
216
+ success: z.ZodBoolean;
217
+ message: z.ZodString;
218
+ }, "strip", z.ZodTypeAny, {
219
+ message: string;
220
+ success: boolean;
221
+ }, {
222
+ message: string;
223
+ success: boolean;
224
+ }>;
225
+ export type MediaFacePersonDeleteResponse = z.infer<typeof sMediaFacePersonDeleteResponse>;
226
+ export declare const QUERY_MEDIA_FACE_PERSON_ADD = "cctv:media-face-person-add";
227
+ export declare const sMediaFacePersonAddArgs: z.ZodObject<{
228
+ id: z.ZodString;
229
+ image: z.ZodString;
230
+ }, "strip", z.ZodTypeAny, {
231
+ id: string;
232
+ image: string;
233
+ }, {
234
+ id: string;
235
+ image: string;
236
+ }>;
237
+ export type MediaFacePersonAddArgs = z.infer<typeof sMediaFacePersonAddArgs>;
238
+ export declare const sMediaFacePersonAddResponse: z.ZodObject<{
239
+ success: z.ZodBoolean;
240
+ message: z.ZodString;
241
+ }, "strip", z.ZodTypeAny, {
242
+ message: string;
243
+ success: boolean;
244
+ }, {
245
+ message: string;
246
+ success: boolean;
247
+ }>;
248
+ export type MediaFacePersonAddResponse = z.infer<typeof sMediaFacePersonAddResponse>;
249
+ export declare const QUERY_MEDIA_FACE_PERSON_REMOVE = "cctv:media-face-person-remove";
250
+ export declare const sMediaFacePersonRemoveArgs: z.ZodObject<{
251
+ id: z.ZodString;
252
+ image: z.ZodString;
253
+ }, "strip", z.ZodTypeAny, {
254
+ id: string;
255
+ image: string;
256
+ }, {
257
+ id: string;
258
+ image: string;
259
+ }>;
260
+ export type MediaFacePersonRemoveArgs = z.infer<typeof sMediaFacePersonRemoveArgs>;
261
+ export declare const sMediaFacePersonRemoveResponse: z.ZodObject<{
262
+ success: z.ZodBoolean;
263
+ message: z.ZodString;
264
+ }, "strip", z.ZodTypeAny, {
265
+ message: string;
266
+ success: boolean;
267
+ }, {
268
+ message: string;
269
+ success: boolean;
270
+ }>;
271
+ export type MediaFacePersonRemoveResponse = z.infer<typeof sMediaFacePersonRemoveResponse>;
272
+ export declare const QUERY_MEDIA_FACE_IMAGE = "cctv:media-face-image";
273
+ export declare const sMediaFaceImageArgs: z.ZodObject<{
274
+ id: z.ZodString;
275
+ imageId: z.ZodString;
276
+ }, "strip", z.ZodTypeAny, {
277
+ id: string;
278
+ imageId: string;
279
+ }, {
280
+ id: string;
281
+ imageId: string;
282
+ }>;
283
+ export type MediaFaceImageArgs = z.infer<typeof sMediaFaceImageArgs>;
284
+ export declare const sMediaFaceImageResponse: z.ZodNullable<z.ZodObject<{
285
+ mimeType: z.ZodString;
286
+ data: z.ZodString;
287
+ }, "strip", z.ZodTypeAny, {
288
+ data: string;
289
+ mimeType: string;
290
+ }, {
291
+ data: string;
292
+ mimeType: string;
293
+ }>>;
294
+ export type MediaFaceImageResponse = z.infer<typeof sMediaFaceImageResponse>;
295
+ export declare const QUERY_MEDIA_FACE_TRAIN = "cctv:media-face-train";
296
+ export declare const sMediaFaceTrainArgs: z.ZodObject<{
297
+ id: z.ZodString;
298
+ imageId: z.ZodString;
299
+ }, "strip", z.ZodTypeAny, {
300
+ id: string;
301
+ imageId: string;
302
+ }, {
303
+ id: string;
304
+ imageId: string;
305
+ }>;
306
+ export type MediaFaceTrainArgs = z.infer<typeof sMediaFaceTrainArgs>;
307
+ export declare const sMediaFaceTrainResponse: z.ZodObject<{
308
+ success: z.ZodBoolean;
309
+ message: z.ZodString;
310
+ }, "strip", z.ZodTypeAny, {
311
+ message: string;
312
+ success: boolean;
313
+ }, {
314
+ message: string;
315
+ success: boolean;
316
+ }>;
317
+ export type MediaFaceTrainResponse = z.infer<typeof sMediaFaceTrainResponse>;
167
318
  export declare const nvrAnalyticsRequestSchemas: {
168
319
  readonly "cctv:media-search": z.ZodObject<{
169
320
  devices: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodAny, "many">>>;
@@ -171,9 +322,10 @@ export declare const nvrAnalyticsRequestSchemas: {
171
322
  q: z.ZodOptional<z.ZodString>;
172
323
  similarTo: z.ZodOptional<z.ZodOptional<z.ZodString>>;
173
324
  label: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
325
+ subLabel: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
174
326
  timeFrom: z.ZodOptional<z.ZodNumber>;
175
327
  timeTo: z.ZodOptional<z.ZodNumber>;
176
- sortBy: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"time_asc">, z.ZodLiteral<"time_desc">]>>;
328
+ sortBy: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"time_asc">, z.ZodLiteral<"time_desc">, z.ZodLiteral<"relevance">]>>;
177
329
  }, "strip", z.ZodTypeAny, {
178
330
  label?: string[] | undefined;
179
331
  q?: string | undefined;
@@ -182,7 +334,8 @@ export declare const nvrAnalyticsRequestSchemas: {
182
334
  timeFrom?: number | undefined;
183
335
  timeTo?: number | undefined;
184
336
  similarTo?: string | undefined;
185
- sortBy?: "time_asc" | "time_desc" | undefined;
337
+ subLabel?: string[] | undefined;
338
+ sortBy?: "time_asc" | "time_desc" | "relevance" | undefined;
186
339
  }, {
187
340
  label?: string[] | undefined;
188
341
  q?: string | undefined;
@@ -191,7 +344,8 @@ export declare const nvrAnalyticsRequestSchemas: {
191
344
  timeFrom?: number | undefined;
192
345
  timeTo?: number | undefined;
193
346
  similarTo?: string | undefined;
194
- sortBy?: "time_asc" | "time_desc" | undefined;
347
+ subLabel?: string[] | undefined;
348
+ sortBy?: "time_asc" | "time_desc" | "relevance" | undefined;
195
349
  }>;
196
350
  readonly "cctv:scene-preview-clip": z.ZodObject<{
197
351
  providerAssignedRef: z.ZodString;
@@ -227,6 +381,62 @@ export declare const nvrAnalyticsRequestSchemas: {
227
381
  providerAssignedRef: string;
228
382
  }>;
229
383
  readonly "cctv:object-labels": z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
384
+ readonly "cctv:media-faces": z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
385
+ readonly "cctv:media-face-people": z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
386
+ readonly "cctv:media-face-person-create": z.ZodObject<{
387
+ id: z.ZodString;
388
+ }, "strip", z.ZodTypeAny, {
389
+ id: string;
390
+ }, {
391
+ id: string;
392
+ }>;
393
+ readonly "cctv:media-face-person-delete": z.ZodObject<{
394
+ id: z.ZodString;
395
+ }, "strip", z.ZodTypeAny, {
396
+ id: string;
397
+ }, {
398
+ id: string;
399
+ }>;
400
+ readonly "cctv:media-face-person-add": z.ZodObject<{
401
+ id: z.ZodString;
402
+ image: z.ZodString;
403
+ }, "strip", z.ZodTypeAny, {
404
+ id: string;
405
+ image: string;
406
+ }, {
407
+ id: string;
408
+ image: string;
409
+ }>;
410
+ readonly "cctv:media-face-person-remove": z.ZodObject<{
411
+ id: z.ZodString;
412
+ image: z.ZodString;
413
+ }, "strip", z.ZodTypeAny, {
414
+ id: string;
415
+ image: string;
416
+ }, {
417
+ id: string;
418
+ image: string;
419
+ }>;
420
+ readonly "cctv:media-face-image": z.ZodObject<{
421
+ id: z.ZodString;
422
+ imageId: z.ZodString;
423
+ }, "strip", z.ZodTypeAny, {
424
+ id: string;
425
+ imageId: string;
426
+ }, {
427
+ id: string;
428
+ imageId: string;
429
+ }>;
430
+ readonly "cctv:media-face-train": z.ZodObject<{
431
+ id: z.ZodString;
432
+ imageId: z.ZodString;
433
+ }, "strip", z.ZodTypeAny, {
434
+ id: string;
435
+ imageId: string;
436
+ }, {
437
+ id: string;
438
+ imageId: string;
439
+ }>;
230
440
  };
231
441
  export declare const nvrAnalyticsResponseSchemas: {
232
442
  readonly "cctv:media-search": z.ZodArray<z.ZodObject<{
@@ -236,6 +446,7 @@ export declare const nvrAnalyticsResponseSchemas: {
236
446
  provider: z.ZodString;
237
447
  probability: z.ZodNumber;
238
448
  objectKind: z.ZodString;
449
+ subLabel: z.ZodString;
239
450
  startTime: z.ZodNumber;
240
451
  endTime: z.ZodNullable<z.ZodNumber>;
241
452
  }, "strip", z.ZodTypeAny, {
@@ -247,6 +458,7 @@ export declare const nvrAnalyticsResponseSchemas: {
247
458
  probability: number;
248
459
  providerAssignedRef: string;
249
460
  relevance: number;
461
+ subLabel: string;
250
462
  }, {
251
463
  endTime: number | null;
252
464
  startTime: number;
@@ -256,6 +468,7 @@ export declare const nvrAnalyticsResponseSchemas: {
256
468
  probability: number;
257
469
  providerAssignedRef: string;
258
470
  relevance: number;
471
+ subLabel: string;
259
472
  }>, "many">;
260
473
  readonly "cctv:scene-preview-clip": z.ZodNullable<z.ZodObject<{
261
474
  mimeType: z.ZodString;
@@ -288,6 +501,68 @@ export declare const nvrAnalyticsResponseSchemas: {
288
501
  mimeType: string;
289
502
  }>>;
290
503
  readonly "cctv:object-labels": z.ZodArray<z.ZodString, "many">;
504
+ readonly "cctv:media-faces": z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>;
505
+ readonly "cctv:media-face-people": z.ZodArray<z.ZodString, "many">;
506
+ readonly "cctv:media-face-person-create": z.ZodObject<{
507
+ success: z.ZodBoolean;
508
+ message: z.ZodString;
509
+ }, "strip", z.ZodTypeAny, {
510
+ message: string;
511
+ success: boolean;
512
+ }, {
513
+ message: string;
514
+ success: boolean;
515
+ }>;
516
+ readonly "cctv:media-face-person-delete": z.ZodObject<{
517
+ success: z.ZodBoolean;
518
+ message: z.ZodString;
519
+ }, "strip", z.ZodTypeAny, {
520
+ message: string;
521
+ success: boolean;
522
+ }, {
523
+ message: string;
524
+ success: boolean;
525
+ }>;
526
+ readonly "cctv:media-face-person-add": z.ZodObject<{
527
+ success: z.ZodBoolean;
528
+ message: z.ZodString;
529
+ }, "strip", z.ZodTypeAny, {
530
+ message: string;
531
+ success: boolean;
532
+ }, {
533
+ message: string;
534
+ success: boolean;
535
+ }>;
536
+ readonly "cctv:media-face-person-remove": z.ZodObject<{
537
+ success: z.ZodBoolean;
538
+ message: z.ZodString;
539
+ }, "strip", z.ZodTypeAny, {
540
+ message: string;
541
+ success: boolean;
542
+ }, {
543
+ message: string;
544
+ success: boolean;
545
+ }>;
546
+ readonly "cctv:media-face-image": z.ZodNullable<z.ZodObject<{
547
+ mimeType: z.ZodString;
548
+ data: z.ZodString;
549
+ }, "strip", z.ZodTypeAny, {
550
+ data: string;
551
+ mimeType: string;
552
+ }, {
553
+ data: string;
554
+ mimeType: string;
555
+ }>>;
556
+ readonly "cctv:media-face-train": z.ZodObject<{
557
+ success: z.ZodBoolean;
558
+ message: z.ZodString;
559
+ }, "strip", z.ZodTypeAny, {
560
+ message: string;
561
+ success: boolean;
562
+ }, {
563
+ message: string;
564
+ success: boolean;
565
+ }>;
291
566
  };
292
567
  export type NvrAnalyticsQueryRequestMap = {
293
568
  [QUERY_MEDIA_SEARCH]: MediaSearchArgs;
@@ -295,6 +570,14 @@ export type NvrAnalyticsQueryRequestMap = {
295
570
  [QUERY_OBJECT_SNAPSHOT]: ObjectSnapshotArgs;
296
571
  [QUERY_OBJECT_THUMBNAIL]: ObjectThumbnailArgs;
297
572
  [QUERY_OBJECT_LABELS]: ObjectLabelsArgs;
573
+ [QUERY_MEDIA_FACES]: MediaFacesArgs;
574
+ [QUERY_MEDIA_FACE_PEOPLE]: MediaFacePeopleArgs;
575
+ [QUERY_MEDIA_FACE_PERSON_CREATE]: MediaFacePersonCreateArgs;
576
+ [QUERY_MEDIA_FACE_PERSON_DELETE]: MediaFacePersonDeleteArgs;
577
+ [QUERY_MEDIA_FACE_PERSON_ADD]: MediaFacePersonAddArgs;
578
+ [QUERY_MEDIA_FACE_PERSON_REMOVE]: MediaFacePersonRemoveArgs;
579
+ [QUERY_MEDIA_FACE_IMAGE]: MediaFaceImageArgs;
580
+ [QUERY_MEDIA_FACE_TRAIN]: MediaFaceTrainArgs;
298
581
  };
299
582
  export type NvrAnalyticsQueryResponseMap = {
300
583
  [QUERY_MEDIA_SEARCH]: MediaSearchResponse;
@@ -302,4 +585,12 @@ export type NvrAnalyticsQueryResponseMap = {
302
585
  [QUERY_OBJECT_SNAPSHOT]: ObjectSnapshotResponse;
303
586
  [QUERY_OBJECT_THUMBNAIL]: ObjectThumbnailResponse;
304
587
  [QUERY_OBJECT_LABELS]: ObjectLabelsResponse;
588
+ [QUERY_MEDIA_FACES]: MediaFacesResponse;
589
+ [QUERY_MEDIA_FACE_PEOPLE]: MediaFacePeopleResponse;
590
+ [QUERY_MEDIA_FACE_PERSON_CREATE]: MediaFacePersonCreateResponse;
591
+ [QUERY_MEDIA_FACE_PERSON_DELETE]: MediaFacePersonDeleteResponse;
592
+ [QUERY_MEDIA_FACE_PERSON_ADD]: MediaFacePersonAddResponse;
593
+ [QUERY_MEDIA_FACE_PERSON_REMOVE]: MediaFacePersonRemoveResponse;
594
+ [QUERY_MEDIA_FACE_IMAGE]: MediaFaceImageResponse;
595
+ [QUERY_MEDIA_FACE_TRAIN]: MediaFaceTrainResponse;
305
596
  };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.nvrAnalyticsResponseSchemas = exports.nvrAnalyticsRequestSchemas = exports.sObjectLabelResponse = exports.sObjectLabelsArgs = exports.QUERY_OBJECT_LABELS = exports.sObjectThumbnailResponse = exports.sObjectThumbnailArgs = exports.QUERY_OBJECT_THUMBNAIL = exports.sObjectSnapshotResponse = exports.sObjectSnapshotArgs = exports.QUERY_OBJECT_SNAPSHOT = exports.sScenePreviewClipResponse = exports.sScenePreviewClipArgs = exports.QUERY_SCENE_PREVIEW_CLIP = exports.sMediaSearchResponse = exports.sMediaSearchMatch = exports.sMediaSearchArgs = exports.QUERY_MEDIA_SEARCH = void 0;
3
+ exports.nvrAnalyticsResponseSchemas = exports.nvrAnalyticsRequestSchemas = exports.sMediaFaceTrainResponse = exports.sMediaFaceTrainArgs = exports.QUERY_MEDIA_FACE_TRAIN = exports.sMediaFaceImageResponse = exports.sMediaFaceImageArgs = exports.QUERY_MEDIA_FACE_IMAGE = exports.sMediaFacePersonRemoveResponse = exports.sMediaFacePersonRemoveArgs = exports.QUERY_MEDIA_FACE_PERSON_REMOVE = exports.sMediaFacePersonAddResponse = exports.sMediaFacePersonAddArgs = exports.QUERY_MEDIA_FACE_PERSON_ADD = exports.sMediaFacePersonDeleteResponse = exports.sMediaFacePersonDeleteArgs = exports.QUERY_MEDIA_FACE_PERSON_DELETE = exports.sMediaFacePersonCreateResponse = exports.sMediaFacePersonCreateArgs = exports.QUERY_MEDIA_FACE_PERSON_CREATE = exports.sMediaFacePeopleResponse = exports.sMediaFacePeopleArgs = exports.QUERY_MEDIA_FACE_PEOPLE = exports.sMediaFacesResponse = exports.sMediaFacesArgs = exports.QUERY_MEDIA_FACES = exports.sObjectLabelResponse = exports.sObjectLabelsArgs = exports.QUERY_OBJECT_LABELS = exports.sObjectThumbnailResponse = exports.sObjectThumbnailArgs = exports.QUERY_OBJECT_THUMBNAIL = exports.sObjectSnapshotResponse = exports.sObjectSnapshotArgs = exports.QUERY_OBJECT_SNAPSHOT = exports.sScenePreviewClipResponse = exports.sScenePreviewClipArgs = exports.QUERY_SCENE_PREVIEW_CLIP = exports.sMediaSearchResponse = exports.sMediaSearchMatch = exports.sMediaSearchArgs = exports.QUERY_MEDIA_SEARCH = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const primitives_1 = require("../../primitives");
6
6
  const media_1 = require("../rest/media");
@@ -14,6 +14,7 @@ exports.sMediaSearchArgs = zod_1.z
14
14
  q: zod_1.z.string(),
15
15
  similarTo: zod_1.z.string().optional(),
16
16
  label: zod_1.z.array(zod_1.z.string().nonempty()),
17
+ subLabel: zod_1.z.array(zod_1.z.string().nonempty()),
17
18
  timeFrom: zod_1.z.number().nonnegative(),
18
19
  timeTo: zod_1.z.number().nonnegative(),
19
20
  sortBy: media_1.sSortOptions,
@@ -26,6 +27,7 @@ exports.sMediaSearchMatch = zod_1.z.object({
26
27
  provider: zod_1.z.string(),
27
28
  probability: zod_1.z.number(),
28
29
  objectKind: zod_1.z.string(),
30
+ subLabel: zod_1.z.string(),
29
31
  startTime: zod_1.z.number(),
30
32
  endTime: zod_1.z.number().nullable(),
31
33
  });
@@ -57,6 +59,69 @@ exports.QUERY_OBJECT_LABELS = 'cctv:object-labels';
57
59
  // (No args or response schema defined for this query in the provided code)
58
60
  exports.sObjectLabelsArgs = zod_1.z.object({});
59
61
  exports.sObjectLabelResponse = zod_1.z.array(zod_1.z.string());
62
+ // -- Faces (Gets list of recognized and un recognized faces in the media library, grouped by person)
63
+ exports.QUERY_MEDIA_FACES = 'cctv:media-faces';
64
+ exports.sMediaFacesArgs = zod_1.z.object({});
65
+ exports.sMediaFacesResponse = zod_1.z.record(zod_1.z.string(), zod_1.z.array(zod_1.z.string()));
66
+ // -- Face People (Gets list of people (ids) who are registered in the face recognition system)
67
+ exports.QUERY_MEDIA_FACE_PEOPLE = 'cctv:media-face-people';
68
+ exports.sMediaFacePeopleArgs = zod_1.z.object({});
69
+ exports.sMediaFacePeopleResponse = zod_1.z.array(zod_1.z.string());
70
+ // -- Media Face Person Create
71
+ exports.QUERY_MEDIA_FACE_PERSON_CREATE = 'cctv:media-face-person-create';
72
+ exports.sMediaFacePersonCreateArgs = zod_1.z.object({
73
+ id: zod_1.z.string().nonempty(),
74
+ });
75
+ exports.sMediaFacePersonCreateResponse = zod_1.z.object({
76
+ success: zod_1.z.boolean(),
77
+ message: zod_1.z.string(),
78
+ });
79
+ // -- Media Face Person Delete
80
+ exports.QUERY_MEDIA_FACE_PERSON_DELETE = 'cctv:media-face-person-delete';
81
+ exports.sMediaFacePersonDeleteArgs = zod_1.z.object({
82
+ id: zod_1.z.string().nonempty(),
83
+ });
84
+ exports.sMediaFacePersonDeleteResponse = zod_1.z.object({
85
+ success: zod_1.z.boolean(),
86
+ message: zod_1.z.string(),
87
+ });
88
+ // -- Media Face Person Add
89
+ exports.QUERY_MEDIA_FACE_PERSON_ADD = 'cctv:media-face-person-add';
90
+ exports.sMediaFacePersonAddArgs = zod_1.z.object({
91
+ id: zod_1.z.string().nonempty(),
92
+ image: zod_1.z.string().nonempty(),
93
+ });
94
+ exports.sMediaFacePersonAddResponse = zod_1.z.object({
95
+ success: zod_1.z.boolean(),
96
+ message: zod_1.z.string(),
97
+ });
98
+ // -- Media Face Person Remove
99
+ exports.QUERY_MEDIA_FACE_PERSON_REMOVE = 'cctv:media-face-person-remove';
100
+ exports.sMediaFacePersonRemoveArgs = zod_1.z.object({
101
+ id: zod_1.z.string().nonempty(),
102
+ image: zod_1.z.string().nonempty(),
103
+ });
104
+ exports.sMediaFacePersonRemoveResponse = zod_1.z.object({
105
+ success: zod_1.z.boolean(),
106
+ message: zod_1.z.string(),
107
+ });
108
+ // -- Media Face Image (Gets the image associated with a face in the media library)
109
+ exports.QUERY_MEDIA_FACE_IMAGE = 'cctv:media-face-image';
110
+ exports.sMediaFaceImageArgs = zod_1.z.object({
111
+ id: zod_1.z.string().nonempty(),
112
+ imageId: zod_1.z.string().nonempty(),
113
+ });
114
+ exports.sMediaFaceImageResponse = primitives_1.sFileResponse;
115
+ // -- Media Face Train (Assigns an unrecognized face in the media library to a person in the face recognition system)
116
+ exports.QUERY_MEDIA_FACE_TRAIN = 'cctv:media-face-train';
117
+ exports.sMediaFaceTrainArgs = zod_1.z.object({
118
+ id: zod_1.z.string().nonempty(),
119
+ imageId: zod_1.z.string().nonempty(),
120
+ });
121
+ exports.sMediaFaceTrainResponse = zod_1.z.object({
122
+ success: zod_1.z.boolean(),
123
+ message: zod_1.z.string(),
124
+ });
60
125
  // SCHEMA DICTIONARIES AND TYPE MAPS
61
126
  // Dictionary of request schemas by query type
62
127
  exports.nvrAnalyticsRequestSchemas = {
@@ -65,6 +130,14 @@ exports.nvrAnalyticsRequestSchemas = {
65
130
  [exports.QUERY_OBJECT_SNAPSHOT]: exports.sObjectSnapshotArgs,
66
131
  [exports.QUERY_OBJECT_THUMBNAIL]: exports.sObjectThumbnailArgs,
67
132
  [exports.QUERY_OBJECT_LABELS]: exports.sObjectLabelsArgs,
133
+ [exports.QUERY_MEDIA_FACES]: exports.sMediaFacesArgs,
134
+ [exports.QUERY_MEDIA_FACE_PEOPLE]: exports.sMediaFacePeopleArgs,
135
+ [exports.QUERY_MEDIA_FACE_PERSON_CREATE]: exports.sMediaFacePersonCreateArgs,
136
+ [exports.QUERY_MEDIA_FACE_PERSON_DELETE]: exports.sMediaFacePersonDeleteArgs,
137
+ [exports.QUERY_MEDIA_FACE_PERSON_ADD]: exports.sMediaFacePersonAddArgs,
138
+ [exports.QUERY_MEDIA_FACE_PERSON_REMOVE]: exports.sMediaFacePersonRemoveArgs,
139
+ [exports.QUERY_MEDIA_FACE_IMAGE]: exports.sMediaFaceImageArgs,
140
+ [exports.QUERY_MEDIA_FACE_TRAIN]: exports.sMediaFaceTrainArgs,
68
141
  };
69
142
  // Dictionary of response schemas by query type
70
143
  exports.nvrAnalyticsResponseSchemas = {
@@ -73,4 +146,12 @@ exports.nvrAnalyticsResponseSchemas = {
73
146
  [exports.QUERY_OBJECT_SNAPSHOT]: exports.sObjectSnapshotResponse,
74
147
  [exports.QUERY_OBJECT_THUMBNAIL]: exports.sObjectThumbnailResponse,
75
148
  [exports.QUERY_OBJECT_LABELS]: exports.sObjectLabelResponse,
149
+ [exports.QUERY_MEDIA_FACES]: exports.sMediaFacesResponse,
150
+ [exports.QUERY_MEDIA_FACE_PEOPLE]: exports.sMediaFacePeopleResponse,
151
+ [exports.QUERY_MEDIA_FACE_PERSON_CREATE]: exports.sMediaFacePersonCreateResponse,
152
+ [exports.QUERY_MEDIA_FACE_PERSON_DELETE]: exports.sMediaFacePersonDeleteResponse,
153
+ [exports.QUERY_MEDIA_FACE_PERSON_ADD]: exports.sMediaFacePersonAddResponse,
154
+ [exports.QUERY_MEDIA_FACE_PERSON_REMOVE]: exports.sMediaFacePersonRemoveResponse,
155
+ [exports.QUERY_MEDIA_FACE_IMAGE]: exports.sMediaFaceImageResponse,
156
+ [exports.QUERY_MEDIA_FACE_TRAIN]: exports.sMediaFaceTrainResponse,
76
157
  };