@evercam/api 1.0.0-7f2a06308 → 1.0.0-7f640ff6f

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.
Files changed (107) hide show
  1. package/README.md +1 -0
  2. package/dist/api/api/3dFirebaseApi.d.ts +212 -15
  3. package/dist/api/api/adminApi.d.ts +152 -120
  4. package/dist/api/api/aiApi.d.ts +192 -57
  5. package/dist/api/api/authzApi.d.ts +26 -16
  6. package/dist/api/api/client/axios.d.ts +1 -1
  7. package/dist/api/api/client/interceptors.d.ts +1 -1
  8. package/dist/api/api/client/swr/Swr.d.ts +1 -1
  9. package/dist/api/api/evercamApi.d.ts +150 -95
  10. package/dist/api/api/evercamLabsApi.d.ts +10 -19
  11. package/dist/api/api/exNvrApi.d.ts +2 -2
  12. package/dist/api/api/index.d.ts +1 -0
  13. package/dist/api/api/ingestApi.d.ts +133 -59
  14. package/dist/api/api/ptzApi.d.ts +9 -4
  15. package/dist/api/api/reportsApi.d.ts +15 -0
  16. package/dist/api/api/videoWallApi.d.ts +2 -2
  17. package/dist/api/api/weatherApi.d.ts +2 -2
  18. package/dist/api/types/360.d.ts +182 -88
  19. package/dist/api/types/aconex.d.ts +9 -9
  20. package/dist/api/types/admin.d.ts +89 -0
  21. package/dist/api/types/aiConfigs.d.ts +244 -0
  22. package/dist/api/types/analytics.d.ts +163 -75
  23. package/dist/api/types/anpr.d.ts +142 -2
  24. package/dist/api/types/apiKey.d.ts +70 -0
  25. package/dist/api/types/auditLogs.d.ts +179 -21
  26. package/dist/api/types/authz.d.ts +115 -6
  27. package/dist/api/types/autodesk.d.ts +7 -7
  28. package/dist/api/types/automation.d.ts +65 -3
  29. package/dist/api/types/axios.d.ts +20 -15
  30. package/dist/api/types/bim.d.ts +80 -16
  31. package/dist/api/types/camera.d.ts +316 -193
  32. package/dist/api/types/comments.d.ts +68 -31
  33. package/dist/api/types/company.d.ts +53 -6
  34. package/dist/api/types/compare.d.ts +21 -6
  35. package/dist/api/types/connector.d.ts +5 -5
  36. package/dist/api/types/coolify.d.ts +18 -2
  37. package/dist/api/types/detections.d.ts +26 -18
  38. package/dist/api/types/drone.d.ts +95 -6
  39. package/dist/api/types/emailMessages.d.ts +27 -0
  40. package/dist/api/types/errors.d.ts +19 -2
  41. package/dist/api/types/gateReport.d.ts +84 -73
  42. package/dist/api/types/gateReportManagement.d.ts +170 -0
  43. package/dist/api/types/hammertech.d.ts +98 -0
  44. package/dist/api/types/hdd.d.ts +27 -2
  45. package/dist/api/types/index.d.ts +17 -3
  46. package/dist/api/types/ingest.d.ts +285 -17
  47. package/dist/api/types/kit.d.ts +108 -121
  48. package/dist/api/types/map.d.ts +12 -0
  49. package/dist/api/types/media.d.ts +33 -4
  50. package/dist/api/types/notification.d.ts +83 -3
  51. package/dist/api/types/nvr.d.ts +39 -8
  52. package/dist/api/types/oauth.d.ts +62 -0
  53. package/dist/api/types/observationEvents.d.ts +167 -0
  54. package/dist/api/types/observations.d.ts +89 -0
  55. package/dist/api/types/planner.d.ts +98 -8
  56. package/dist/api/types/posthog.d.ts +87 -0
  57. package/dist/api/types/procore.d.ts +13 -6
  58. package/dist/api/types/progressPhoto.d.ts +42 -25
  59. package/dist/api/types/project.d.ts +154 -33
  60. package/dist/api/types/recording.d.ts +9 -15
  61. package/dist/api/types/recycleBin.d.ts +9 -3
  62. package/dist/api/types/reports.d.ts +109 -0
  63. package/dist/api/types/ring.d.ts +53 -0
  64. package/dist/api/types/roi.d.ts +3 -11
  65. package/dist/api/types/routeParams.d.ts +1 -0
  66. package/dist/api/types/router.d.ts +15 -10
  67. package/dist/api/types/shared.d.ts +47 -30
  68. package/dist/api/types/shares.d.ts +1 -14
  69. package/dist/api/types/sim.d.ts +23 -11
  70. package/dist/api/types/siteAnalytics.d.ts +81 -43
  71. package/dist/api/types/siteAnalyticsManagement.d.ts +127 -0
  72. package/dist/api/types/siteView.d.ts +104 -0
  73. package/dist/api/types/smartSeach.d.ts +5 -0
  74. package/dist/api/types/snapshots.d.ts +99 -14
  75. package/dist/api/types/socket.d.ts +4 -0
  76. package/dist/api/types/sso.d.ts +12 -37
  77. package/dist/api/types/storageProvider.d.ts +30 -0
  78. package/dist/api/types/storyblok.d.ts +27 -0
  79. package/dist/api/types/streaming.d.ts +3 -3
  80. package/dist/api/types/tag.d.ts +1 -1
  81. package/dist/api/types/time.d.ts +0 -18
  82. package/dist/api/types/timelapse.d.ts +7 -11
  83. package/dist/api/types/user.d.ts +139 -54
  84. package/dist/api/types/videoWall.d.ts +21 -21
  85. package/dist/api/types/weather.d.ts +75 -11
  86. package/dist/api/types/widget.d.ts +83 -15
  87. package/dist/api/types/xweather.d.ts +4 -4
  88. package/dist/api/utils.d.ts +1 -1
  89. package/dist/index.js +2497 -953
  90. package/dist/index.js.map +1 -1
  91. package/dist/index.umd.cjs +1 -1
  92. package/dist/index.umd.cjs.map +1 -1
  93. package/dist/shared/types/components.d.ts +769 -33
  94. package/dist/shared/types/customDataTableFilters.d.ts +10 -0
  95. package/dist/shared/types/droneUpload.d.ts +93 -0
  96. package/dist/shared/types/imagePlayer.d.ts +9 -2
  97. package/dist/shared/types/index.d.ts +5 -0
  98. package/dist/shared/types/observations.d.ts +25 -0
  99. package/dist/shared/types/rbac.d.ts +80 -0
  100. package/dist/shared/types/report.d.ts +108 -0
  101. package/dist/shared/types/timeline.d.ts +2 -1
  102. package/dist/shared/utils/datePickerValue.d.ts +36 -0
  103. package/dist/shared/utils/datePresets.d.ts +31 -0
  104. package/package.json +4 -2
  105. package/dist/api/types/copilot.d.ts +0 -157
  106. package/dist/api/types/storageServers.d.ts +0 -4
  107. package/dist/api/types/vendorModel.d.ts +0 -15
@@ -0,0 +1,30 @@
1
+ import type { DateType } from "@evercam/api/types";
2
+ import type { CameraExid } from "@evercam/api/types/camera";
3
+ export type StorageProviderS3Config = {
4
+ bucket?: string;
5
+ accessKeyId?: string;
6
+ secretAccessKey?: string;
7
+ region?: string;
8
+ vendor?: string;
9
+ };
10
+ export type StorageProviderSeaweedfsConfig = {
11
+ jwtSigningKey?: string;
12
+ jwtReadSigningKey?: string;
13
+ };
14
+ export type StorageProviderConfig = StorageProviderS3Config & StorageProviderSeaweedfsConfig;
15
+ export type StorageProvider = {
16
+ id?: number;
17
+ cameraId: number | CameraExid;
18
+ type: string;
19
+ provider: string;
20
+ url: string;
21
+ startDate: DateType;
22
+ endDate: DateType;
23
+ config: StorageProviderConfig;
24
+ insertedAt?: DateType;
25
+ updatedAt?: DateType;
26
+ };
27
+ export declare enum ProjectStorageProvider {
28
+ Seaweedfs = "seaweedfs",
29
+ S3 = "s3"
30
+ }
@@ -0,0 +1,27 @@
1
+ import type { JsonObject, JsonValue } from "@evercam/api/types";
2
+ export type StoryblokStory<TContent extends JsonObject = JsonObject> = {
3
+ id: number;
4
+ uuid: string;
5
+ name: string;
6
+ slug: string;
7
+ fullSlug: string;
8
+ content: TContent;
9
+ createdAt: string;
10
+ publishedAt: string | null;
11
+ updatedAt: string;
12
+ position: number;
13
+ tagList: string[];
14
+ isStartpage: boolean;
15
+ parentId: number | null;
16
+ groupId: string;
17
+ firstPublishedAt: string | null;
18
+ releaseId: number | null;
19
+ lang: string;
20
+ path: string;
21
+ };
22
+ export type StoryblokResponse<TContent extends JsonObject = JsonObject> = {
23
+ story: StoryblokStory<TContent>;
24
+ cv: number;
25
+ rels: JsonValue[];
26
+ links: JsonValue[];
27
+ };
@@ -1,11 +1,11 @@
1
- import { DateTime_Z_micros, KitMetricData } from "@/types";
1
+ import { KitMetricData } from "@evercam/api/types";
2
2
  export type ExNvrLoginResponse = {
3
3
  accessToken: string;
4
4
  };
5
5
  export type ExNvrRecordingInterval = {
6
6
  active: boolean;
7
- startDate: DateTime_Z_micros;
8
- endDate: DateTime_Z_micros;
7
+ startDate: string;
8
+ endDate: string;
9
9
  };
10
10
  export type ExNvrDeviceConfig = {
11
11
  id: string;
@@ -1,4 +1,4 @@
1
- import { Kit } from "@/types/kit";
1
+ import { Kit } from "@evercam/api/types/kit";
2
2
  export type Tag<T = string> = {
3
3
  id?: number;
4
4
  name: T;
@@ -1,25 +1,7 @@
1
1
  import { Moment } from "moment-timezone";
2
2
  export type DateType = Date | string | number;
3
3
  export type ExtendedDateType = Moment | DateType;
4
- type YYYY = number;
5
- type MM = number;
6
- type DD = number;
7
- type HH = number;
8
- type mm = number;
9
- type ss = number;
10
- type microS = number;
11
- export type Date_YYYY = `${YYYY}` | string;
12
- export type Date_YYYY_MM = `${YYYY}-${MM}` | string;
13
- export type Date_YYYY_MM_DD = `${YYYY}-${MM}-${DD}` | string;
14
- export type Time_HH_mm_ss = `${HH}:${mm}:${ss}` | string;
15
- export type Date_HH = `${HH}` | string;
16
- export type DateTime = `${Date_YYYY_MM_DD}T${Time_HH_mm_ss}` | string;
17
- export type DateTime_tz = `${Date_YYYY_MM_DD}T${Time_HH_mm_ss}${"+" | "-"}${HH}:${mm}` | string;
18
- export type DateTime_Z = `${Date_YYYY_MM_DD}T${Time_HH_mm_ss}Z` | string;
19
- export type DateTime_Z_micros = `${Date_YYYY_MM_DD}T${Time_HH_mm_ss}.${microS}Z` | string;
20
- export type DateTimeSpaceSeparated = `${Date_YYYY_MM_DD} ${Time_HH_mm_ss}` | string;
21
4
  export type DateRangeFilter = {
22
5
  fromDate: DateType;
23
6
  toDate: DateType;
24
7
  };
25
- export {};
@@ -1,4 +1,4 @@
1
- import { DateType, Schedule } from "@/types";
1
+ import { Point2D, Schedule } from "@evercam/api/types";
2
2
  export declare enum TimelapseStatus {
3
3
  Pending = 11,
4
4
  Completed = 5,
@@ -7,7 +7,8 @@ export declare enum TimelapseStatus {
7
7
  export declare enum TimelapseDuration {
8
8
  ThirtySeconds = 30,
9
9
  SixtySeconds = 60,
10
- NintySeconds = 90
10
+ NintySeconds = 90,
11
+ TwoMinutes = 120
11
12
  }
12
13
  export type TimelapseVideoOptions = {
13
14
  width?: number;
@@ -15,7 +16,9 @@ export type TimelapseVideoOptions = {
15
16
  removeTimestamp: boolean;
16
17
  smoothTransition: boolean;
17
18
  evercamWatermark: boolean;
19
+ sectionBlur?: boolean;
18
20
  timestampPosition?: TimestampPositionCoordinates;
21
+ blurRegions?: BlurRegionCoordinates[];
19
22
  };
20
23
  export type TimestampPositionCoordinates = {
21
24
  x: number;
@@ -23,14 +26,14 @@ export type TimestampPositionCoordinates = {
23
26
  w: number;
24
27
  h: number;
25
28
  };
29
+ export type BlurRegionCoordinates = Point2D[];
26
30
  export type TimelapseLogoOptions = {
27
- id: number;
31
+ id?: number;
28
32
  x: number;
29
33
  y: number;
30
34
  width: number;
31
35
  height: number;
32
36
  };
33
- export type TimelapseSchedules = string | Schedule;
34
37
  export declare enum TimelapseScheduleType {
35
38
  Continuous = "continuous",
36
39
  WorkingHours = "workingHours",
@@ -51,13 +54,6 @@ export declare enum TimelapseType {
51
54
  Year = "year",
52
55
  FullProject = "full_project"
53
56
  }
54
- export type TimelapseFilterQueryParams = {
55
- from?: DateType;
56
- to?: DateType;
57
- period?: TimelapsePeriod;
58
- duration?: number;
59
- schedule?: TimelapseSchedules;
60
- };
61
57
  export type TimelapseCreationRequestPayload = {
62
58
  title: string;
63
59
  duration: number;
@@ -1,4 +1,5 @@
1
- import type { DateTime, PaginationParams } from "@/types";
1
+ import type { CameraExid, JsonValue, PaginationParams } from "@evercam/api/types";
2
+ import { Role, RoleSubRole } from "@evercam/api/types/authz";
2
3
  export type User = {
3
4
  id?: number;
4
5
  fullname?: string;
@@ -9,10 +10,16 @@ export type User = {
9
10
  country: string;
10
11
  isAdmin: boolean;
11
12
  persona: Persona;
12
- companyId?: string;
13
+ companyId?: string | number;
13
14
  companyName?: string;
14
15
  companyExid?: string;
15
16
  features?: Array<UserFeatureFlag>;
17
+ confirmedAt?: string;
18
+ createdAt?: string;
19
+ lastLoginAt?: string;
20
+ token?: string;
21
+ updatedAt?: string;
22
+ evercamAccount?: boolean;
16
23
  };
17
24
  export type AdminUser = {
18
25
  id: number;
@@ -21,10 +28,8 @@ export type AdminUser = {
21
28
  email: string;
22
29
  telephone: string;
23
30
  country: string;
24
- isAdmin: boolean;
25
31
  companyId: string;
26
32
  companyName: string;
27
- companyExid: string;
28
33
  features: Array<UserFeatureFlag>;
29
34
  active: boolean;
30
35
  cameraShares: number;
@@ -32,9 +37,9 @@ export type AdminUser = {
32
37
  camerasOwned: number;
33
38
  countryId: number;
34
39
  countryName: string;
35
- createdAt: DateTime;
40
+ createdAt: string;
36
41
  integrations: string[];
37
- lastSeenAt: DateTime;
42
+ lastSeenAt: string;
38
43
  lastLoginAt: string;
39
44
  lastname: string;
40
45
  persona: string;
@@ -48,7 +53,6 @@ export declare enum UserFeatureFlag {
48
53
  CompanyAdmin = "company-admin",
49
54
  VideoWalls = "video-walls",
50
55
  MassCameraSharing = "mass-camera-sharing",
51
- Copilot = "copilot",
52
56
  ProjectSharing = "project-sharing"
53
57
  }
54
58
  export type ProjectUser = User & {
@@ -89,26 +93,48 @@ export type RemotePasswordUpdateRequestPayload = {
89
93
  currentPassword: string;
90
94
  newPassword: string;
91
95
  };
92
- export type LoginResponsePayload = {
93
- confirmedAt?: string;
94
- country?: string;
95
- createdAt?: string;
96
- email?: string;
97
- firstname?: string;
98
- id?: string;
99
- isAdmin?: boolean;
100
- lastLoginAt?: string;
101
- lastname?: string;
102
- persona?: Persona;
103
- telephone?: string;
104
- token?: string;
105
- updatedAt?: string;
106
- evercamAccount?: string;
96
+ export declare enum AuthOptionType {
97
+ Password = "password",
98
+ Sso = "sso"
99
+ }
100
+ export type AuthPasswordOption = {
101
+ type: AuthOptionType.Password;
102
+ };
103
+ export type AuthSsoOption = {
104
+ type: AuthOptionType.Sso;
105
+ name: string;
106
+ scope: string;
107
+ prompt: string | null;
108
+ exid: string;
109
+ clientId: string;
110
+ iconUrl: string;
111
+ loginUrl: string;
112
+ responseType: string;
113
+ };
114
+ export type AuthOption = AuthPasswordOption | AuthSsoOption;
115
+ export type AuthOptionsResponsePayload = {
116
+ options: AuthOption[];
117
+ };
118
+ export type AuthProviderConfigPayload = {
119
+ name: string;
120
+ scope: string;
121
+ prompt: string | null;
122
+ exid: string;
123
+ clientId: string;
124
+ iconUrl: string;
125
+ loginUrl: string;
126
+ responseType: string;
107
127
  };
108
128
  export type LogoutParams = {
109
129
  token: string;
110
130
  fromAdmin?: boolean;
111
131
  };
132
+ export type ConfirmUserRequestPayload = {
133
+ c: string;
134
+ };
135
+ export type DeleteActiveSessionRequestPayload = {
136
+ authorization: string;
137
+ };
112
138
  export type UserSession = {
113
139
  browser: string;
114
140
  createdAt: string;
@@ -127,9 +153,24 @@ export type SessionsListRequestPayload = {
127
153
  limit: number;
128
154
  page: number;
129
155
  };
156
+ export type AuthorizedApp = {
157
+ id: number;
158
+ clientId: string;
159
+ clientName: string;
160
+ clientDescription: string | null;
161
+ logoUrl: string | null;
162
+ scopes: string[];
163
+ grantedAt: string;
164
+ };
165
+ export type AuthorizedAppsListRequestPayload = {
166
+ search?: string;
167
+ sort?: string;
168
+ limit?: number;
169
+ page?: number;
170
+ };
130
171
  export type SessionActivityCamSettingsDetail = {
131
- new: any;
132
- old: any;
172
+ new: Record<string, JsonValue>;
173
+ old: Record<string, JsonValue>;
133
174
  };
134
175
  export type SessionActivityDetail = {
135
176
  agent: string;
@@ -152,7 +193,6 @@ export type SessionActivitiesListRequestPayload = {
152
193
  };
153
194
  export type SignupUserRequestPayload = {
154
195
  telephone: string;
155
- token: string;
156
196
  firstname: string;
157
197
  lastname: string;
158
198
  email: string;
@@ -170,13 +210,33 @@ export type UserUpdateRequestPayload = {
170
210
  country: string;
171
211
  persona: string;
172
212
  };
173
- export type UserDeleteRequestPayload = {
174
- verifEmail: string;
175
- };
176
213
  export type GoogleAuthRequestPayload = {
177
214
  code: string;
178
215
  redirectUri: string;
179
216
  };
217
+ export type ProjectContact = {
218
+ name: string;
219
+ role: ContactRole | string;
220
+ email?: string;
221
+ phone?: string;
222
+ photo?: string;
223
+ };
224
+ export type ProjectContactsResponsePayload = {
225
+ data: ProjectContact[];
226
+ };
227
+ export type EmailCcRule = {
228
+ csmEmail: string;
229
+ cc: string[];
230
+ };
231
+ export type EmailToRule = {
232
+ projectExid: string;
233
+ to: string[];
234
+ };
235
+ export type EmailingSettings = {
236
+ ccByCsm?: EmailCcRule[];
237
+ defaultCc?: string[];
238
+ toByProject?: EmailToRule[];
239
+ };
180
240
  export type UserStatsResponse = {
181
241
  data: {
182
242
  userStats: AdminUser;
@@ -185,10 +245,12 @@ export type UserStatsResponse = {
185
245
  export type UserCamera = {
186
246
  id: number;
187
247
  exid: string;
248
+ name: string;
188
249
  ownerFullname: string;
189
250
  ownerEmail: string;
190
251
  apiId: string;
191
252
  apiKey: string;
253
+ projectId: string;
192
254
  };
193
255
  export type UserCameraResponse = {
194
256
  data: UserCamera[];
@@ -197,7 +259,7 @@ export type UserProject = {
197
259
  id: number;
198
260
  exid: string;
199
261
  name: string;
200
- startedAt: DateTime;
262
+ startedAt: string;
201
263
  };
202
264
  export type UserProjectResponse = {
203
265
  data: UserProject[];
@@ -217,32 +279,16 @@ export type Admin = {
217
279
  id: number;
218
280
  fullname: string;
219
281
  email: string;
220
- createdAt: DateTime;
221
- updatedAt: DateTime;
222
- lastSignInAt: DateTime;
282
+ createdAt: string;
283
+ updatedAt: string;
284
+ lastLoginAt: string;
223
285
  signInCount: number;
224
286
  lastSignInIp: string;
225
287
  apiId: string;
226
288
  apiKey: string;
289
+ roles?: string[];
227
290
  };
228
291
  export type ImpersonateUserResponse = {
229
- id: string;
230
- firstname: string;
231
- lastname: string;
232
- telephone: string;
233
- email: string;
234
- is_admin: boolean;
235
- persona: Persona;
236
- country: string;
237
- companyId: number;
238
- companyExid: string;
239
- companyName: string;
240
- evercamAccount: boolean;
241
- createdAt: DateTime;
242
- updatedAt: DateTime;
243
- confirmedAt: DateTime;
244
- last_loginAt: DateTime;
245
- features: UserFeatureFlag[];
246
292
  token: string;
247
293
  };
248
294
  export type AdminUserQueryParams = PaginationParams & {
@@ -251,13 +297,13 @@ export type AdminUserQueryParams = PaginationParams & {
251
297
  telephone: string;
252
298
  persona: Persona;
253
299
  companyName: string;
300
+ countryName: string;
301
+ countryId: number;
302
+ sessionCount: string;
254
303
  camerasCount: string;
255
304
  projectsCount: string;
256
305
  snapmailCount: string;
257
306
  camerasOwned: string;
258
- cameraShares: string;
259
- createdAtDate: string;
260
- lastLoginAtDate: string;
261
307
  integrations: "procore" | "aconex" | "autodesk";
262
308
  features: UserFeatureFlag.ProjectSharing | UserFeatureFlag.VideoWalls;
263
309
  };
@@ -270,6 +316,45 @@ export type Suppression = {
270
316
  id: number;
271
317
  email: string;
272
318
  source: string;
273
- insertedAt: DateTime;
274
- updatedAt: DateTime;
319
+ insertedAt: string;
320
+ updatedAt: string;
321
+ };
322
+ type Email = string;
323
+ export type WsAccessRestrictionUpdate = {
324
+ camera_id: CameraExid;
325
+ is_access_restricted: boolean;
326
+ };
327
+ export type WsUserRestrictionItem = {
328
+ user_id: number;
329
+ camera_id: CameraExid;
330
+ is_user_access_restricted: boolean;
331
+ };
332
+ export type WsUserRestrictionUpdate = WsUserRestrictionItem[];
333
+ /**
334
+ * Backend WebSocket event payload:
335
+ * {
336
+ * user: {
337
+ * "someone@domain.com": {camera_id, is_access_restricted} OR [{...}, {...}]
338
+ * }
339
+ * }
340
+ */
341
+ export type WsRestrictionChangedPayload = {
342
+ user: Record<Email, WsAccessRestrictionUpdate | WsUserRestrictionUpdate>;
343
+ };
344
+ export type ProjectUserWithRole = {
345
+ id: number;
346
+ email: string;
347
+ fullname: string;
348
+ company: {
349
+ id: number;
350
+ name: string;
351
+ exid: string;
352
+ } | null;
353
+ persona: Persona;
354
+ permissions: string[];
355
+ role: Role;
356
+ subRoles: RoleSubRole[];
357
+ lastSeenAt: string | null;
358
+ telephone: string | null;
275
359
  };
360
+ export {};
@@ -1,25 +1,16 @@
1
- import { Camera, Media, PaginationParams } from "@/types";
1
+ import { Camera, Media, PaginationParams } from "@evercam/api/types";
2
2
  export declare enum VideoWallItemType {
3
3
  LiveView = "live",
4
4
  Video = "video",
5
5
  Image = "image"
6
6
  }
7
- export type VideoWallItem<T extends Camera | Media> = {
7
+ export type VideoWallItem<T extends Camera | Media = Camera> = {
8
8
  value: T;
9
9
  type: VideoWallItemType;
10
10
  };
11
- export type VideoWallPresetItemConfig = {
12
- camera: Camera;
13
- h: number;
14
- i: string | number;
15
- moved: boolean;
16
- w: number;
17
- x: number;
18
- y: number;
19
- };
20
- export type VideoWallPreset = {
21
- name?: string;
22
- configuration: Array<VideoWallPresetItemConfig>;
11
+ export type VideoWallPresetGridConfig = {
12
+ items: VideoWallPresetItem[];
13
+ meta?: VideoWallPresetMeta;
23
14
  };
24
15
  export type VideoWallPresetItem = {
25
16
  i: string | number;
@@ -30,6 +21,14 @@ export type VideoWallPresetItem = {
30
21
  camera: Camera;
31
22
  weather?: Record<string, unknown>;
32
23
  media?: Media;
24
+ moved?: boolean;
25
+ };
26
+ export type VideoWallPresetMeta = {
27
+ colNum: number;
28
+ rowCount: number;
29
+ tile: number;
30
+ template: string;
31
+ gridSize: number;
33
32
  };
34
33
  export type VideoWallSource = "default" | "widget";
35
34
  export interface VideoWall {
@@ -38,8 +37,8 @@ export interface VideoWall {
38
37
  name: string;
39
38
  source: VideoWallSource;
40
39
  config: Record<string, any>;
41
- inserted_at: string;
42
- updated_at: string;
40
+ insertedAt: string;
41
+ updatedAt: string;
43
42
  user: {
44
43
  id: number;
45
44
  firstname: string;
@@ -47,20 +46,21 @@ export interface VideoWall {
47
46
  email: string;
48
47
  };
49
48
  }
50
- export interface ListParams extends PaginationParams {
51
- project_exid?: string;
49
+ export interface VideoWallListParams extends PaginationParams {
50
+ projectExid?: string;
52
51
  id?: number;
53
52
  exid?: string;
54
- project_id?: number;
55
- user_id?: number;
53
+ projectId?: number;
54
+ userId?: number;
56
55
  name?: string;
57
56
  project?: string;
58
57
  user?: string;
59
58
  source?: VideoWallSource;
60
59
  }
61
60
  export type VideoWallCreateUpdatePayload = {
62
- project_exid: string;
61
+ projectExid?: string;
63
62
  name: string;
64
63
  source?: VideoWallSource;
65
64
  config: Record<string, unknown>;
65
+ scope?: string;
66
66
  };
@@ -1,31 +1,95 @@
1
- import { Date_YYYY_MM_DD, DateType } from "@/types/time";
1
+ import { DateType } from "@evercam/api/types/time";
2
2
  export type HistoryWeatherRequestPayload = {
3
3
  day: string;
4
4
  provider: WeatherProvider;
5
5
  };
6
+ export type WeatherReportParams = {
7
+ startDate: string;
8
+ endDate: string;
9
+ weatherConditionIds?: number[];
10
+ minMinTemp?: number;
11
+ maxMinTemp?: number;
12
+ minMaxTemp?: number;
13
+ maxMaxTemp?: number;
14
+ minMinPrecip?: number;
15
+ maxMinPrecip?: number;
16
+ minMaxPrecip?: number;
17
+ maxMaxPrecip?: number;
18
+ minMinWindSpeed?: number;
19
+ maxMinWindSpeed?: number;
20
+ minMaxWindSpeed?: number;
21
+ maxMaxWindSpeed?: number;
22
+ minMinHumidity?: number;
23
+ maxMinHumidity?: number;
24
+ minMaxHumidity?: number;
25
+ maxMaxHumidity?: number;
26
+ minMinPressure?: number;
27
+ maxMinPressure?: number;
28
+ minMaxPressure?: number;
29
+ maxMaxPressure?: number;
30
+ minMinClouds?: number;
31
+ maxMinClouds?: number;
32
+ minMaxClouds?: number;
33
+ maxMaxClouds?: number;
34
+ minMaxUvIndex?: number;
35
+ maxMaxUvIndex?: number;
36
+ };
37
+ export declare enum WeatherReportScope {
38
+ Daily = "daily"
39
+ }
40
+ export type WeatherReportRequestPayload = WeatherReportParams & {
41
+ scope: WeatherReportScope;
42
+ includeRecent: boolean;
43
+ };
6
44
  export type CurrentWeatherRequestPayload = {
7
45
  provider: WeatherProvider;
8
46
  includeForecast?: boolean;
9
47
  forecastDays?: number;
10
48
  };
11
- export type WeatherResponsePayload = Array<{
12
- hour?: number;
13
- temp?: number;
49
+ export type WeatherHourlyItem = {
50
+ chanceoffog: number;
51
+ chanceoffrost: number;
52
+ chanceofhightemp: number;
53
+ chanceofovercast: number;
54
+ chanceofrain: number;
55
+ chanceofremdry: number;
56
+ chanceofsnow: number;
57
+ chanceofsunshine: number;
58
+ chanceofthunder: number;
59
+ chanceofwindy: number;
14
60
  clouds?: number;
61
+ dewpoint: number;
15
62
  feelsLike?: number;
16
- pressure?: number;
63
+ heatindex: number;
64
+ hour?: number;
17
65
  humidity?: number;
18
- windSpeed?: number;
19
- windDegree?: number;
20
- weather?: [WeatherSummary];
66
+ isRequestedWeather?: boolean;
67
+ precip: number;
68
+ pressure?: number;
21
69
  rain?: HourlyReading;
22
70
  snow?: HourlyReading;
23
- }>;
71
+ source: string;
72
+ temp?: number;
73
+ uvIndex: number;
74
+ weather?: WeatherSummary;
75
+ windchill: number;
76
+ windDegree?: number;
77
+ windDir: string;
78
+ windgust: number;
79
+ windSpeed?: number;
80
+ wind?: {
81
+ speed: number;
82
+ };
83
+ };
84
+ export type WeatherResponsePayload = Array<WeatherHourlyItem>;
24
85
  export type WeatherSummary = {
25
86
  id?: number;
26
87
  main?: string;
27
88
  description?: string;
28
- icon?: string;
89
+ temperature?: number;
90
+ icon?: string | string[];
91
+ weatherIndex?: number;
92
+ rain?: HourlyReading;
29
93
  };
30
94
  export type HourlyReading = {
31
95
  "1h"?: number;
@@ -78,7 +142,7 @@ export type WeatherDataResponse = {
78
142
  uvIndex: number;
79
143
  maxHeatindex: number;
80
144
  minTemp: number;
81
- date: Date_YYYY_MM_DD;
145
+ date: string;
82
146
  totalsnow: number;
83
147
  maxPressure: number;
84
148
  maxWindchill: number;