@awarevue/api-types 1.1.15 → 2.0.2
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/access-control/person-agreement.d.ts +2 -2
- package/dist/access-control/person.d.ts +4 -4
- package/dist/agent-communication/protocol.d.ts +108 -308
- package/dist/agent-communication/protocol.js +5 -8
- package/dist/agent-communication/queries.d.ts +1312 -1045
- package/dist/agent-communication/queries.js +11 -109
- package/dist/api/media.d.ts +6 -14
- package/dist/api/media.js +1 -4
- package/dist/device/alarm.d.ts +24 -24
- package/dist/device/any-device.d.ts +537 -269
- package/dist/device/any-device.js +22 -4
- package/dist/device/camera.d.ts +97 -0
- package/dist/device/camera.js +24 -1
- package/dist/device/index.d.ts +3 -1
- package/dist/device/index.js +3 -1
- package/dist/device/intercom-terminal.d.ts +4 -4
- package/dist/device/nvr-analytics-server.d.ts +307 -0
- package/dist/device/nvr-analytics-server.js +73 -0
- package/dist/device/nvr-exporter.d.ts +892 -0
- package/dist/device/nvr-exporter.js +77 -0
- package/dist/device/nvr-recorder.d.ts +2981 -0
- package/dist/device/nvr-recorder.js +47 -0
- package/dist/device/presence-tracker.d.ts +8 -8
- package/dist/device-event.d.ts +43 -19
- package/dist/device-event.js +5 -0
- package/dist/device-import.d.ts +123 -51
- package/dist/device-relation.d.ts +7 -7
- package/dist/device-relation.js +12 -0
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/messages/web-rtc-signaling.d.ts +10 -10
- package/dist/package.json +1 -1
- package/dist/permissions.d.ts +3 -3
- package/dist/permissions.js +9 -1
- package/dist/primitives.d.ts +596 -0
- package/dist/primitives.js +13 -1
- package/dist/user.d.ts +16 -16
- package/package.json +1 -1
- package/dist/device/recorder.d.ts +0 -12
- package/dist/device/recorder.js +0 -9
- package/dist/export.d.ts +0 -30
- package/dist/export.js +0 -14
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.nvrExporterResponseSchemas = exports.nvrExporterRequestSchemas = exports.sGetExportsResponse = exports.sExportItem = exports.sGetExportsArgs = exports.QUERY_GET_EXPORTS = exports.sGetExportLinkResponse = exports.sGetExportLinkArgs = exports.QUERY_GET_EXPORT_LINK = exports.nvrExporterEventSchemasByKind = exports.sExportDeleted = exports.sExportStarted = exports.sDeleteExportCommand = exports.sStartExportCommand = exports.sExporterStateDto = exports.sExporterSpecs = exports.NVR_EXPORTER = void 0;
|
|
4
|
+
const primitives_1 = require("../primitives");
|
|
5
|
+
const zod_1 = require("zod");
|
|
6
|
+
exports.NVR_EXPORTER = 'nvr-exporter';
|
|
7
|
+
exports.sExporterSpecs = zod_1.z.object({});
|
|
8
|
+
exports.sExporterStateDto = zod_1.z.object({
|
|
9
|
+
connected: zod_1.z.boolean(),
|
|
10
|
+
exportsInProgress: zod_1.z.array(zod_1.z.string().nonempty()),
|
|
11
|
+
});
|
|
12
|
+
// COMMANDS
|
|
13
|
+
exports.sStartExportCommand = zod_1.z.object({
|
|
14
|
+
command: zod_1.z.literal('nvr-exporter.start-export'),
|
|
15
|
+
params: zod_1.z.object({
|
|
16
|
+
requestId: zod_1.z.string().nonempty(),
|
|
17
|
+
device: primitives_1.sDeviceParam,
|
|
18
|
+
timeFrom: zod_1.z.number().int().nonnegative(),
|
|
19
|
+
timeTo: zod_1.z.number().int().nonnegative(),
|
|
20
|
+
name: zod_1.z.string().nonempty(),
|
|
21
|
+
}),
|
|
22
|
+
});
|
|
23
|
+
exports.sDeleteExportCommand = zod_1.z.object({
|
|
24
|
+
command: zod_1.z.literal('nvr-exporter.delete-export'),
|
|
25
|
+
params: zod_1.z.object({
|
|
26
|
+
exportId: zod_1.z.string().nonempty(),
|
|
27
|
+
}),
|
|
28
|
+
});
|
|
29
|
+
// EVENTS
|
|
30
|
+
exports.sExportStarted = zod_1.z.object({
|
|
31
|
+
kind: zod_1.z.literal('nvr-export-started'),
|
|
32
|
+
exportId: zod_1.z
|
|
33
|
+
.string()
|
|
34
|
+
.nonempty()
|
|
35
|
+
.describe('The ID of the export, will be used to reference the export in future commands and queries'),
|
|
36
|
+
requestId: zod_1.z.string().nonempty(),
|
|
37
|
+
});
|
|
38
|
+
exports.sExportDeleted = zod_1.z.object({
|
|
39
|
+
kind: zod_1.z.literal('nvr-export-deleted'),
|
|
40
|
+
exportId: zod_1.z.string().nonempty(),
|
|
41
|
+
});
|
|
42
|
+
exports.nvrExporterEventSchemasByKind = {
|
|
43
|
+
'nvr-export-started': exports.sExportStarted,
|
|
44
|
+
'nvr-export-deleted': exports.sExportDeleted,
|
|
45
|
+
};
|
|
46
|
+
// QUERIES
|
|
47
|
+
// -- Get Export Link
|
|
48
|
+
exports.QUERY_GET_EXPORT_LINK = 'cctv:get-export-link';
|
|
49
|
+
exports.sGetExportLinkArgs = zod_1.z.object({
|
|
50
|
+
exportId: zod_1.z.string().nonempty(),
|
|
51
|
+
});
|
|
52
|
+
exports.sGetExportLinkResponse = zod_1.z.object({
|
|
53
|
+
exportLink: zod_1.z.string().url(),
|
|
54
|
+
});
|
|
55
|
+
// -- Get Exports
|
|
56
|
+
exports.QUERY_GET_EXPORTS = 'cctv:get-exports';
|
|
57
|
+
exports.sGetExportsArgs = zod_1.z.object({});
|
|
58
|
+
exports.sExportItem = zod_1.z.object({
|
|
59
|
+
name: zod_1.z.string().nonempty(),
|
|
60
|
+
endTime: zod_1.z.number().int().nonnegative(),
|
|
61
|
+
startTime: zod_1.z.number().int().nonnegative(),
|
|
62
|
+
id: zod_1.z.string().nonempty(),
|
|
63
|
+
status: zod_1.z.string().nonempty(),
|
|
64
|
+
size: zod_1.z.string().nonempty().optional(),
|
|
65
|
+
expires: zod_1.z.number().int().nonnegative().optional(),
|
|
66
|
+
});
|
|
67
|
+
exports.sGetExportsResponse = zod_1.z.array(exports.sExportItem);
|
|
68
|
+
// Dictionary of request schemas by query type
|
|
69
|
+
exports.nvrExporterRequestSchemas = {
|
|
70
|
+
[exports.QUERY_GET_EXPORT_LINK]: exports.sGetExportLinkArgs,
|
|
71
|
+
[exports.QUERY_GET_EXPORTS]: exports.sGetExportsArgs,
|
|
72
|
+
};
|
|
73
|
+
// Dictionary of response schemas by query type
|
|
74
|
+
exports.nvrExporterResponseSchemas = {
|
|
75
|
+
[exports.QUERY_GET_EXPORT_LINK]: exports.sGetExportLinkResponse,
|
|
76
|
+
[exports.QUERY_GET_EXPORTS]: exports.sGetExportsResponse,
|
|
77
|
+
};
|