@tmlmobilidade/types 20250325.1729.12
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/README.md +13 -0
- package/dist/index.d.ts +18 -0
- package/dist/index.js +21 -0
- package/dist/src/agency.d.ts +155 -0
- package/dist/src/agency.js +20 -0
- package/dist/src/alert.d.ts +289 -0
- package/dist/src/alert.js +81 -0
- package/dist/src/apex-t11.d.ts +152 -0
- package/dist/src/apex-t11.js +98 -0
- package/dist/src/apex-t19.d.ts +67 -0
- package/dist/src/apex-t19.js +17 -0
- package/dist/src/auth.d.ts +525 -0
- package/dist/src/auth.js +97 -0
- package/dist/src/common.d.ts +77 -0
- package/dist/src/common.js +50 -0
- package/dist/src/file.d.ts +121 -0
- package/dist/src/file.js +16 -0
- package/dist/src/hashed-shape.d.ts +186 -0
- package/dist/src/hashed-shape.js +19 -0
- package/dist/src/hashed-trip.d.ts +445 -0
- package/dist/src/hashed-trip.js +37 -0
- package/dist/src/locality.d.ts +145 -0
- package/dist/src/locality.js +20 -0
- package/dist/src/municipality.d.ts +145 -0
- package/dist/src/municipality.js +20 -0
- package/dist/src/organization.d.ts +52 -0
- package/dist/src/organization.js +8 -0
- package/dist/src/plan.d.ts +127 -0
- package/dist/src/plan.js +16 -0
- package/dist/src/ride.d.ts +498 -0
- package/dist/src/ride.js +44 -0
- package/dist/src/stop.d.ts +474 -0
- package/dist/src/stop.js +139 -0
- package/dist/src/vehicle-event.d.ts +76 -0
- package/dist/src/vehicle-event.js +20 -0
- package/dist/src/zone.d.ts +120 -0
- package/dist/src/zone.js +16 -0
- package/package.json +51 -0
|
@@ -0,0 +1,474 @@
|
|
|
1
|
+
import { UnixTimestamp } from './common.js';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
export declare const StopSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
4
|
+
_id: z.ZodString;
|
|
5
|
+
created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
6
|
+
updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
7
|
+
}, {
|
|
8
|
+
_id: z.ZodString;
|
|
9
|
+
jurisdiction: z.ZodDefault<z.ZodEnum<["ip", "municipality", "other", "unknown"]>>;
|
|
10
|
+
name: z.ZodString;
|
|
11
|
+
operational_status: z.ZodDefault<z.ZodEnum<["active", "inactive", "provisional", "seasonal", "voided"]>>;
|
|
12
|
+
short_name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
13
|
+
tts_name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
14
|
+
district_id: z.ZodString;
|
|
15
|
+
latitude: z.ZodNumber;
|
|
16
|
+
locality_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
17
|
+
longitude: z.ZodNumber;
|
|
18
|
+
municipality_id: z.ZodString;
|
|
19
|
+
parish_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
20
|
+
bench_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
21
|
+
docking_bay_type: z.ZodDefault<z.ZodEnum<["unknown", "simple_interaction", "cut_in_road_without_marks", "cut_in_road_with_marks", "island", "peninsula"]>>;
|
|
22
|
+
electricity_status: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
|
|
23
|
+
flag_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
24
|
+
lighting_status: z.ZodDefault<z.ZodEnum<["confortable", "damaged", "insuficient", "moderate", "unavailable", "unknown"]>>;
|
|
25
|
+
pavement_type: z.ZodDefault<z.ZodEnum<["asphalt", "concrete", "dirt", "grass", "gravel", "portuguese_stones", "unknown"]>>;
|
|
26
|
+
pole_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
27
|
+
road_type: z.ZodDefault<z.ZodEnum<["complementary_itinerary", "highway", "main_itinerary", "national_road", "regional_road", "secondary_road", "unknown"]>>;
|
|
28
|
+
shelter_code: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
29
|
+
shelter_maintainer: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
30
|
+
shelter_make: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
31
|
+
shelter_model: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
32
|
+
shelter_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
33
|
+
sidewalk_type: z.ZodDefault<z.ZodEnum<["unknown", "none", "gutter", "inaccessible", "is_ok"]>>;
|
|
34
|
+
last_infrastructure_check: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
35
|
+
last_infrastructure_maintenance: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
36
|
+
last_schedules_check: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
37
|
+
last_schedules_maintenance: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
38
|
+
connections: z.ZodDefault<z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">>;
|
|
39
|
+
facilities: z.ZodDefault<z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "pip"]>, "many">>;
|
|
40
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodObject<z.objectUtil.extendShape<{
|
|
41
|
+
_id: z.ZodString;
|
|
42
|
+
created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
43
|
+
updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
44
|
+
}, {
|
|
45
|
+
_id: z.ZodString;
|
|
46
|
+
text: z.ZodString;
|
|
47
|
+
user_id: z.ZodString;
|
|
48
|
+
}>, "strict", z.ZodTypeAny, {
|
|
49
|
+
_id: string;
|
|
50
|
+
text: string;
|
|
51
|
+
user_id: string;
|
|
52
|
+
created_at?: (number & {
|
|
53
|
+
__brand: "UnixTimestamp";
|
|
54
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
55
|
+
updated_at?: (number & {
|
|
56
|
+
__brand: "UnixTimestamp";
|
|
57
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
58
|
+
}, {
|
|
59
|
+
_id: string;
|
|
60
|
+
text: string;
|
|
61
|
+
user_id: string;
|
|
62
|
+
created_at?: number | null | undefined;
|
|
63
|
+
updated_at?: number | null | undefined;
|
|
64
|
+
}>, "many">>;
|
|
65
|
+
}>, "strict", z.ZodTypeAny, {
|
|
66
|
+
_id: string;
|
|
67
|
+
name: string;
|
|
68
|
+
jurisdiction: "unknown" | "ip" | "municipality" | "other";
|
|
69
|
+
operational_status: "active" | "inactive" | "provisional" | "seasonal" | "voided";
|
|
70
|
+
district_id: string;
|
|
71
|
+
latitude: number;
|
|
72
|
+
longitude: number;
|
|
73
|
+
municipality_id: string;
|
|
74
|
+
bench_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
75
|
+
docking_bay_type: "unknown" | "simple_interaction" | "cut_in_road_without_marks" | "cut_in_road_with_marks" | "island" | "peninsula";
|
|
76
|
+
electricity_status: "unknown" | "available" | "unavailable";
|
|
77
|
+
flag_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
78
|
+
lighting_status: "unknown" | "unavailable" | "confortable" | "damaged" | "insuficient" | "moderate";
|
|
79
|
+
pavement_type: "unknown" | "asphalt" | "concrete" | "dirt" | "grass" | "gravel" | "portuguese_stones";
|
|
80
|
+
pole_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
81
|
+
road_type: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road";
|
|
82
|
+
shelter_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
83
|
+
sidewalk_type: "unknown" | "is_ok" | "none" | "gutter" | "inaccessible";
|
|
84
|
+
connections: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[];
|
|
85
|
+
facilities: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "pip")[];
|
|
86
|
+
comments: {
|
|
87
|
+
_id: string;
|
|
88
|
+
text: string;
|
|
89
|
+
user_id: string;
|
|
90
|
+
created_at?: (number & {
|
|
91
|
+
__brand: "UnixTimestamp";
|
|
92
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
93
|
+
updated_at?: (number & {
|
|
94
|
+
__brand: "UnixTimestamp";
|
|
95
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
96
|
+
}[];
|
|
97
|
+
created_at?: (number & {
|
|
98
|
+
__brand: "UnixTimestamp";
|
|
99
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
100
|
+
updated_at?: (number & {
|
|
101
|
+
__brand: "UnixTimestamp";
|
|
102
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
103
|
+
short_name?: string | null | undefined;
|
|
104
|
+
tts_name?: string | null | undefined;
|
|
105
|
+
locality_id?: string | null | undefined;
|
|
106
|
+
parish_id?: string | null | undefined;
|
|
107
|
+
shelter_code?: string | null | undefined;
|
|
108
|
+
shelter_maintainer?: string | null | undefined;
|
|
109
|
+
shelter_make?: string | null | undefined;
|
|
110
|
+
shelter_model?: string | null | undefined;
|
|
111
|
+
last_infrastructure_check?: Date | null | undefined;
|
|
112
|
+
last_infrastructure_maintenance?: Date | null | undefined;
|
|
113
|
+
last_schedules_check?: Date | null | undefined;
|
|
114
|
+
last_schedules_maintenance?: Date | null | undefined;
|
|
115
|
+
}, {
|
|
116
|
+
_id: string;
|
|
117
|
+
name: string;
|
|
118
|
+
district_id: string;
|
|
119
|
+
latitude: number;
|
|
120
|
+
longitude: number;
|
|
121
|
+
municipality_id: string;
|
|
122
|
+
created_at?: number | null | undefined;
|
|
123
|
+
updated_at?: number | null | undefined;
|
|
124
|
+
jurisdiction?: "unknown" | "ip" | "municipality" | "other" | undefined;
|
|
125
|
+
operational_status?: "active" | "inactive" | "provisional" | "seasonal" | "voided" | undefined;
|
|
126
|
+
short_name?: string | null | undefined;
|
|
127
|
+
tts_name?: string | null | undefined;
|
|
128
|
+
locality_id?: string | null | undefined;
|
|
129
|
+
parish_id?: string | null | undefined;
|
|
130
|
+
bench_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
131
|
+
docking_bay_type?: "unknown" | "simple_interaction" | "cut_in_road_without_marks" | "cut_in_road_with_marks" | "island" | "peninsula" | undefined;
|
|
132
|
+
electricity_status?: "unknown" | "available" | "unavailable" | undefined;
|
|
133
|
+
flag_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
134
|
+
lighting_status?: "unknown" | "unavailable" | "confortable" | "damaged" | "insuficient" | "moderate" | undefined;
|
|
135
|
+
pavement_type?: "unknown" | "asphalt" | "concrete" | "dirt" | "grass" | "gravel" | "portuguese_stones" | undefined;
|
|
136
|
+
pole_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
137
|
+
road_type?: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road" | undefined;
|
|
138
|
+
shelter_code?: string | null | undefined;
|
|
139
|
+
shelter_maintainer?: string | null | undefined;
|
|
140
|
+
shelter_make?: string | null | undefined;
|
|
141
|
+
shelter_model?: string | null | undefined;
|
|
142
|
+
shelter_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
143
|
+
sidewalk_type?: "unknown" | "is_ok" | "none" | "gutter" | "inaccessible" | undefined;
|
|
144
|
+
last_infrastructure_check?: Date | null | undefined;
|
|
145
|
+
last_infrastructure_maintenance?: Date | null | undefined;
|
|
146
|
+
last_schedules_check?: Date | null | undefined;
|
|
147
|
+
last_schedules_maintenance?: Date | null | undefined;
|
|
148
|
+
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | undefined;
|
|
149
|
+
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "pip")[] | undefined;
|
|
150
|
+
comments?: {
|
|
151
|
+
_id: string;
|
|
152
|
+
text: string;
|
|
153
|
+
user_id: string;
|
|
154
|
+
created_at?: number | null | undefined;
|
|
155
|
+
updated_at?: number | null | undefined;
|
|
156
|
+
}[] | undefined;
|
|
157
|
+
}>;
|
|
158
|
+
export declare const CreateStopSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
159
|
+
_id: z.ZodString;
|
|
160
|
+
created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
161
|
+
updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
162
|
+
}, {
|
|
163
|
+
_id: z.ZodString;
|
|
164
|
+
jurisdiction: z.ZodDefault<z.ZodEnum<["ip", "municipality", "other", "unknown"]>>;
|
|
165
|
+
name: z.ZodString;
|
|
166
|
+
operational_status: z.ZodDefault<z.ZodEnum<["active", "inactive", "provisional", "seasonal", "voided"]>>;
|
|
167
|
+
short_name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
168
|
+
tts_name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
169
|
+
district_id: z.ZodString;
|
|
170
|
+
latitude: z.ZodNumber;
|
|
171
|
+
locality_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
172
|
+
longitude: z.ZodNumber;
|
|
173
|
+
municipality_id: z.ZodString;
|
|
174
|
+
parish_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
175
|
+
bench_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
176
|
+
docking_bay_type: z.ZodDefault<z.ZodEnum<["unknown", "simple_interaction", "cut_in_road_without_marks", "cut_in_road_with_marks", "island", "peninsula"]>>;
|
|
177
|
+
electricity_status: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
|
|
178
|
+
flag_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
179
|
+
lighting_status: z.ZodDefault<z.ZodEnum<["confortable", "damaged", "insuficient", "moderate", "unavailable", "unknown"]>>;
|
|
180
|
+
pavement_type: z.ZodDefault<z.ZodEnum<["asphalt", "concrete", "dirt", "grass", "gravel", "portuguese_stones", "unknown"]>>;
|
|
181
|
+
pole_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
182
|
+
road_type: z.ZodDefault<z.ZodEnum<["complementary_itinerary", "highway", "main_itinerary", "national_road", "regional_road", "secondary_road", "unknown"]>>;
|
|
183
|
+
shelter_code: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
184
|
+
shelter_maintainer: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
185
|
+
shelter_make: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
186
|
+
shelter_model: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
187
|
+
shelter_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>;
|
|
188
|
+
sidewalk_type: z.ZodDefault<z.ZodEnum<["unknown", "none", "gutter", "inaccessible", "is_ok"]>>;
|
|
189
|
+
last_infrastructure_check: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
190
|
+
last_infrastructure_maintenance: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
191
|
+
last_schedules_check: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
192
|
+
last_schedules_maintenance: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
193
|
+
connections: z.ZodDefault<z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">>;
|
|
194
|
+
facilities: z.ZodDefault<z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "pip"]>, "many">>;
|
|
195
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodObject<z.objectUtil.extendShape<{
|
|
196
|
+
_id: z.ZodString;
|
|
197
|
+
created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
198
|
+
updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
199
|
+
}, {
|
|
200
|
+
_id: z.ZodString;
|
|
201
|
+
text: z.ZodString;
|
|
202
|
+
user_id: z.ZodString;
|
|
203
|
+
}>, "strict", z.ZodTypeAny, {
|
|
204
|
+
_id: string;
|
|
205
|
+
text: string;
|
|
206
|
+
user_id: string;
|
|
207
|
+
created_at?: (number & {
|
|
208
|
+
__brand: "UnixTimestamp";
|
|
209
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
210
|
+
updated_at?: (number & {
|
|
211
|
+
__brand: "UnixTimestamp";
|
|
212
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
213
|
+
}, {
|
|
214
|
+
_id: string;
|
|
215
|
+
text: string;
|
|
216
|
+
user_id: string;
|
|
217
|
+
created_at?: number | null | undefined;
|
|
218
|
+
updated_at?: number | null | undefined;
|
|
219
|
+
}>, "many">>;
|
|
220
|
+
}>, "strict", z.ZodTypeAny, {
|
|
221
|
+
_id: string;
|
|
222
|
+
name: string;
|
|
223
|
+
jurisdiction: "unknown" | "ip" | "municipality" | "other";
|
|
224
|
+
operational_status: "active" | "inactive" | "provisional" | "seasonal" | "voided";
|
|
225
|
+
district_id: string;
|
|
226
|
+
latitude: number;
|
|
227
|
+
longitude: number;
|
|
228
|
+
municipality_id: string;
|
|
229
|
+
bench_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
230
|
+
docking_bay_type: "unknown" | "simple_interaction" | "cut_in_road_without_marks" | "cut_in_road_with_marks" | "island" | "peninsula";
|
|
231
|
+
electricity_status: "unknown" | "available" | "unavailable";
|
|
232
|
+
flag_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
233
|
+
lighting_status: "unknown" | "unavailable" | "confortable" | "damaged" | "insuficient" | "moderate";
|
|
234
|
+
pavement_type: "unknown" | "asphalt" | "concrete" | "dirt" | "grass" | "gravel" | "portuguese_stones";
|
|
235
|
+
pole_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
236
|
+
road_type: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road";
|
|
237
|
+
shelter_status: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok";
|
|
238
|
+
sidewalk_type: "unknown" | "is_ok" | "none" | "gutter" | "inaccessible";
|
|
239
|
+
connections: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[];
|
|
240
|
+
facilities: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "pip")[];
|
|
241
|
+
comments: {
|
|
242
|
+
_id: string;
|
|
243
|
+
text: string;
|
|
244
|
+
user_id: string;
|
|
245
|
+
created_at?: (number & {
|
|
246
|
+
__brand: "UnixTimestamp";
|
|
247
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
248
|
+
updated_at?: (number & {
|
|
249
|
+
__brand: "UnixTimestamp";
|
|
250
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
251
|
+
}[];
|
|
252
|
+
created_at?: (number & {
|
|
253
|
+
__brand: "UnixTimestamp";
|
|
254
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
255
|
+
updated_at?: (number & {
|
|
256
|
+
__brand: "UnixTimestamp";
|
|
257
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
258
|
+
short_name?: string | null | undefined;
|
|
259
|
+
tts_name?: string | null | undefined;
|
|
260
|
+
locality_id?: string | null | undefined;
|
|
261
|
+
parish_id?: string | null | undefined;
|
|
262
|
+
shelter_code?: string | null | undefined;
|
|
263
|
+
shelter_maintainer?: string | null | undefined;
|
|
264
|
+
shelter_make?: string | null | undefined;
|
|
265
|
+
shelter_model?: string | null | undefined;
|
|
266
|
+
last_infrastructure_check?: Date | null | undefined;
|
|
267
|
+
last_infrastructure_maintenance?: Date | null | undefined;
|
|
268
|
+
last_schedules_check?: Date | null | undefined;
|
|
269
|
+
last_schedules_maintenance?: Date | null | undefined;
|
|
270
|
+
}, {
|
|
271
|
+
_id: string;
|
|
272
|
+
name: string;
|
|
273
|
+
district_id: string;
|
|
274
|
+
latitude: number;
|
|
275
|
+
longitude: number;
|
|
276
|
+
municipality_id: string;
|
|
277
|
+
created_at?: number | null | undefined;
|
|
278
|
+
updated_at?: number | null | undefined;
|
|
279
|
+
jurisdiction?: "unknown" | "ip" | "municipality" | "other" | undefined;
|
|
280
|
+
operational_status?: "active" | "inactive" | "provisional" | "seasonal" | "voided" | undefined;
|
|
281
|
+
short_name?: string | null | undefined;
|
|
282
|
+
tts_name?: string | null | undefined;
|
|
283
|
+
locality_id?: string | null | undefined;
|
|
284
|
+
parish_id?: string | null | undefined;
|
|
285
|
+
bench_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
286
|
+
docking_bay_type?: "unknown" | "simple_interaction" | "cut_in_road_without_marks" | "cut_in_road_with_marks" | "island" | "peninsula" | undefined;
|
|
287
|
+
electricity_status?: "unknown" | "available" | "unavailable" | undefined;
|
|
288
|
+
flag_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
289
|
+
lighting_status?: "unknown" | "unavailable" | "confortable" | "damaged" | "insuficient" | "moderate" | undefined;
|
|
290
|
+
pavement_type?: "unknown" | "asphalt" | "concrete" | "dirt" | "grass" | "gravel" | "portuguese_stones" | undefined;
|
|
291
|
+
pole_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
292
|
+
road_type?: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road" | undefined;
|
|
293
|
+
shelter_code?: string | null | undefined;
|
|
294
|
+
shelter_maintainer?: string | null | undefined;
|
|
295
|
+
shelter_make?: string | null | undefined;
|
|
296
|
+
shelter_model?: string | null | undefined;
|
|
297
|
+
shelter_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
298
|
+
sidewalk_type?: "unknown" | "is_ok" | "none" | "gutter" | "inaccessible" | undefined;
|
|
299
|
+
last_infrastructure_check?: Date | null | undefined;
|
|
300
|
+
last_infrastructure_maintenance?: Date | null | undefined;
|
|
301
|
+
last_schedules_check?: Date | null | undefined;
|
|
302
|
+
last_schedules_maintenance?: Date | null | undefined;
|
|
303
|
+
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | undefined;
|
|
304
|
+
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "pip")[] | undefined;
|
|
305
|
+
comments?: {
|
|
306
|
+
_id: string;
|
|
307
|
+
text: string;
|
|
308
|
+
user_id: string;
|
|
309
|
+
created_at?: number | null | undefined;
|
|
310
|
+
updated_at?: number | null | undefined;
|
|
311
|
+
}[] | undefined;
|
|
312
|
+
}>;
|
|
313
|
+
export declare const UpdateStopSchema: z.ZodObject<{
|
|
314
|
+
created_at: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>>;
|
|
315
|
+
updated_at: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>>;
|
|
316
|
+
_id: z.ZodOptional<z.ZodString>;
|
|
317
|
+
jurisdiction: z.ZodOptional<z.ZodDefault<z.ZodEnum<["ip", "municipality", "other", "unknown"]>>>;
|
|
318
|
+
name: z.ZodOptional<z.ZodString>;
|
|
319
|
+
operational_status: z.ZodOptional<z.ZodDefault<z.ZodEnum<["active", "inactive", "provisional", "seasonal", "voided"]>>>;
|
|
320
|
+
short_name: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
321
|
+
tts_name: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
322
|
+
district_id: z.ZodOptional<z.ZodString>;
|
|
323
|
+
latitude: z.ZodOptional<z.ZodNumber>;
|
|
324
|
+
locality_id: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
325
|
+
longitude: z.ZodOptional<z.ZodNumber>;
|
|
326
|
+
municipality_id: z.ZodOptional<z.ZodString>;
|
|
327
|
+
parish_id: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
328
|
+
bench_status: z.ZodOptional<z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>>;
|
|
329
|
+
docking_bay_type: z.ZodOptional<z.ZodDefault<z.ZodEnum<["unknown", "simple_interaction", "cut_in_road_without_marks", "cut_in_road_with_marks", "island", "peninsula"]>>>;
|
|
330
|
+
electricity_status: z.ZodOptional<z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>>;
|
|
331
|
+
flag_status: z.ZodOptional<z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>>;
|
|
332
|
+
lighting_status: z.ZodOptional<z.ZodDefault<z.ZodEnum<["confortable", "damaged", "insuficient", "moderate", "unavailable", "unknown"]>>>;
|
|
333
|
+
pavement_type: z.ZodOptional<z.ZodDefault<z.ZodEnum<["asphalt", "concrete", "dirt", "grass", "gravel", "portuguese_stones", "unknown"]>>>;
|
|
334
|
+
pole_status: z.ZodOptional<z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>>;
|
|
335
|
+
road_type: z.ZodOptional<z.ZodDefault<z.ZodEnum<["complementary_itinerary", "highway", "main_itinerary", "national_road", "regional_road", "secondary_road", "unknown"]>>>;
|
|
336
|
+
shelter_code: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
337
|
+
shelter_maintainer: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
338
|
+
shelter_make: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
339
|
+
shelter_model: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
340
|
+
shelter_status: z.ZodOptional<z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "is_missing", "is_damaged", "is_ok"]>>>;
|
|
341
|
+
sidewalk_type: z.ZodOptional<z.ZodDefault<z.ZodEnum<["unknown", "none", "gutter", "inaccessible", "is_ok"]>>>;
|
|
342
|
+
last_infrastructure_check: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodDate>>>;
|
|
343
|
+
last_infrastructure_maintenance: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodDate>>>;
|
|
344
|
+
last_schedules_check: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodDate>>>;
|
|
345
|
+
last_schedules_maintenance: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodDate>>>;
|
|
346
|
+
connections: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">>>;
|
|
347
|
+
facilities: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "pip"]>, "many">>>;
|
|
348
|
+
comments: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<z.objectUtil.extendShape<{
|
|
349
|
+
_id: z.ZodString;
|
|
350
|
+
created_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
351
|
+
updated_at: z.ZodOptional<z.ZodNullable<z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">>>;
|
|
352
|
+
}, {
|
|
353
|
+
_id: z.ZodString;
|
|
354
|
+
text: z.ZodString;
|
|
355
|
+
user_id: z.ZodString;
|
|
356
|
+
}>, "strict", z.ZodTypeAny, {
|
|
357
|
+
_id: string;
|
|
358
|
+
text: string;
|
|
359
|
+
user_id: string;
|
|
360
|
+
created_at?: (number & {
|
|
361
|
+
__brand: "UnixTimestamp";
|
|
362
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
363
|
+
updated_at?: (number & {
|
|
364
|
+
__brand: "UnixTimestamp";
|
|
365
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
366
|
+
}, {
|
|
367
|
+
_id: string;
|
|
368
|
+
text: string;
|
|
369
|
+
user_id: string;
|
|
370
|
+
created_at?: number | null | undefined;
|
|
371
|
+
updated_at?: number | null | undefined;
|
|
372
|
+
}>, "many">>>;
|
|
373
|
+
}, "strict", z.ZodTypeAny, {
|
|
374
|
+
_id?: string | undefined;
|
|
375
|
+
created_at?: (number & {
|
|
376
|
+
__brand: "UnixTimestamp";
|
|
377
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
378
|
+
updated_at?: (number & {
|
|
379
|
+
__brand: "UnixTimestamp";
|
|
380
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
381
|
+
name?: string | undefined;
|
|
382
|
+
jurisdiction?: "unknown" | "ip" | "municipality" | "other" | undefined;
|
|
383
|
+
operational_status?: "active" | "inactive" | "provisional" | "seasonal" | "voided" | undefined;
|
|
384
|
+
short_name?: string | null | undefined;
|
|
385
|
+
tts_name?: string | null | undefined;
|
|
386
|
+
district_id?: string | undefined;
|
|
387
|
+
latitude?: number | undefined;
|
|
388
|
+
locality_id?: string | null | undefined;
|
|
389
|
+
longitude?: number | undefined;
|
|
390
|
+
municipality_id?: string | undefined;
|
|
391
|
+
parish_id?: string | null | undefined;
|
|
392
|
+
bench_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
393
|
+
docking_bay_type?: "unknown" | "simple_interaction" | "cut_in_road_without_marks" | "cut_in_road_with_marks" | "island" | "peninsula" | undefined;
|
|
394
|
+
electricity_status?: "unknown" | "available" | "unavailable" | undefined;
|
|
395
|
+
flag_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
396
|
+
lighting_status?: "unknown" | "unavailable" | "confortable" | "damaged" | "insuficient" | "moderate" | undefined;
|
|
397
|
+
pavement_type?: "unknown" | "asphalt" | "concrete" | "dirt" | "grass" | "gravel" | "portuguese_stones" | undefined;
|
|
398
|
+
pole_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
399
|
+
road_type?: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road" | undefined;
|
|
400
|
+
shelter_code?: string | null | undefined;
|
|
401
|
+
shelter_maintainer?: string | null | undefined;
|
|
402
|
+
shelter_make?: string | null | undefined;
|
|
403
|
+
shelter_model?: string | null | undefined;
|
|
404
|
+
shelter_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
405
|
+
sidewalk_type?: "unknown" | "is_ok" | "none" | "gutter" | "inaccessible" | undefined;
|
|
406
|
+
last_infrastructure_check?: Date | null | undefined;
|
|
407
|
+
last_infrastructure_maintenance?: Date | null | undefined;
|
|
408
|
+
last_schedules_check?: Date | null | undefined;
|
|
409
|
+
last_schedules_maintenance?: Date | null | undefined;
|
|
410
|
+
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | undefined;
|
|
411
|
+
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "pip")[] | undefined;
|
|
412
|
+
comments?: {
|
|
413
|
+
_id: string;
|
|
414
|
+
text: string;
|
|
415
|
+
user_id: string;
|
|
416
|
+
created_at?: (number & {
|
|
417
|
+
__brand: "UnixTimestamp";
|
|
418
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
419
|
+
updated_at?: (number & {
|
|
420
|
+
__brand: "UnixTimestamp";
|
|
421
|
+
} & z.BRAND<"UnixTimestamp">) | null | undefined;
|
|
422
|
+
}[] | undefined;
|
|
423
|
+
}, {
|
|
424
|
+
_id?: string | undefined;
|
|
425
|
+
created_at?: number | null | undefined;
|
|
426
|
+
updated_at?: number | null | undefined;
|
|
427
|
+
name?: string | undefined;
|
|
428
|
+
jurisdiction?: "unknown" | "ip" | "municipality" | "other" | undefined;
|
|
429
|
+
operational_status?: "active" | "inactive" | "provisional" | "seasonal" | "voided" | undefined;
|
|
430
|
+
short_name?: string | null | undefined;
|
|
431
|
+
tts_name?: string | null | undefined;
|
|
432
|
+
district_id?: string | undefined;
|
|
433
|
+
latitude?: number | undefined;
|
|
434
|
+
locality_id?: string | null | undefined;
|
|
435
|
+
longitude?: number | undefined;
|
|
436
|
+
municipality_id?: string | undefined;
|
|
437
|
+
parish_id?: string | null | undefined;
|
|
438
|
+
bench_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
439
|
+
docking_bay_type?: "unknown" | "simple_interaction" | "cut_in_road_without_marks" | "cut_in_road_with_marks" | "island" | "peninsula" | undefined;
|
|
440
|
+
electricity_status?: "unknown" | "available" | "unavailable" | undefined;
|
|
441
|
+
flag_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
442
|
+
lighting_status?: "unknown" | "unavailable" | "confortable" | "damaged" | "insuficient" | "moderate" | undefined;
|
|
443
|
+
pavement_type?: "unknown" | "asphalt" | "concrete" | "dirt" | "grass" | "gravel" | "portuguese_stones" | undefined;
|
|
444
|
+
pole_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
445
|
+
road_type?: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road" | undefined;
|
|
446
|
+
shelter_code?: string | null | undefined;
|
|
447
|
+
shelter_maintainer?: string | null | undefined;
|
|
448
|
+
shelter_make?: string | null | undefined;
|
|
449
|
+
shelter_model?: string | null | undefined;
|
|
450
|
+
shelter_status?: "unknown" | "not_applicable" | "is_missing" | "is_damaged" | "is_ok" | undefined;
|
|
451
|
+
sidewalk_type?: "unknown" | "is_ok" | "none" | "gutter" | "inaccessible" | undefined;
|
|
452
|
+
last_infrastructure_check?: Date | null | undefined;
|
|
453
|
+
last_infrastructure_maintenance?: Date | null | undefined;
|
|
454
|
+
last_schedules_check?: Date | null | undefined;
|
|
455
|
+
last_schedules_maintenance?: Date | null | undefined;
|
|
456
|
+
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | undefined;
|
|
457
|
+
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "pip")[] | undefined;
|
|
458
|
+
comments?: {
|
|
459
|
+
_id: string;
|
|
460
|
+
text: string;
|
|
461
|
+
user_id: string;
|
|
462
|
+
created_at?: number | null | undefined;
|
|
463
|
+
updated_at?: number | null | undefined;
|
|
464
|
+
}[] | undefined;
|
|
465
|
+
}>;
|
|
466
|
+
export type Stop = Omit<z.infer<typeof StopSchema>, 'created_at' | 'updated_at'> & {
|
|
467
|
+
created_at: UnixTimestamp;
|
|
468
|
+
updated_at: UnixTimestamp;
|
|
469
|
+
};
|
|
470
|
+
export type CreateStopDto = Omit<z.infer<typeof CreateStopSchema>, 'created_at' | 'updated_at'> & {
|
|
471
|
+
created_at?: UnixTimestamp;
|
|
472
|
+
updated_at?: UnixTimestamp;
|
|
473
|
+
};
|
|
474
|
+
export type UpdateStopDto = Partial<CreateStopDto>;
|
package/dist/src/stop.js
ADDED
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
/* * */
|
|
2
|
+
import { CommentSchema, DocumentSchema } from './common.js';
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
/* * */
|
|
5
|
+
export const StopSchema = DocumentSchema.extend({
|
|
6
|
+
//
|
|
7
|
+
// General
|
|
8
|
+
_id: z
|
|
9
|
+
.string()
|
|
10
|
+
.length(6),
|
|
11
|
+
jurisdiction: z
|
|
12
|
+
.enum(['ip', 'municipality', 'other', 'unknown'])
|
|
13
|
+
.default('unknown'),
|
|
14
|
+
name: z
|
|
15
|
+
.string(),
|
|
16
|
+
operational_status: z
|
|
17
|
+
.enum(['active', 'inactive', 'provisional', 'seasonal', 'voided'])
|
|
18
|
+
.default('inactive'),
|
|
19
|
+
short_name: z
|
|
20
|
+
.string()
|
|
21
|
+
.nullish(),
|
|
22
|
+
tts_name: z
|
|
23
|
+
.string()
|
|
24
|
+
.nullish(),
|
|
25
|
+
//
|
|
26
|
+
// Location
|
|
27
|
+
district_id: z
|
|
28
|
+
.string(),
|
|
29
|
+
latitude: z
|
|
30
|
+
.number(),
|
|
31
|
+
locality_id: z
|
|
32
|
+
.string()
|
|
33
|
+
.nullish(),
|
|
34
|
+
longitude: z
|
|
35
|
+
.number(),
|
|
36
|
+
municipality_id: z
|
|
37
|
+
.string(),
|
|
38
|
+
parish_id: z
|
|
39
|
+
.string()
|
|
40
|
+
.nullish(),
|
|
41
|
+
//
|
|
42
|
+
// Infrastructure
|
|
43
|
+
bench_status: z
|
|
44
|
+
.enum(['not_applicable', 'unknown', 'is_missing', 'is_damaged', 'is_ok'])
|
|
45
|
+
.default('unknown'),
|
|
46
|
+
docking_bay_type: z
|
|
47
|
+
.enum(['unknown', 'simple_interaction', 'cut_in_road_without_marks', 'cut_in_road_with_marks', 'island', 'peninsula'])
|
|
48
|
+
.default('unknown'),
|
|
49
|
+
electricity_status: z
|
|
50
|
+
.enum(['available', 'unavailable', 'unknown'])
|
|
51
|
+
.default('unknown'),
|
|
52
|
+
flag_status: z
|
|
53
|
+
.enum(['not_applicable', 'unknown', 'is_missing', 'is_damaged', 'is_ok'])
|
|
54
|
+
.default('unknown'),
|
|
55
|
+
lighting_status: z
|
|
56
|
+
.enum(['confortable', 'damaged', 'insuficient', 'moderate', 'unavailable', 'unknown'])
|
|
57
|
+
.default('unknown'),
|
|
58
|
+
pavement_type: z
|
|
59
|
+
.enum(['asphalt', 'concrete', 'dirt', 'grass', 'gravel', 'portuguese_stones', 'unknown'])
|
|
60
|
+
.default('unknown'),
|
|
61
|
+
pole_status: z
|
|
62
|
+
.enum(['not_applicable', 'unknown', 'is_missing', 'is_damaged', 'is_ok'])
|
|
63
|
+
.default('unknown'),
|
|
64
|
+
road_type: z
|
|
65
|
+
.enum(['complementary_itinerary', 'highway', 'main_itinerary', 'national_road', 'regional_road', 'secondary_road', 'unknown'])
|
|
66
|
+
.default('unknown'),
|
|
67
|
+
shelter_code: z
|
|
68
|
+
.string()
|
|
69
|
+
.nullish(),
|
|
70
|
+
shelter_maintainer: z
|
|
71
|
+
.string()
|
|
72
|
+
.nullish(),
|
|
73
|
+
shelter_make: z
|
|
74
|
+
.string()
|
|
75
|
+
.nullish(),
|
|
76
|
+
shelter_model: z
|
|
77
|
+
.string()
|
|
78
|
+
.nullish(),
|
|
79
|
+
shelter_status: z
|
|
80
|
+
.enum(['not_applicable', 'unknown', 'is_missing', 'is_damaged', 'is_ok'])
|
|
81
|
+
.default('unknown'),
|
|
82
|
+
sidewalk_type: z
|
|
83
|
+
.enum(['unknown', 'none', 'gutter', 'inaccessible', 'is_ok'])
|
|
84
|
+
.default('unknown'),
|
|
85
|
+
//
|
|
86
|
+
// Checks
|
|
87
|
+
last_infrastructure_check: z
|
|
88
|
+
.coerce
|
|
89
|
+
.date()
|
|
90
|
+
.nullish(),
|
|
91
|
+
last_infrastructure_maintenance: z
|
|
92
|
+
.coerce
|
|
93
|
+
.date()
|
|
94
|
+
.nullish(),
|
|
95
|
+
last_schedules_check: z
|
|
96
|
+
.coerce
|
|
97
|
+
.date()
|
|
98
|
+
.nullish(),
|
|
99
|
+
last_schedules_maintenance: z
|
|
100
|
+
.coerce
|
|
101
|
+
.date()
|
|
102
|
+
.nullish(),
|
|
103
|
+
//
|
|
104
|
+
// Facilities
|
|
105
|
+
connections: z
|
|
106
|
+
.array(z.enum([
|
|
107
|
+
'ferry',
|
|
108
|
+
'light_rail',
|
|
109
|
+
'subway',
|
|
110
|
+
'train',
|
|
111
|
+
'boat',
|
|
112
|
+
'airport',
|
|
113
|
+
'bike_sharing',
|
|
114
|
+
'bike_parking',
|
|
115
|
+
'car_parking',
|
|
116
|
+
]))
|
|
117
|
+
.default([]),
|
|
118
|
+
facilities: z
|
|
119
|
+
.array(z.enum([
|
|
120
|
+
'fire_station',
|
|
121
|
+
'health_clinic',
|
|
122
|
+
'historic_building',
|
|
123
|
+
'hospital',
|
|
124
|
+
'police_station',
|
|
125
|
+
'school',
|
|
126
|
+
'shopping',
|
|
127
|
+
'transit_office',
|
|
128
|
+
'university',
|
|
129
|
+
'pip',
|
|
130
|
+
]))
|
|
131
|
+
.default([]),
|
|
132
|
+
//
|
|
133
|
+
// Notes & Comments
|
|
134
|
+
comments: z
|
|
135
|
+
.array(CommentSchema)
|
|
136
|
+
.default([]),
|
|
137
|
+
}).strict();
|
|
138
|
+
export const CreateStopSchema = StopSchema;
|
|
139
|
+
export const UpdateStopSchema = CreateStopSchema.partial();
|