@tmlmobilidade/types
Version:
368 lines (367 loc) • 21.9 kB
TypeScript
import { z } from 'zod';
export declare const FlatStopSchema: z.ZodObject<{
_id: z.ZodNumber;
flags: z.ZodDefault<z.ZodArray<z.ZodObject<{
agency_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
is_harmonized: z.ZodDefault<z.ZodBoolean>;
short_name: z.ZodString;
stop_id: z.ZodString;
}, "strip", z.ZodTypeAny, {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}, {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}>, "many">>;
jurisdiction: z.ZodDefault<z.ZodEnum<["ip", "municipality", "other", "unknown"]>>;
legacy_id: z.ZodDefault<z.ZodNullable<z.ZodString>>;
legacy_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
lifecycle_status: z.ZodDefault<z.ZodEnum<["draft", "active", "inactive", "provisional", "seasonal", "voided"]>>;
name: z.ZodString;
new_name: z.ZodDefault<z.ZodNullable<z.ZodString>>;
previous_go_id: z.ZodDefault<z.ZodNullable<z.ZodString>>;
short_name: z.ZodString;
tts_name: z.ZodString;
district_id: z.ZodString;
latitude: z.ZodNumber;
locality_id: z.ZodDefault<z.ZodNullable<z.ZodString>>;
longitude: z.ZodNumber;
municapility_name: z.ZodOptional<z.ZodString>;
municipality_id: z.ZodString;
parish_id: z.ZodDefault<z.ZodNullable<z.ZodString>>;
bench_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "missing", "damaged", "ok"]>>;
electricity_status: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
pole_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "missing", "damaged", "ok"]>>;
road_type: z.ZodDefault<z.ZodEnum<["complementary_itinerary", "highway", "main_itinerary", "national_road", "regional_road", "secondary_road", "unknown"]>>;
shelter_code: z.ZodDefault<z.ZodNullable<z.ZodString>>;
shelter_frame_size: z.ZodDefault<z.ZodNullable<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
shelter_installation_date: z.ZodDefault<z.ZodNullable<z.ZodEffects<z.ZodNumber, import("@tmlmobilidade/go-types-shared").UnixTimestamp, number>>>;
shelter_maintainer: z.ZodDefault<z.ZodNullable<z.ZodString>>;
shelter_make: z.ZodDefault<z.ZodNullable<z.ZodString>>;
shelter_model: z.ZodDefault<z.ZodNullable<z.ZodString>>;
shelter_status: z.ZodDefault<z.ZodEnum<["not_applicable", "unknown", "missing", "damaged", "ok"]>>;
last_infrastructure_check: z.ZodDefault<z.ZodNullable<z.ZodEffects<z.ZodNumber, import("@tmlmobilidade/go-types-shared").UnixTimestamp, number>>>;
last_infrastructure_maintenance: z.ZodDefault<z.ZodNullable<z.ZodEffects<z.ZodNumber, import("@tmlmobilidade/go-types-shared").UnixTimestamp, number>>>;
last_schedules_check: z.ZodDefault<z.ZodNullable<z.ZodEffects<z.ZodNumber, import("@tmlmobilidade/go-types-shared").UnixTimestamp, number>>>;
last_schedules_maintenance: z.ZodDefault<z.ZodNullable<z.ZodEffects<z.ZodNumber, import("@tmlmobilidade/go-types-shared").UnixTimestamp, number>>>;
connections: z.ZodDefault<z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">>;
facilities: z.ZodDefault<z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "beach"]>, "many">>;
equipment: z.ZodDefault<z.ZodArray<z.ZodEnum<["pip", "mupi", "mini_pip"]>, "many">>;
has_bench: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
has_mupi: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
has_network_map: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
has_schedules: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
has_shelter: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
has_stop_sign: z.ZodDefault<z.ZodEnum<["available", "unavailable", "unknown"]>>;
}, "strip", z.ZodTypeAny, {
_id: number;
name: string;
short_name: string;
flags: {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}[];
jurisdiction: "unknown" | "ip" | "municipality" | "other";
legacy_id: string | null;
legacy_ids: string[];
lifecycle_status: "draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided";
new_name: string | null;
previous_go_id: string | null;
tts_name: string;
district_id: string;
latitude: number;
locality_id: string | null;
longitude: number;
municipality_id: string;
parish_id: string | null;
bench_status: "unknown" | "not_applicable" | "missing" | "damaged" | "ok";
electricity_status: "unknown" | "available" | "unavailable";
pole_status: "unknown" | "not_applicable" | "missing" | "damaged" | "ok";
road_type: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road";
shelter_code: string | null;
shelter_frame_size: [number, number] | null;
shelter_installation_date: import("@tmlmobilidade/go-types-shared").UnixTimestamp | null;
shelter_maintainer: string | null;
shelter_make: string | null;
shelter_model: string | null;
shelter_status: "unknown" | "not_applicable" | "missing" | "damaged" | "ok";
last_infrastructure_check: import("@tmlmobilidade/go-types-shared").UnixTimestamp | null;
last_infrastructure_maintenance: import("@tmlmobilidade/go-types-shared").UnixTimestamp | null;
last_schedules_check: import("@tmlmobilidade/go-types-shared").UnixTimestamp | null;
last_schedules_maintenance: import("@tmlmobilidade/go-types-shared").UnixTimestamp | null;
connections: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[];
facilities: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[];
equipment: ("pip" | "mupi" | "mini_pip")[];
has_bench: "unknown" | "available" | "unavailable";
has_mupi: "unknown" | "available" | "unavailable";
has_network_map: "unknown" | "available" | "unavailable";
has_schedules: "unknown" | "available" | "unavailable";
has_shelter: "unknown" | "available" | "unavailable";
has_stop_sign: "unknown" | "available" | "unavailable";
municapility_name?: string | undefined;
}, {
_id: number;
name: string;
short_name: string;
tts_name: string;
district_id: string;
latitude: number;
longitude: number;
municipality_id: string;
flags?: {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}[] | undefined;
jurisdiction?: "unknown" | "ip" | "municipality" | "other" | undefined;
legacy_id?: string | null | undefined;
legacy_ids?: string[] | undefined;
lifecycle_status?: "draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided" | undefined;
new_name?: string | null | undefined;
previous_go_id?: string | null | undefined;
locality_id?: string | null | undefined;
municapility_name?: string | undefined;
parish_id?: string | null | undefined;
bench_status?: "unknown" | "not_applicable" | "missing" | "damaged" | "ok" | undefined;
electricity_status?: "unknown" | "available" | "unavailable" | undefined;
pole_status?: "unknown" | "not_applicable" | "missing" | "damaged" | "ok" | undefined;
road_type?: "unknown" | "complementary_itinerary" | "highway" | "main_itinerary" | "national_road" | "regional_road" | "secondary_road" | undefined;
shelter_code?: string | null | undefined;
shelter_frame_size?: [number, number] | null | undefined;
shelter_installation_date?: number | null | undefined;
shelter_maintainer?: string | null | undefined;
shelter_make?: string | null | undefined;
shelter_model?: string | null | undefined;
shelter_status?: "unknown" | "not_applicable" | "missing" | "damaged" | "ok" | undefined;
last_infrastructure_check?: number | null | undefined;
last_infrastructure_maintenance?: number | null | undefined;
last_schedules_check?: number | null | undefined;
last_schedules_maintenance?: number | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | undefined;
has_bench?: "unknown" | "available" | "unavailable" | undefined;
has_mupi?: "unknown" | "available" | "unavailable" | undefined;
has_network_map?: "unknown" | "available" | "unavailable" | undefined;
has_schedules?: "unknown" | "available" | "unavailable" | undefined;
has_shelter?: "unknown" | "available" | "unavailable" | undefined;
has_stop_sign?: "unknown" | "available" | "unavailable" | undefined;
}>;
export declare const StopExportPropertiesSchema: z.ZodObject<{
properties: z.ZodObject<{
connections: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">>>;
equipment: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["pip", "mupi", "mini_pip"]>, "many">>>;
facilities: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "beach"]>, "many">>>;
flags: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
agency_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
is_harmonized: z.ZodDefault<z.ZodBoolean>;
short_name: z.ZodString;
stop_id: z.ZodString;
}, "strip", z.ZodTypeAny, {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}, {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}>, "many">>>;
jurisdiction: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["ip", "municipality", "other", "unknown"]>, "many">>>;
lifecycle_statuses: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["draft", "active", "inactive", "provisional", "seasonal", "voided"]>, "many">>>;
search: z.ZodNullable<z.ZodOptional<z.ZodString>>;
stop_ids: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>>;
}, "strip", z.ZodTypeAny, {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
}, {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
}>;
type: z.ZodLiteral<"stop">;
}, "strip", z.ZodTypeAny, {
type: "stop";
properties: {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
};
}, {
type: "stop";
properties: {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
};
}>;
export declare const StopExportSchema: z.ZodObject<{
_id: z.ZodString;
created_at: z.ZodEffects<z.ZodNumber, import("@tmlmobilidade/go-types-shared").UnixTimestamp, number>;
created_by: z.ZodDefault<z.ZodNullable<z.ZodString>>;
updated_at: z.ZodEffects<z.ZodNumber, import("@tmlmobilidade/go-types-shared").UnixTimestamp, number>;
updated_by: z.ZodOptional<z.ZodString>;
file_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
file_name: z.ZodString;
processing_status: z.ZodEnum<["waiting", "processing", "complete", "error", "skipped"]>;
} & {
properties: z.ZodObject<{
connections: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["ferry", "light_rail", "subway", "train", "boat", "airport", "bike_sharing", "bike_parking", "car_parking"]>, "many">>>;
equipment: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["pip", "mupi", "mini_pip"]>, "many">>>;
facilities: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["fire_station", "health_clinic", "historic_building", "hospital", "police_station", "school", "shopping", "transit_office", "university", "beach"]>, "many">>>;
flags: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
agency_ids: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
is_harmonized: z.ZodDefault<z.ZodBoolean>;
short_name: z.ZodString;
stop_id: z.ZodString;
}, "strip", z.ZodTypeAny, {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}, {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}>, "many">>>;
jurisdiction: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["ip", "municipality", "other", "unknown"]>, "many">>>;
lifecycle_statuses: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodEnum<["draft", "active", "inactive", "provisional", "seasonal", "voided"]>, "many">>>;
search: z.ZodNullable<z.ZodOptional<z.ZodString>>;
stop_ids: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>>;
}, "strip", z.ZodTypeAny, {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
}, {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
}>;
type: z.ZodLiteral<"stop">;
}, "strip", z.ZodTypeAny, {
_id: string;
created_at: number & {
__brand: "UnixTimestamp";
};
created_by: string | null;
updated_at: number & {
__brand: "UnixTimestamp";
};
type: "stop";
file_name: string;
processing_status: "error" | "waiting" | "processing" | "complete" | "skipped";
properties: {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
agency_ids: string[];
is_harmonized: boolean;
stop_id: string;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
};
updated_by?: string | undefined;
file_id?: string | null | undefined;
}, {
_id: string;
created_at: number;
updated_at: number;
type: "stop";
file_name: string;
processing_status: "error" | "waiting" | "processing" | "complete" | "skipped";
properties: {
search?: string | null | undefined;
stop_ids?: number[] | null | undefined;
flags?: {
short_name: string;
stop_id: string;
agency_ids?: string[] | undefined;
is_harmonized?: boolean | undefined;
}[] | null | undefined;
jurisdiction?: ("unknown" | "ip" | "municipality" | "other")[] | null | undefined;
connections?: ("ferry" | "light_rail" | "subway" | "train" | "boat" | "airport" | "bike_sharing" | "bike_parking" | "car_parking")[] | null | undefined;
facilities?: ("fire_station" | "health_clinic" | "historic_building" | "hospital" | "police_station" | "school" | "shopping" | "transit_office" | "university" | "beach")[] | null | undefined;
equipment?: ("pip" | "mupi" | "mini_pip")[] | null | undefined;
lifecycle_statuses?: ("draft" | "active" | "inactive" | "provisional" | "seasonal" | "voided")[] | null | undefined;
};
created_by?: string | null | undefined;
updated_by?: string | undefined;
file_id?: string | null | undefined;
}>;
export type StopExportProperties = z.infer<typeof StopExportPropertiesSchema>;
export type StopExportData = z.infer<typeof FlatStopSchema>;