@evercam/api 1.0.0-ecc20ba32 → 1.0.0-eea993f14
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/api/api/3dFirebaseApi.d.ts +5 -1
- package/dist/api/api/adminApi.d.ts +3 -23
- package/dist/api/api/aiApi.d.ts +9 -14
- package/dist/api/api/authzApi.d.ts +5 -3
- package/dist/api/api/client/axios.d.ts +1 -0
- package/dist/api/api/evercamApi.d.ts +1 -24
- package/dist/api/api/evercamLabsApi.d.ts +3 -1
- package/dist/api/api/ingestApi.d.ts +1 -0
- package/dist/api/types/360.d.ts +130 -3
- package/dist/api/types/analytics.d.ts +1 -1
- package/dist/api/types/authz.d.ts +11 -5
- package/dist/api/types/axios.d.ts +1 -0
- package/dist/api/types/camera.d.ts +1 -1
- package/dist/api/types/gateReport.d.ts +3 -0
- package/dist/api/types/project.d.ts +6 -0
- package/dist/api/types/shares.d.ts +6 -144
- package/dist/api/types/siteAnalytics.d.ts +111 -27
- package/dist/api/types/user.d.ts +14 -1
- package/dist/index.js +431 -450
- package/dist/index.js.map +1 -1
- package/dist/index.umd.cjs +1 -1
- package/dist/index.umd.cjs.map +1 -1
- package/package.json +2 -2
|
@@ -1,34 +1,33 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { BBox, BoundingBox, DateType, Schedule, CameraExid, DateTime, DetectionModel, PaginationParams, PpeLabel, ProjectExid, CameraDateRangeFilter, CameraFeatureFlag, TimelineDateInterval, Camera, AdminCamera, _360FullProject, _360FloorId, PaginatedItems } from "@evercam/api/types";
|
|
2
2
|
import { DetectionLabel, DownloadFileType } from "@evercam/api/types";
|
|
3
3
|
export declare enum SiteAnalyticsMode {
|
|
4
4
|
Detections = "detections",
|
|
5
5
|
Segments = "segments"
|
|
6
6
|
}
|
|
7
|
-
export type
|
|
7
|
+
export type SmartSearchPart = {
|
|
8
8
|
id?: string;
|
|
9
|
-
type:
|
|
9
|
+
type: SmartSearchPartType;
|
|
10
10
|
value: DetectionLabel | SmartSearchOperatorType | SmartSearchConditionData | SmartSearchCondition | SmartSearchDateRange | string;
|
|
11
11
|
};
|
|
12
|
-
export
|
|
13
|
-
export declare enum SmartSearchQueryComponentType {
|
|
12
|
+
export declare enum SmartSearchComponentType {
|
|
14
13
|
Condition = "condition",
|
|
15
14
|
Object = "object",
|
|
16
15
|
Area = "in_area",
|
|
17
16
|
Time = "time",
|
|
18
17
|
Operator = "operator",
|
|
19
|
-
|
|
18
|
+
View = "view",
|
|
20
19
|
DateRange = "date_range",
|
|
21
20
|
Heatmap = "heatmap"
|
|
22
21
|
}
|
|
23
|
-
export type
|
|
22
|
+
export type SmartSearchPartType = SmartSearchComponentType | SmartSearchCondition;
|
|
24
23
|
export type SmartSearchDateRange = {
|
|
25
24
|
start: DateType;
|
|
26
25
|
end: DateType;
|
|
27
26
|
};
|
|
28
|
-
export type
|
|
27
|
+
export type SmartSearchComponentData = {
|
|
29
28
|
id: string;
|
|
30
|
-
type:
|
|
31
|
-
parts:
|
|
29
|
+
type: SmartSearchComponentType;
|
|
30
|
+
parts: SmartSearchPart[];
|
|
32
31
|
};
|
|
33
32
|
export declare enum SmartSearchCondition {
|
|
34
33
|
InArea = "in_area",
|
|
@@ -39,33 +38,33 @@ export type SmartSearchConditionData = {
|
|
|
39
38
|
condition: SmartSearchCondition;
|
|
40
39
|
value: string | BoundingBox | DetectionLabel | Date;
|
|
41
40
|
};
|
|
42
|
-
export type
|
|
43
|
-
type:
|
|
44
|
-
target:
|
|
45
|
-
operator?:
|
|
41
|
+
export type SmartSearchBackendQueryCondition = {
|
|
42
|
+
type: SmartSearchConditionTypes;
|
|
43
|
+
target: SmartSearchTargets;
|
|
44
|
+
operator?: SmartSearchOperators;
|
|
46
45
|
attribute?: string;
|
|
47
46
|
value: string | number | string[];
|
|
48
47
|
reference?: {
|
|
49
|
-
target:
|
|
48
|
+
target: SmartSearchTargets;
|
|
50
49
|
attribute: string;
|
|
51
50
|
value: string | number | string[];
|
|
52
51
|
};
|
|
53
52
|
polygon?: BBox;
|
|
54
53
|
};
|
|
55
|
-
export type
|
|
56
|
-
returnTargets:
|
|
54
|
+
export type SmartSearchBackendQuery = {
|
|
55
|
+
returnTargets: SmartSearchTargets[];
|
|
57
56
|
rulesLogic: SmartSearchOperatorType;
|
|
58
57
|
rules: {
|
|
59
58
|
logic: SmartSearchOperatorType;
|
|
60
|
-
conditions:
|
|
59
|
+
conditions: SmartSearchBackendQueryCondition[];
|
|
61
60
|
}[];
|
|
62
|
-
returnType:
|
|
61
|
+
returnType: SmartSearchReturnType;
|
|
63
62
|
};
|
|
64
|
-
export declare enum
|
|
63
|
+
export declare enum SmartSearchTargets {
|
|
65
64
|
Tracking = "tracking",
|
|
66
65
|
Segments = "segments"
|
|
67
66
|
}
|
|
68
|
-
export declare enum
|
|
67
|
+
export declare enum SmartSearchReturnType {
|
|
69
68
|
All = "all",
|
|
70
69
|
FirstLastSeen = "first_last_seen"
|
|
71
70
|
}
|
|
@@ -73,7 +72,7 @@ export declare enum SmartSearchOperatorType {
|
|
|
73
72
|
And = "AND",
|
|
74
73
|
Or = "OR"
|
|
75
74
|
}
|
|
76
|
-
export declare enum
|
|
75
|
+
export declare enum SmartSearchOperators {
|
|
77
76
|
Near = "near",
|
|
78
77
|
Far = "far",
|
|
79
78
|
Intersects = "intersects",
|
|
@@ -85,21 +84,22 @@ export declare enum SmartSearchQueryOperators {
|
|
|
85
84
|
Area = "in_area",
|
|
86
85
|
Equal = "="
|
|
87
86
|
}
|
|
88
|
-
export declare enum
|
|
87
|
+
export declare enum SmartSearchConditionTypes {
|
|
89
88
|
Selection = "selection",
|
|
90
89
|
Spatial = "spatial",
|
|
91
90
|
Area = "area",
|
|
91
|
+
GeoArea = "in_geo_area",
|
|
92
92
|
Iou = "iou",
|
|
93
93
|
Near = "near",
|
|
94
94
|
Far = "far"
|
|
95
95
|
}
|
|
96
96
|
export type SmartSearchOptionValue = DetectionLabel | SmartSearchOperatorType | SmartSearchConditionData;
|
|
97
|
-
export type
|
|
97
|
+
export type SmartSearchBackendQueryPayload = {
|
|
98
98
|
cameraExid: string;
|
|
99
99
|
name: string;
|
|
100
100
|
description: string;
|
|
101
101
|
query: {
|
|
102
|
-
req:
|
|
102
|
+
req: SmartSearchBackendQuery;
|
|
103
103
|
timeSchedule?: Schedule | undefined;
|
|
104
104
|
};
|
|
105
105
|
fromDate?: DateType;
|
|
@@ -112,11 +112,11 @@ export type SavedQuery = {
|
|
|
112
112
|
description: string;
|
|
113
113
|
id: number;
|
|
114
114
|
query: {
|
|
115
|
-
req:
|
|
115
|
+
req: SmartSearchBackendQuery;
|
|
116
116
|
timeSchedule?: Schedule | undefined;
|
|
117
117
|
};
|
|
118
118
|
params: Record<string, string>;
|
|
119
|
-
components?: Omit<
|
|
119
|
+
components?: Omit<SmartSearchPart, "id">[];
|
|
120
120
|
toDate?: DateType;
|
|
121
121
|
createdAt?: DateType;
|
|
122
122
|
cameraExid: string;
|
|
@@ -161,3 +161,87 @@ export type SmartSearchSidebarItem = {
|
|
|
161
161
|
data: SmartSearchHeatmapData;
|
|
162
162
|
imagePath?: string;
|
|
163
163
|
};
|
|
164
|
+
export declare enum SiteAnalyticsViewType {
|
|
165
|
+
Camera = "camera",
|
|
166
|
+
ThreeSixty = "360"
|
|
167
|
+
}
|
|
168
|
+
type SiteAnalyticsViewByType = {
|
|
169
|
+
[SiteAnalyticsViewType.Camera]: Camera | AdminCamera;
|
|
170
|
+
[SiteAnalyticsViewType.ThreeSixty]: _360FullProject;
|
|
171
|
+
};
|
|
172
|
+
export type SiteAnalyticsView<T extends SiteAnalyticsViewType = SiteAnalyticsViewType.Camera> = {
|
|
173
|
+
type: SiteAnalyticsViewType;
|
|
174
|
+
value: SiteAnalyticsViewByType[T];
|
|
175
|
+
};
|
|
176
|
+
export type SiteAnalyticsProcessingStatusPayload = {
|
|
177
|
+
projectExid?: ProjectExid;
|
|
178
|
+
fromDate?: DateType;
|
|
179
|
+
toDate?: DateType;
|
|
180
|
+
cameraExid?: CameraExid;
|
|
181
|
+
drawingId?: string;
|
|
182
|
+
features?: CameraFeatureFlag[];
|
|
183
|
+
};
|
|
184
|
+
export type SiteAnalyticsProcessingStatus = {
|
|
185
|
+
projectExid: ProjectExid;
|
|
186
|
+
viewType: SiteAnalyticsViewType;
|
|
187
|
+
viewId: string;
|
|
188
|
+
feature: CameraFeatureFlag;
|
|
189
|
+
processedIntervals: TimelineDateInterval[];
|
|
190
|
+
};
|
|
191
|
+
export type SmartSearchRequestPayload = {
|
|
192
|
+
cameraExids?: CameraExid[];
|
|
193
|
+
drawingIds?: _360FloorId[];
|
|
194
|
+
walkIds?: string[];
|
|
195
|
+
markerIds?: string[];
|
|
196
|
+
payload: SmartSearchBackendQuery;
|
|
197
|
+
fromDate?: string;
|
|
198
|
+
toDate?: string;
|
|
199
|
+
page?: number;
|
|
200
|
+
pageSize?: number;
|
|
201
|
+
threshold?: number;
|
|
202
|
+
};
|
|
203
|
+
type SmartSearchResultItemBase = {
|
|
204
|
+
area: number;
|
|
205
|
+
bbox: BBox;
|
|
206
|
+
cameraExid?: CameraExid;
|
|
207
|
+
centroid: number[];
|
|
208
|
+
confidenceScore: number;
|
|
209
|
+
drawingId?: _360FloorId;
|
|
210
|
+
label: DetectionLabel;
|
|
211
|
+
modelId: DetectionModel;
|
|
212
|
+
projectExid: ProjectExid;
|
|
213
|
+
segmentId?: number;
|
|
214
|
+
trackId: number;
|
|
215
|
+
walkId?: string | number;
|
|
216
|
+
};
|
|
217
|
+
export type SmartSearchResultItemFirstLastSeen = SmartSearchResultItemBase & {
|
|
218
|
+
firstSeen: DateType;
|
|
219
|
+
firstSeenMarkerId?: string | number;
|
|
220
|
+
lastSeen: DateType;
|
|
221
|
+
lastSeenMarkerId?: string | number;
|
|
222
|
+
};
|
|
223
|
+
export type SmartSearchResultItemAll = SmartSearchResultItemBase & {
|
|
224
|
+
walkId?: string | number;
|
|
225
|
+
markerId?: string | number;
|
|
226
|
+
geolocation?: number[];
|
|
227
|
+
mask?: number[][];
|
|
228
|
+
timestamp: DateType;
|
|
229
|
+
};
|
|
230
|
+
type SmartSearchResultItemByType = {
|
|
231
|
+
[SmartSearchReturnType.FirstLastSeen]: SmartSearchResultItemFirstLastSeen;
|
|
232
|
+
[SmartSearchReturnType.All]: SmartSearchResultItemAll;
|
|
233
|
+
};
|
|
234
|
+
export type SmartSearchResponse<R extends SmartSearchReturnType = SmartSearchReturnType.FirstLastSeen> = {
|
|
235
|
+
data: PaginatedItems<SmartSearchResultItemByType[R]>;
|
|
236
|
+
message?: string;
|
|
237
|
+
success: boolean;
|
|
238
|
+
};
|
|
239
|
+
export type SmartSearchMinifiedPart = {
|
|
240
|
+
t: SmartSearchComponentType;
|
|
241
|
+
v: unknown;
|
|
242
|
+
};
|
|
243
|
+
export type SmartSearchMinifiedComponent = {
|
|
244
|
+
t: SmartSearchComponentType;
|
|
245
|
+
p: SmartSearchMinifiedPart[];
|
|
246
|
+
};
|
|
247
|
+
export {};
|
package/dist/api/types/user.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { DateTime, PaginationParams, BaseRole, SubRole } from "@/types";
|
|
2
2
|
export type User = {
|
|
3
3
|
id?: number;
|
|
4
4
|
fullname?: string;
|
|
@@ -273,3 +273,16 @@ export type Suppression = {
|
|
|
273
273
|
insertedAt: DateTime;
|
|
274
274
|
updatedAt: DateTime;
|
|
275
275
|
};
|
|
276
|
+
export type ProjectUserWithRole = {
|
|
277
|
+
id: number;
|
|
278
|
+
email: string;
|
|
279
|
+
fullname: string;
|
|
280
|
+
company: {
|
|
281
|
+
id: number;
|
|
282
|
+
name: string;
|
|
283
|
+
exid: string;
|
|
284
|
+
};
|
|
285
|
+
permissions: string[];
|
|
286
|
+
role: BaseRole;
|
|
287
|
+
subRoles: SubRole[];
|
|
288
|
+
};
|