@tmlmobilidade/types 20250909.1559.44 → 20250910.1526.7

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 (37) hide show
  1. package/dist/src/_common/comment.d.ts +247 -16
  2. package/dist/src/_common/comment.js +36 -5
  3. package/dist/src/_common/document.d.ts +14 -8
  4. package/dist/src/_common/document.js +5 -3
  5. package/dist/src/_common/proposed-change.d.ts +37 -19
  6. package/dist/src/_common/unix-timestamp.d.ts +1 -1
  7. package/dist/src/_common/unix-timestamp.js +1 -2
  8. package/dist/src/agency.d.ts +30 -12
  9. package/dist/src/alert.d.ts +52 -59
  10. package/dist/src/auth/role.d.ts +30 -12
  11. package/dist/src/auth/session.d.ts +30 -12
  12. package/dist/src/auth/user.d.ts +30 -12
  13. package/dist/src/auth/verification-token.d.ts +30 -12
  14. package/dist/src/file.d.ts +23 -23
  15. package/dist/src/organization.d.ts +30 -12
  16. package/dist/src/plans/gtfs-validation.d.ts +30 -12
  17. package/dist/src/plans/plan.d.ts +30 -12
  18. package/dist/src/rides/index.d.ts +2 -1
  19. package/dist/src/rides/index.js +2 -1
  20. package/dist/src/rides/ride-audit.d.ts +729 -0
  21. package/dist/src/rides/ride-audit.js +12 -0
  22. package/dist/src/rides/ride-justification.d.ts +959 -0
  23. package/dist/src/rides/ride-justification.js +64 -0
  24. package/dist/src/rides/ride-overrides.d.ts +9 -0
  25. package/dist/src/rides/ride-overrides.js +6 -0
  26. package/dist/src/rides/ride.d.ts +38 -20
  27. package/dist/src/sams/sam.d.ts +30 -12
  28. package/dist/src/simplified-apex/simplified-apex-location.d.ts +32 -24
  29. package/dist/src/simplified-apex/simplified-apex-on-board-refund.d.ts +32 -24
  30. package/dist/src/simplified-apex/simplified-apex-on-board-sale.d.ts +32 -24
  31. package/dist/src/simplified-apex/simplified-apex-validation.d.ts +36 -28
  32. package/dist/src/stop.d.ts +713 -188
  33. package/dist/src/vehicle-event.d.ts +18 -12
  34. package/dist/src/zone.d.ts +24 -6
  35. package/package.json +1 -1
  36. package/dist/src/rides/ride-annotation.d.ts +0 -579
  37. package/dist/src/rides/ride-annotation.js +0 -34
@@ -10,8 +10,10 @@ export declare const facilitiesSchema: z.ZodEnum<["fire_station", "health_clinic
10
10
  export declare const hasAnySchema: z.ZodEnum<["yes", "no", "unknown"]>;
11
11
  export declare const equipmentSchema: z.ZodEnum<["pip", "mupi", "mini_pip"]>;
12
12
  export declare const StopSchema: z.ZodObject<{
13
- created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
14
- updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
13
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
14
+ created_by: z.ZodDefault<z.ZodString>;
15
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
16
+ updated_by: z.ZodDefault<z.ZodString>;
15
17
  } & {
16
18
  _id: z.ZodString;
17
19
  is_archived: z.ZodDefault<z.ZodBoolean>;
@@ -35,15 +37,15 @@ export declare const StopSchema: z.ZodObject<{
35
37
  road_type: z.ZodEnum<["complementary_itinerary", "highway", "main_itinerary", "national_road", "regional_road", "secondary_road", "unknown"]>;
36
38
  shelter_code: z.ZodOptional<z.ZodNullable<z.ZodString>>;
37
39
  shelter_frame_size: z.ZodOptional<z.ZodNullable<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
38
- shelter_installation_date: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
40
+ shelter_installation_date: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
39
41
  shelter_maintainer: z.ZodOptional<z.ZodNullable<z.ZodString>>;
40
42
  shelter_make: z.ZodOptional<z.ZodNullable<z.ZodString>>;
41
43
  shelter_model: z.ZodOptional<z.ZodNullable<z.ZodString>>;
42
44
  shelter_status: z.ZodEnum<["not_applicable", "unknown", "missing", "damaged", "ok"]>;
43
- last_infrastructure_check: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
44
- last_infrastructure_maintenance: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
45
- last_schedules_check: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
46
- last_schedules_maintenance: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
45
+ last_infrastructure_check: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
46
+ last_infrastructure_maintenance: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
47
+ last_schedules_check: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
48
+ last_schedules_maintenance: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
47
49
  connections: z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">;
48
50
  facilities: z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "beach"]>, "many">;
49
51
  equipment: z.ZodArray<z.ZodEnum<["pip", "mupi", "mini_pip"]>, "many">;
@@ -55,33 +57,170 @@ export declare const StopSchema: z.ZodObject<{
55
57
  has_stop_sign: z.ZodEnum<["yes", "no", "unknown"]>;
56
58
  file_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
57
59
  image_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
58
- comments: z.ZodArray<z.ZodObject<{
59
- created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
60
- updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
60
+ comments: z.ZodArray<z.ZodEffects<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
61
+ _id: z.ZodString;
62
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
63
+ created_by: z.ZodDefault<z.ZodString>;
64
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
65
+ updated_by: z.ZodDefault<z.ZodString>;
61
66
  } & {
67
+ message: z.ZodString;
68
+ type: z.ZodLiteral<"note">;
69
+ }, "strip", z.ZodTypeAny, {
70
+ _id: string;
71
+ created_at: number & {
72
+ __brand: "UnixTimestamp";
73
+ };
74
+ created_by: string;
75
+ updated_at: number & {
76
+ __brand: "UnixTimestamp";
77
+ };
78
+ updated_by: string;
79
+ message: string;
80
+ type: "note";
81
+ }, {
82
+ _id: string;
83
+ created_at: number;
84
+ updated_at: number;
85
+ message: string;
86
+ type: "note";
87
+ created_by?: string | undefined;
88
+ updated_by?: string | undefined;
89
+ }>, z.ZodObject<{
90
+ _id: z.ZodString;
91
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
92
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
93
+ } & {
94
+ created_by: z.ZodLiteral<"system">;
95
+ message: z.ZodString;
96
+ type: z.ZodLiteral<"system_info">;
97
+ updated_by: z.ZodLiteral<"system">;
98
+ }, "strip", z.ZodTypeAny, {
99
+ _id: string;
100
+ created_at: number & {
101
+ __brand: "UnixTimestamp";
102
+ };
103
+ created_by: "system";
104
+ updated_at: number & {
105
+ __brand: "UnixTimestamp";
106
+ };
107
+ updated_by: "system";
108
+ message: string;
109
+ type: "system_info";
110
+ }, {
111
+ _id: string;
112
+ created_at: number;
113
+ created_by: "system";
114
+ updated_at: number;
115
+ updated_by: "system";
116
+ message: string;
117
+ type: "system_info";
118
+ }>, z.ZodObject<{
62
119
  _id: z.ZodString;
63
- text: z.ZodString;
64
- user_id: z.ZodString;
65
- }, "strict", z.ZodTypeAny, {
120
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
121
+ created_by: z.ZodDefault<z.ZodString>;
122
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
123
+ updated_by: z.ZodDefault<z.ZodString>;
124
+ } & {
125
+ curr_status: z.ZodString;
126
+ prev_status: z.ZodString;
127
+ type: z.ZodLiteral<"statusChanged">;
128
+ }, "strip", z.ZodTypeAny, {
129
+ _id: string;
130
+ created_at: number & {
131
+ __brand: "UnixTimestamp";
132
+ };
133
+ created_by: string;
134
+ updated_at: number & {
135
+ __brand: "UnixTimestamp";
136
+ };
137
+ updated_by: string;
138
+ type: "statusChanged";
139
+ curr_status: string;
140
+ prev_status: string;
141
+ }, {
66
142
  _id: string;
67
- text: string;
68
- user_id: string;
69
- created_at?: (number & {
143
+ created_at: number;
144
+ updated_at: number;
145
+ type: "statusChanged";
146
+ curr_status: string;
147
+ prev_status: string;
148
+ created_by?: string | undefined;
149
+ updated_by?: string | undefined;
150
+ }>]>, {
151
+ _id: string;
152
+ created_at: number & {
153
+ __brand: "UnixTimestamp";
154
+ };
155
+ created_by: string;
156
+ updated_at: number & {
70
157
  __brand: "UnixTimestamp";
71
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
72
- updated_at?: (number & {
158
+ };
159
+ updated_by: string;
160
+ message: string;
161
+ type: "note";
162
+ } | {
163
+ _id: string;
164
+ created_at: number & {
73
165
  __brand: "UnixTimestamp";
74
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
166
+ };
167
+ created_by: "system";
168
+ updated_at: number & {
169
+ __brand: "UnixTimestamp";
170
+ };
171
+ updated_by: "system";
172
+ message: string;
173
+ type: "system_info";
174
+ } | {
175
+ _id: string;
176
+ created_at: number & {
177
+ __brand: "UnixTimestamp";
178
+ };
179
+ created_by: string;
180
+ updated_at: number & {
181
+ __brand: "UnixTimestamp";
182
+ };
183
+ updated_by: string;
184
+ type: "statusChanged";
185
+ curr_status: string;
186
+ prev_status: string;
75
187
  }, {
76
188
  _id: string;
77
- text: string;
78
- user_id: string;
79
- created_at?: number | null | undefined;
80
- updated_at?: number | null | undefined;
189
+ created_at: number;
190
+ updated_at: number;
191
+ message: string;
192
+ type: "note";
193
+ created_by?: string | undefined;
194
+ updated_by?: string | undefined;
195
+ } | {
196
+ _id: string;
197
+ created_at: number;
198
+ created_by: "system";
199
+ updated_at: number;
200
+ updated_by: "system";
201
+ message: string;
202
+ type: "system_info";
203
+ } | {
204
+ _id: string;
205
+ created_at: number;
206
+ updated_at: number;
207
+ type: "statusChanged";
208
+ curr_status: string;
209
+ prev_status: string;
210
+ created_by?: string | undefined;
211
+ updated_by?: string | undefined;
81
212
  }>, "many">;
82
213
  observations: z.ZodOptional<z.ZodNullable<z.ZodString>>;
83
214
  }, "strict", z.ZodTypeAny, {
84
215
  _id: string;
216
+ created_at: number & {
217
+ __brand: "UnixTimestamp";
218
+ };
219
+ created_by: string;
220
+ updated_at: number & {
221
+ __brand: "UnixTimestamp";
222
+ };
223
+ updated_by: string;
85
224
  name: string;
86
225
  has_bench: "unknown" | "yes" | "no";
87
226
  has_network_map: "unknown" | "yes" | "no";
@@ -90,18 +229,44 @@ export declare const StopSchema: z.ZodObject<{
90
229
  has_stop_sign: "unknown" | "yes" | "no";
91
230
  municipality_id: string;
92
231
  is_locked: boolean;
93
- comments: {
232
+ comments: ({
94
233
  _id: string;
95
- text: string;
96
- user_id: string;
97
- created_at?: (number & {
234
+ created_at: number & {
98
235
  __brand: "UnixTimestamp";
99
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
100
- updated_at?: (number & {
236
+ };
237
+ created_by: string;
238
+ updated_at: number & {
101
239
  __brand: "UnixTimestamp";
102
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
103
- }[];
104
- file_ids: string[];
240
+ };
241
+ updated_by: string;
242
+ message: string;
243
+ type: "note";
244
+ } | {
245
+ _id: string;
246
+ created_at: number & {
247
+ __brand: "UnixTimestamp";
248
+ };
249
+ created_by: "system";
250
+ updated_at: number & {
251
+ __brand: "UnixTimestamp";
252
+ };
253
+ updated_by: "system";
254
+ message: string;
255
+ type: "system_info";
256
+ } | {
257
+ _id: string;
258
+ created_at: number & {
259
+ __brand: "UnixTimestamp";
260
+ };
261
+ created_by: string;
262
+ updated_at: number & {
263
+ __brand: "UnixTimestamp";
264
+ };
265
+ updated_by: string;
266
+ type: "statusChanged";
267
+ curr_status: string;
268
+ prev_status: string;
269
+ })[];
105
270
  is_archived: boolean;
106
271
  jurisdiction: "unknown" | "ip" | "municipality" | "other";
107
272
  operational_status: "active" | "inactive" | "provisional" | "seasonal" | "voided";
@@ -117,13 +282,8 @@ export declare const StopSchema: z.ZodObject<{
117
282
  facilities: ("school" | "fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "shopping" | "transit_office" | "university" | "beach")[];
118
283
  equipment: ("pip" | "mupi" | "mini_pip")[];
119
284
  has_mupi: "unknown" | "yes" | "no";
285
+ file_ids: string[];
120
286
  image_ids: string[];
121
- created_at?: (number & {
122
- __brand: "UnixTimestamp";
123
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
124
- updated_at?: (number & {
125
- __brand: "UnixTimestamp";
126
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
127
287
  short_name?: string | null | undefined;
128
288
  parish_id?: string | null | undefined;
129
289
  shelter_code?: string | null | undefined;
@@ -133,26 +293,18 @@ export declare const StopSchema: z.ZodObject<{
133
293
  tts_name?: string | null | undefined;
134
294
  locality_id?: string | null | undefined;
135
295
  shelter_frame_size?: [number, number] | null | undefined;
136
- shelter_installation_date?: (number & {
137
- __brand: "UnixTimestamp";
138
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
296
+ shelter_installation_date?: UnixTimestamp | null | undefined;
139
297
  shelter_make?: string | null | undefined;
140
298
  shelter_model?: string | null | undefined;
141
- last_infrastructure_check?: (number & {
142
- __brand: "UnixTimestamp";
143
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
144
- last_infrastructure_maintenance?: (number & {
145
- __brand: "UnixTimestamp";
146
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
147
- last_schedules_check?: (number & {
148
- __brand: "UnixTimestamp";
149
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
150
- last_schedules_maintenance?: (number & {
151
- __brand: "UnixTimestamp";
152
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
299
+ last_infrastructure_check?: UnixTimestamp | null | undefined;
300
+ last_infrastructure_maintenance?: UnixTimestamp | null | undefined;
301
+ last_schedules_check?: UnixTimestamp | null | undefined;
302
+ last_schedules_maintenance?: UnixTimestamp | null | undefined;
153
303
  observations?: string | null | undefined;
154
304
  }, {
155
305
  _id: string;
306
+ created_at: number;
307
+ updated_at: number;
156
308
  name: string;
157
309
  has_bench: "unknown" | "yes" | "no";
158
310
  has_network_map: "unknown" | "yes" | "no";
@@ -160,13 +312,32 @@ export declare const StopSchema: z.ZodObject<{
160
312
  has_shelter: "unknown" | "yes" | "no";
161
313
  has_stop_sign: "unknown" | "yes" | "no";
162
314
  municipality_id: string;
163
- comments: {
315
+ comments: ({
316
+ _id: string;
317
+ created_at: number;
318
+ updated_at: number;
319
+ message: string;
320
+ type: "note";
321
+ created_by?: string | undefined;
322
+ updated_by?: string | undefined;
323
+ } | {
164
324
  _id: string;
165
- text: string;
166
- user_id: string;
167
- created_at?: number | null | undefined;
168
- updated_at?: number | null | undefined;
169
- }[];
325
+ created_at: number;
326
+ created_by: "system";
327
+ updated_at: number;
328
+ updated_by: "system";
329
+ message: string;
330
+ type: "system_info";
331
+ } | {
332
+ _id: string;
333
+ created_at: number;
334
+ updated_at: number;
335
+ type: "statusChanged";
336
+ curr_status: string;
337
+ prev_status: string;
338
+ created_by?: string | undefined;
339
+ updated_by?: string | undefined;
340
+ })[];
170
341
  jurisdiction: "unknown" | "ip" | "municipality" | "other";
171
342
  operational_status: "active" | "inactive" | "provisional" | "seasonal" | "voided";
172
343
  district_id: string;
@@ -181,14 +352,13 @@ export declare const StopSchema: z.ZodObject<{
181
352
  facilities: ("school" | "fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "shopping" | "transit_office" | "university" | "beach")[];
182
353
  equipment: ("pip" | "mupi" | "mini_pip")[];
183
354
  has_mupi: "unknown" | "yes" | "no";
184
- created_at?: number | null | undefined;
185
- updated_at?: number | null | undefined;
355
+ created_by?: string | undefined;
356
+ updated_by?: string | undefined;
186
357
  short_name?: string | null | undefined;
187
358
  parish_id?: string | null | undefined;
188
359
  shelter_code?: string | null | undefined;
189
360
  shelter_maintainer?: string | null | undefined;
190
361
  is_locked?: boolean | undefined;
191
- file_ids?: string[] | undefined;
192
362
  is_archived?: boolean | undefined;
193
363
  legacy_id?: string | null | undefined;
194
364
  new_name?: string | null | undefined;
@@ -202,53 +372,66 @@ export declare const StopSchema: z.ZodObject<{
202
372
  last_infrastructure_maintenance?: number | null | undefined;
203
373
  last_schedules_check?: number | null | undefined;
204
374
  last_schedules_maintenance?: number | null | undefined;
375
+ file_ids?: string[] | undefined;
205
376
  image_ids?: string[] | undefined;
206
377
  observations?: string | null | undefined;
207
378
  }>;
208
379
  export declare const parentStationSchema: z.ZodObject<{
209
- created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
210
- updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
380
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
381
+ created_by: z.ZodDefault<z.ZodString>;
382
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
383
+ updated_by: z.ZodDefault<z.ZodString>;
211
384
  } & {
212
385
  _id: z.ZodString;
213
386
  agency_id: z.ZodString;
214
387
  stop_ids: z.ZodArray<z.ZodString, "many">;
215
388
  }, "strict", z.ZodTypeAny, {
216
389
  _id: string;
217
- agency_id: string;
218
- stop_ids: string[];
219
- created_at?: (number & {
390
+ created_at: number & {
220
391
  __brand: "UnixTimestamp";
221
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
222
- updated_at?: (number & {
392
+ };
393
+ created_by: string;
394
+ updated_at: number & {
223
395
  __brand: "UnixTimestamp";
224
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
396
+ };
397
+ updated_by: string;
398
+ agency_id: string;
399
+ stop_ids: string[];
225
400
  }, {
226
401
  _id: string;
402
+ created_at: number;
403
+ updated_at: number;
227
404
  agency_id: string;
228
405
  stop_ids: string[];
229
- created_at?: number | null | undefined;
230
- updated_at?: number | null | undefined;
406
+ created_by?: string | undefined;
407
+ updated_by?: string | undefined;
231
408
  }>;
232
409
  export declare const stopAreaSchema: z.ZodObject<{
233
- created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
234
- updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
410
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
411
+ created_by: z.ZodDefault<z.ZodString>;
412
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
413
+ updated_by: z.ZodDefault<z.ZodString>;
235
414
  } & {
236
415
  _id: z.ZodString;
237
416
  parent_station_ids: z.ZodArray<z.ZodString, "many">;
238
417
  }, "strict", z.ZodTypeAny, {
239
418
  _id: string;
240
- parent_station_ids: string[];
241
- created_at?: (number & {
419
+ created_at: number & {
242
420
  __brand: "UnixTimestamp";
243
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
244
- updated_at?: (number & {
421
+ };
422
+ created_by: string;
423
+ updated_at: number & {
245
424
  __brand: "UnixTimestamp";
246
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
425
+ };
426
+ updated_by: string;
427
+ parent_station_ids: string[];
247
428
  }, {
248
429
  _id: string;
430
+ created_at: number;
431
+ updated_at: number;
249
432
  parent_station_ids: string[];
250
- created_at?: number | null | undefined;
251
- updated_at?: number | null | undefined;
433
+ created_by?: string | undefined;
434
+ updated_by?: string | undefined;
252
435
  }>;
253
436
  export type Jurisdiction = z.infer<typeof jurisdictionSchema>;
254
437
  export type OperationalStatus = z.infer<typeof operationalStatusSchema>;
@@ -259,8 +442,10 @@ export type Connections = z.infer<typeof connectionsSchema>;
259
442
  export type Facilities = z.infer<typeof facilitiesSchema>;
260
443
  export type Equipment = z.infer<typeof equipmentSchema>;
261
444
  export declare const CreateStopSchema: z.ZodObject<Omit<{
262
- created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
263
- updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
445
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
446
+ created_by: z.ZodDefault<z.ZodString>;
447
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
448
+ updated_by: z.ZodDefault<z.ZodString>;
264
449
  } & {
265
450
  _id: z.ZodString;
266
451
  is_archived: z.ZodDefault<z.ZodBoolean>;
@@ -284,15 +469,15 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
284
469
  road_type: z.ZodEnum<["complementary_itinerary", "highway", "main_itinerary", "national_road", "regional_road", "secondary_road", "unknown"]>;
285
470
  shelter_code: z.ZodOptional<z.ZodNullable<z.ZodString>>;
286
471
  shelter_frame_size: z.ZodOptional<z.ZodNullable<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
287
- shelter_installation_date: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
472
+ shelter_installation_date: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
288
473
  shelter_maintainer: z.ZodOptional<z.ZodNullable<z.ZodString>>;
289
474
  shelter_make: z.ZodOptional<z.ZodNullable<z.ZodString>>;
290
475
  shelter_model: z.ZodOptional<z.ZodNullable<z.ZodString>>;
291
476
  shelter_status: z.ZodEnum<["not_applicable", "unknown", "missing", "damaged", "ok"]>;
292
- last_infrastructure_check: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
293
- last_infrastructure_maintenance: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
294
- last_schedules_check: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
295
- last_schedules_maintenance: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
477
+ last_infrastructure_check: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
478
+ last_infrastructure_maintenance: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
479
+ last_schedules_check: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
480
+ last_schedules_maintenance: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>;
296
481
  connections: z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">;
297
482
  facilities: z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "beach"]>, "many">;
298
483
  equipment: z.ZodArray<z.ZodEnum<["pip", "mupi", "mini_pip"]>, "many">;
@@ -304,33 +489,164 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
304
489
  has_stop_sign: z.ZodEnum<["yes", "no", "unknown"]>;
305
490
  file_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
306
491
  image_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
307
- comments: z.ZodArray<z.ZodObject<{
308
- created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
309
- updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
492
+ comments: z.ZodArray<z.ZodEffects<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
493
+ _id: z.ZodString;
494
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
495
+ created_by: z.ZodDefault<z.ZodString>;
496
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
497
+ updated_by: z.ZodDefault<z.ZodString>;
310
498
  } & {
499
+ message: z.ZodString;
500
+ type: z.ZodLiteral<"note">;
501
+ }, "strip", z.ZodTypeAny, {
502
+ _id: string;
503
+ created_at: number & {
504
+ __brand: "UnixTimestamp";
505
+ };
506
+ created_by: string;
507
+ updated_at: number & {
508
+ __brand: "UnixTimestamp";
509
+ };
510
+ updated_by: string;
511
+ message: string;
512
+ type: "note";
513
+ }, {
514
+ _id: string;
515
+ created_at: number;
516
+ updated_at: number;
517
+ message: string;
518
+ type: "note";
519
+ created_by?: string | undefined;
520
+ updated_by?: string | undefined;
521
+ }>, z.ZodObject<{
522
+ _id: z.ZodString;
523
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
524
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
525
+ } & {
526
+ created_by: z.ZodLiteral<"system">;
527
+ message: z.ZodString;
528
+ type: z.ZodLiteral<"system_info">;
529
+ updated_by: z.ZodLiteral<"system">;
530
+ }, "strip", z.ZodTypeAny, {
531
+ _id: string;
532
+ created_at: number & {
533
+ __brand: "UnixTimestamp";
534
+ };
535
+ created_by: "system";
536
+ updated_at: number & {
537
+ __brand: "UnixTimestamp";
538
+ };
539
+ updated_by: "system";
540
+ message: string;
541
+ type: "system_info";
542
+ }, {
543
+ _id: string;
544
+ created_at: number;
545
+ created_by: "system";
546
+ updated_at: number;
547
+ updated_by: "system";
548
+ message: string;
549
+ type: "system_info";
550
+ }>, z.ZodObject<{
311
551
  _id: z.ZodString;
312
- text: z.ZodString;
313
- user_id: z.ZodString;
314
- }, "strict", z.ZodTypeAny, {
552
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
553
+ created_by: z.ZodDefault<z.ZodString>;
554
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
555
+ updated_by: z.ZodDefault<z.ZodString>;
556
+ } & {
557
+ curr_status: z.ZodString;
558
+ prev_status: z.ZodString;
559
+ type: z.ZodLiteral<"statusChanged">;
560
+ }, "strip", z.ZodTypeAny, {
561
+ _id: string;
562
+ created_at: number & {
563
+ __brand: "UnixTimestamp";
564
+ };
565
+ created_by: string;
566
+ updated_at: number & {
567
+ __brand: "UnixTimestamp";
568
+ };
569
+ updated_by: string;
570
+ type: "statusChanged";
571
+ curr_status: string;
572
+ prev_status: string;
573
+ }, {
315
574
  _id: string;
316
- text: string;
317
- user_id: string;
318
- created_at?: (number & {
575
+ created_at: number;
576
+ updated_at: number;
577
+ type: "statusChanged";
578
+ curr_status: string;
579
+ prev_status: string;
580
+ created_by?: string | undefined;
581
+ updated_by?: string | undefined;
582
+ }>]>, {
583
+ _id: string;
584
+ created_at: number & {
585
+ __brand: "UnixTimestamp";
586
+ };
587
+ created_by: string;
588
+ updated_at: number & {
319
589
  __brand: "UnixTimestamp";
320
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
321
- updated_at?: (number & {
590
+ };
591
+ updated_by: string;
592
+ message: string;
593
+ type: "note";
594
+ } | {
595
+ _id: string;
596
+ created_at: number & {
322
597
  __brand: "UnixTimestamp";
323
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
598
+ };
599
+ created_by: "system";
600
+ updated_at: number & {
601
+ __brand: "UnixTimestamp";
602
+ };
603
+ updated_by: "system";
604
+ message: string;
605
+ type: "system_info";
606
+ } | {
607
+ _id: string;
608
+ created_at: number & {
609
+ __brand: "UnixTimestamp";
610
+ };
611
+ created_by: string;
612
+ updated_at: number & {
613
+ __brand: "UnixTimestamp";
614
+ };
615
+ updated_by: string;
616
+ type: "statusChanged";
617
+ curr_status: string;
618
+ prev_status: string;
324
619
  }, {
325
620
  _id: string;
326
- text: string;
327
- user_id: string;
328
- created_at?: number | null | undefined;
329
- updated_at?: number | null | undefined;
621
+ created_at: number;
622
+ updated_at: number;
623
+ message: string;
624
+ type: "note";
625
+ created_by?: string | undefined;
626
+ updated_by?: string | undefined;
627
+ } | {
628
+ _id: string;
629
+ created_at: number;
630
+ created_by: "system";
631
+ updated_at: number;
632
+ updated_by: "system";
633
+ message: string;
634
+ type: "system_info";
635
+ } | {
636
+ _id: string;
637
+ created_at: number;
638
+ updated_at: number;
639
+ type: "statusChanged";
640
+ curr_status: string;
641
+ prev_status: string;
642
+ created_by?: string | undefined;
643
+ updated_by?: string | undefined;
330
644
  }>, "many">;
331
645
  observations: z.ZodOptional<z.ZodNullable<z.ZodString>>;
332
646
  }, "created_at" | "updated_at">, "strict", z.ZodTypeAny, {
333
647
  _id: string;
648
+ created_by: string;
649
+ updated_by: string;
334
650
  name: string;
335
651
  has_bench: "unknown" | "yes" | "no";
336
652
  has_network_map: "unknown" | "yes" | "no";
@@ -339,18 +655,44 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
339
655
  has_stop_sign: "unknown" | "yes" | "no";
340
656
  municipality_id: string;
341
657
  is_locked: boolean;
342
- comments: {
658
+ comments: ({
343
659
  _id: string;
344
- text: string;
345
- user_id: string;
346
- created_at?: (number & {
660
+ created_at: number & {
347
661
  __brand: "UnixTimestamp";
348
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
349
- updated_at?: (number & {
662
+ };
663
+ created_by: string;
664
+ updated_at: number & {
350
665
  __brand: "UnixTimestamp";
351
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
352
- }[];
353
- file_ids: string[];
666
+ };
667
+ updated_by: string;
668
+ message: string;
669
+ type: "note";
670
+ } | {
671
+ _id: string;
672
+ created_at: number & {
673
+ __brand: "UnixTimestamp";
674
+ };
675
+ created_by: "system";
676
+ updated_at: number & {
677
+ __brand: "UnixTimestamp";
678
+ };
679
+ updated_by: "system";
680
+ message: string;
681
+ type: "system_info";
682
+ } | {
683
+ _id: string;
684
+ created_at: number & {
685
+ __brand: "UnixTimestamp";
686
+ };
687
+ created_by: string;
688
+ updated_at: number & {
689
+ __brand: "UnixTimestamp";
690
+ };
691
+ updated_by: string;
692
+ type: "statusChanged";
693
+ curr_status: string;
694
+ prev_status: string;
695
+ })[];
354
696
  is_archived: boolean;
355
697
  jurisdiction: "unknown" | "ip" | "municipality" | "other";
356
698
  operational_status: "active" | "inactive" | "provisional" | "seasonal" | "voided";
@@ -366,6 +708,7 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
366
708
  facilities: ("school" | "fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "shopping" | "transit_office" | "university" | "beach")[];
367
709
  equipment: ("pip" | "mupi" | "mini_pip")[];
368
710
  has_mupi: "unknown" | "yes" | "no";
711
+ file_ids: string[];
369
712
  image_ids: string[];
370
713
  short_name?: string | null | undefined;
371
714
  parish_id?: string | null | undefined;
@@ -376,23 +719,13 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
376
719
  tts_name?: string | null | undefined;
377
720
  locality_id?: string | null | undefined;
378
721
  shelter_frame_size?: [number, number] | null | undefined;
379
- shelter_installation_date?: (number & {
380
- __brand: "UnixTimestamp";
381
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
722
+ shelter_installation_date?: UnixTimestamp | null | undefined;
382
723
  shelter_make?: string | null | undefined;
383
724
  shelter_model?: string | null | undefined;
384
- last_infrastructure_check?: (number & {
385
- __brand: "UnixTimestamp";
386
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
387
- last_infrastructure_maintenance?: (number & {
388
- __brand: "UnixTimestamp";
389
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
390
- last_schedules_check?: (number & {
391
- __brand: "UnixTimestamp";
392
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
393
- last_schedules_maintenance?: (number & {
394
- __brand: "UnixTimestamp";
395
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
725
+ last_infrastructure_check?: UnixTimestamp | null | undefined;
726
+ last_infrastructure_maintenance?: UnixTimestamp | null | undefined;
727
+ last_schedules_check?: UnixTimestamp | null | undefined;
728
+ last_schedules_maintenance?: UnixTimestamp | null | undefined;
396
729
  observations?: string | null | undefined;
397
730
  }, {
398
731
  _id: string;
@@ -403,13 +736,32 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
403
736
  has_shelter: "unknown" | "yes" | "no";
404
737
  has_stop_sign: "unknown" | "yes" | "no";
405
738
  municipality_id: string;
406
- comments: {
739
+ comments: ({
740
+ _id: string;
741
+ created_at: number;
742
+ updated_at: number;
743
+ message: string;
744
+ type: "note";
745
+ created_by?: string | undefined;
746
+ updated_by?: string | undefined;
747
+ } | {
407
748
  _id: string;
408
- text: string;
409
- user_id: string;
410
- created_at?: number | null | undefined;
411
- updated_at?: number | null | undefined;
412
- }[];
749
+ created_at: number;
750
+ created_by: "system";
751
+ updated_at: number;
752
+ updated_by: "system";
753
+ message: string;
754
+ type: "system_info";
755
+ } | {
756
+ _id: string;
757
+ created_at: number;
758
+ updated_at: number;
759
+ type: "statusChanged";
760
+ curr_status: string;
761
+ prev_status: string;
762
+ created_by?: string | undefined;
763
+ updated_by?: string | undefined;
764
+ })[];
413
765
  jurisdiction: "unknown" | "ip" | "municipality" | "other";
414
766
  operational_status: "active" | "inactive" | "provisional" | "seasonal" | "voided";
415
767
  district_id: string;
@@ -424,12 +776,13 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
424
776
  facilities: ("school" | "fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "shopping" | "transit_office" | "university" | "beach")[];
425
777
  equipment: ("pip" | "mupi" | "mini_pip")[];
426
778
  has_mupi: "unknown" | "yes" | "no";
779
+ created_by?: string | undefined;
780
+ updated_by?: string | undefined;
427
781
  short_name?: string | null | undefined;
428
782
  parish_id?: string | null | undefined;
429
783
  shelter_code?: string | null | undefined;
430
784
  shelter_maintainer?: string | null | undefined;
431
785
  is_locked?: boolean | undefined;
432
- file_ids?: string[] | undefined;
433
786
  is_archived?: boolean | undefined;
434
787
  legacy_id?: string | null | undefined;
435
788
  new_name?: string | null | undefined;
@@ -443,10 +796,13 @@ export declare const CreateStopSchema: z.ZodObject<Omit<{
443
796
  last_infrastructure_maintenance?: number | null | undefined;
444
797
  last_schedules_check?: number | null | undefined;
445
798
  last_schedules_maintenance?: number | null | undefined;
799
+ file_ids?: string[] | undefined;
446
800
  image_ids?: string[] | undefined;
447
801
  observations?: string | null | undefined;
448
802
  }>;
449
803
  export declare const UpdateStopSchema: z.ZodObject<{
804
+ created_by: z.ZodOptional<z.ZodDefault<z.ZodString>>;
805
+ updated_by: z.ZodOptional<z.ZodDefault<z.ZodString>>;
450
806
  name: z.ZodOptional<z.ZodString>;
451
807
  short_name: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
452
808
  has_bench: z.ZodOptional<z.ZodEnum<["yes", "no", "unknown"]>>;
@@ -459,31 +815,159 @@ export declare const UpdateStopSchema: z.ZodObject<{
459
815
  shelter_code: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
460
816
  shelter_maintainer: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
461
817
  is_locked: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
462
- comments: z.ZodOptional<z.ZodArray<z.ZodObject<{
463
- created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
464
- updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
818
+ comments: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
819
+ _id: z.ZodString;
820
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
821
+ created_by: z.ZodDefault<z.ZodString>;
822
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
823
+ updated_by: z.ZodDefault<z.ZodString>;
465
824
  } & {
825
+ message: z.ZodString;
826
+ type: z.ZodLiteral<"note">;
827
+ }, "strip", z.ZodTypeAny, {
828
+ _id: string;
829
+ created_at: number & {
830
+ __brand: "UnixTimestamp";
831
+ };
832
+ created_by: string;
833
+ updated_at: number & {
834
+ __brand: "UnixTimestamp";
835
+ };
836
+ updated_by: string;
837
+ message: string;
838
+ type: "note";
839
+ }, {
840
+ _id: string;
841
+ created_at: number;
842
+ updated_at: number;
843
+ message: string;
844
+ type: "note";
845
+ created_by?: string | undefined;
846
+ updated_by?: string | undefined;
847
+ }>, z.ZodObject<{
848
+ _id: z.ZodString;
849
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
850
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
851
+ } & {
852
+ created_by: z.ZodLiteral<"system">;
853
+ message: z.ZodString;
854
+ type: z.ZodLiteral<"system_info">;
855
+ updated_by: z.ZodLiteral<"system">;
856
+ }, "strip", z.ZodTypeAny, {
857
+ _id: string;
858
+ created_at: number & {
859
+ __brand: "UnixTimestamp";
860
+ };
861
+ created_by: "system";
862
+ updated_at: number & {
863
+ __brand: "UnixTimestamp";
864
+ };
865
+ updated_by: "system";
866
+ message: string;
867
+ type: "system_info";
868
+ }, {
869
+ _id: string;
870
+ created_at: number;
871
+ created_by: "system";
872
+ updated_at: number;
873
+ updated_by: "system";
874
+ message: string;
875
+ type: "system_info";
876
+ }>, z.ZodObject<{
466
877
  _id: z.ZodString;
467
- text: z.ZodString;
468
- user_id: z.ZodString;
469
- }, "strict", z.ZodTypeAny, {
878
+ created_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
879
+ created_by: z.ZodDefault<z.ZodString>;
880
+ updated_at: z.ZodEffects<z.ZodNumber, UnixTimestamp, number>;
881
+ updated_by: z.ZodDefault<z.ZodString>;
882
+ } & {
883
+ curr_status: z.ZodString;
884
+ prev_status: z.ZodString;
885
+ type: z.ZodLiteral<"statusChanged">;
886
+ }, "strip", z.ZodTypeAny, {
887
+ _id: string;
888
+ created_at: number & {
889
+ __brand: "UnixTimestamp";
890
+ };
891
+ created_by: string;
892
+ updated_at: number & {
893
+ __brand: "UnixTimestamp";
894
+ };
895
+ updated_by: string;
896
+ type: "statusChanged";
897
+ curr_status: string;
898
+ prev_status: string;
899
+ }, {
900
+ _id: string;
901
+ created_at: number;
902
+ updated_at: number;
903
+ type: "statusChanged";
904
+ curr_status: string;
905
+ prev_status: string;
906
+ created_by?: string | undefined;
907
+ updated_by?: string | undefined;
908
+ }>]>, {
470
909
  _id: string;
471
- text: string;
472
- user_id: string;
473
- created_at?: (number & {
910
+ created_at: number & {
474
911
  __brand: "UnixTimestamp";
475
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
476
- updated_at?: (number & {
912
+ };
913
+ created_by: string;
914
+ updated_at: number & {
477
915
  __brand: "UnixTimestamp";
478
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
916
+ };
917
+ updated_by: string;
918
+ message: string;
919
+ type: "note";
920
+ } | {
921
+ _id: string;
922
+ created_at: number & {
923
+ __brand: "UnixTimestamp";
924
+ };
925
+ created_by: "system";
926
+ updated_at: number & {
927
+ __brand: "UnixTimestamp";
928
+ };
929
+ updated_by: "system";
930
+ message: string;
931
+ type: "system_info";
932
+ } | {
933
+ _id: string;
934
+ created_at: number & {
935
+ __brand: "UnixTimestamp";
936
+ };
937
+ created_by: string;
938
+ updated_at: number & {
939
+ __brand: "UnixTimestamp";
940
+ };
941
+ updated_by: string;
942
+ type: "statusChanged";
943
+ curr_status: string;
944
+ prev_status: string;
479
945
  }, {
480
946
  _id: string;
481
- text: string;
482
- user_id: string;
483
- created_at?: number | null | undefined;
484
- updated_at?: number | null | undefined;
947
+ created_at: number;
948
+ updated_at: number;
949
+ message: string;
950
+ type: "note";
951
+ created_by?: string | undefined;
952
+ updated_by?: string | undefined;
953
+ } | {
954
+ _id: string;
955
+ created_at: number;
956
+ created_by: "system";
957
+ updated_at: number;
958
+ updated_by: "system";
959
+ message: string;
960
+ type: "system_info";
961
+ } | {
962
+ _id: string;
963
+ created_at: number;
964
+ updated_at: number;
965
+ type: "statusChanged";
966
+ curr_status: string;
967
+ prev_status: string;
968
+ created_by?: string | undefined;
969
+ updated_by?: string | undefined;
485
970
  }>, "many">>;
486
- file_ids: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
487
971
  is_archived: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
488
972
  jurisdiction: z.ZodOptional<z.ZodEnum<["ip", "municipality", "other", "unknown"]>>;
489
973
  legacy_id: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
@@ -499,21 +983,24 @@ export declare const UpdateStopSchema: z.ZodObject<{
499
983
  pole_status: z.ZodOptional<z.ZodEnum<["not_applicable", "unknown", "missing", "damaged", "ok"]>>;
500
984
  road_type: z.ZodOptional<z.ZodEnum<["complementary_itinerary", "highway", "main_itinerary", "national_road", "regional_road", "secondary_road", "unknown"]>>;
501
985
  shelter_frame_size: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>>;
502
- shelter_installation_date: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>>;
986
+ shelter_installation_date: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>>;
503
987
  shelter_make: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
504
988
  shelter_model: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
505
989
  shelter_status: z.ZodOptional<z.ZodEnum<["not_applicable", "unknown", "missing", "damaged", "ok"]>>;
506
- last_infrastructure_check: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>>;
507
- last_infrastructure_maintenance: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>>;
508
- last_schedules_check: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>>;
509
- last_schedules_maintenance: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>>;
990
+ last_infrastructure_check: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>>;
991
+ last_infrastructure_maintenance: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>>;
992
+ last_schedules_check: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>>;
993
+ last_schedules_maintenance: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>>>>;
510
994
  connections: z.ZodOptional<z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">>;
511
995
  facilities: z.ZodOptional<z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "beach"]>, "many">>;
512
996
  equipment: z.ZodOptional<z.ZodArray<z.ZodEnum<["pip", "mupi", "mini_pip"]>, "many">>;
513
997
  has_mupi: z.ZodOptional<z.ZodEnum<["yes", "no", "unknown"]>>;
998
+ file_ids: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
514
999
  image_ids: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
515
1000
  observations: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
516
1001
  }, "strict", z.ZodTypeAny, {
1002
+ created_by?: string | undefined;
1003
+ updated_by?: string | undefined;
517
1004
  name?: string | undefined;
518
1005
  short_name?: string | null | undefined;
519
1006
  has_bench?: "unknown" | "yes" | "no" | undefined;
@@ -526,18 +1013,44 @@ export declare const UpdateStopSchema: z.ZodObject<{
526
1013
  shelter_code?: string | null | undefined;
527
1014
  shelter_maintainer?: string | null | undefined;
528
1015
  is_locked?: boolean | undefined;
529
- comments?: {
1016
+ comments?: ({
530
1017
  _id: string;
531
- text: string;
532
- user_id: string;
533
- created_at?: (number & {
1018
+ created_at: number & {
534
1019
  __brand: "UnixTimestamp";
535
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
536
- updated_at?: (number & {
1020
+ };
1021
+ created_by: string;
1022
+ updated_at: number & {
537
1023
  __brand: "UnixTimestamp";
538
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
539
- }[] | undefined;
540
- file_ids?: string[] | undefined;
1024
+ };
1025
+ updated_by: string;
1026
+ message: string;
1027
+ type: "note";
1028
+ } | {
1029
+ _id: string;
1030
+ created_at: number & {
1031
+ __brand: "UnixTimestamp";
1032
+ };
1033
+ created_by: "system";
1034
+ updated_at: number & {
1035
+ __brand: "UnixTimestamp";
1036
+ };
1037
+ updated_by: "system";
1038
+ message: string;
1039
+ type: "system_info";
1040
+ } | {
1041
+ _id: string;
1042
+ created_at: number & {
1043
+ __brand: "UnixTimestamp";
1044
+ };
1045
+ created_by: string;
1046
+ updated_at: number & {
1047
+ __brand: "UnixTimestamp";
1048
+ };
1049
+ updated_by: string;
1050
+ type: "statusChanged";
1051
+ curr_status: string;
1052
+ prev_status: string;
1053
+ })[] | undefined;
541
1054
  is_archived?: boolean | undefined;
542
1055
  jurisdiction?: "unknown" | "ip" | "municipality" | "other" | undefined;
543
1056
  legacy_id?: string | null | undefined;
@@ -553,31 +1066,24 @@ export declare const UpdateStopSchema: z.ZodObject<{
553
1066
  pole_status?: "unknown" | "not_applicable" | "missing" | "damaged" | "ok" | undefined;
554
1067
  road_type?: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road" | undefined;
555
1068
  shelter_frame_size?: [number, number] | null | undefined;
556
- shelter_installation_date?: (number & {
557
- __brand: "UnixTimestamp";
558
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
1069
+ shelter_installation_date?: UnixTimestamp | null | undefined;
559
1070
  shelter_make?: string | null | undefined;
560
1071
  shelter_model?: string | null | undefined;
561
1072
  shelter_status?: "unknown" | "not_applicable" | "missing" | "damaged" | "ok" | undefined;
562
- last_infrastructure_check?: (number & {
563
- __brand: "UnixTimestamp";
564
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
565
- last_infrastructure_maintenance?: (number & {
566
- __brand: "UnixTimestamp";
567
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
568
- last_schedules_check?: (number & {
569
- __brand: "UnixTimestamp";
570
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
571
- last_schedules_maintenance?: (number & {
572
- __brand: "UnixTimestamp";
573
- } & z.BRAND<"UnixTimestamp">) | null | undefined;
1073
+ last_infrastructure_check?: UnixTimestamp | null | undefined;
1074
+ last_infrastructure_maintenance?: UnixTimestamp | null | undefined;
1075
+ last_schedules_check?: UnixTimestamp | null | undefined;
1076
+ last_schedules_maintenance?: UnixTimestamp | null | undefined;
574
1077
  connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | undefined;
575
1078
  facilities?: ("school" | "fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "shopping" | "transit_office" | "university" | "beach")[] | undefined;
576
1079
  equipment?: ("pip" | "mupi" | "mini_pip")[] | undefined;
577
1080
  has_mupi?: "unknown" | "yes" | "no" | undefined;
1081
+ file_ids?: string[] | undefined;
578
1082
  image_ids?: string[] | undefined;
579
1083
  observations?: string | null | undefined;
580
1084
  }, {
1085
+ created_by?: string | undefined;
1086
+ updated_by?: string | undefined;
581
1087
  name?: string | undefined;
582
1088
  short_name?: string | null | undefined;
583
1089
  has_bench?: "unknown" | "yes" | "no" | undefined;
@@ -590,14 +1096,32 @@ export declare const UpdateStopSchema: z.ZodObject<{
590
1096
  shelter_code?: string | null | undefined;
591
1097
  shelter_maintainer?: string | null | undefined;
592
1098
  is_locked?: boolean | undefined;
593
- comments?: {
1099
+ comments?: ({
594
1100
  _id: string;
595
- text: string;
596
- user_id: string;
597
- created_at?: number | null | undefined;
598
- updated_at?: number | null | undefined;
599
- }[] | undefined;
600
- file_ids?: string[] | undefined;
1101
+ created_at: number;
1102
+ updated_at: number;
1103
+ message: string;
1104
+ type: "note";
1105
+ created_by?: string | undefined;
1106
+ updated_by?: string | undefined;
1107
+ } | {
1108
+ _id: string;
1109
+ created_at: number;
1110
+ created_by: "system";
1111
+ updated_at: number;
1112
+ updated_by: "system";
1113
+ message: string;
1114
+ type: "system_info";
1115
+ } | {
1116
+ _id: string;
1117
+ created_at: number;
1118
+ updated_at: number;
1119
+ type: "statusChanged";
1120
+ curr_status: string;
1121
+ prev_status: string;
1122
+ created_by?: string | undefined;
1123
+ updated_by?: string | undefined;
1124
+ })[] | undefined;
601
1125
  is_archived?: boolean | undefined;
602
1126
  jurisdiction?: "unknown" | "ip" | "municipality" | "other" | undefined;
603
1127
  legacy_id?: string | null | undefined;
@@ -625,6 +1149,7 @@ export declare const UpdateStopSchema: z.ZodObject<{
625
1149
  facilities?: ("school" | "fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "shopping" | "transit_office" | "university" | "beach")[] | undefined;
626
1150
  equipment?: ("pip" | "mupi" | "mini_pip")[] | undefined;
627
1151
  has_mupi?: "unknown" | "yes" | "no" | undefined;
1152
+ file_ids?: string[] | undefined;
628
1153
  image_ids?: string[] | undefined;
629
1154
  observations?: string | null | undefined;
630
1155
  }>;