@motis-project/motis-client 2.5.0 → 2.7.3
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 +4 -2
- package/dist/{chunk-5QEG6DOF.js → chunk-47ZS6OWZ.js} +543 -40
- package/dist/{chunk-ZSHHWD3H.js → chunk-FDF4H3WD.js} +7 -0
- package/dist/index.d.ts +3 -3
- package/dist/index.js +22 -2
- package/dist/schemas.gen.d.ts +460 -8
- package/dist/schemas.gen.js +19 -1
- package/dist/services.gen.d.ts +22 -2
- package/dist/services.gen.js +3 -1
- package/dist/types.gen.d.ts +544 -46
- package/package.json +3 -3
- package/dist/chunk-35GMB6DP.js +0 -1232
- package/dist/chunk-7PIP6KRC.js +0 -1300
- package/dist/chunk-7UKCGCXT.js +0 -1247
- package/dist/chunk-CAW6R2LI.js +0 -1285
- package/dist/chunk-EM7IAOVY.js +0 -91
- package/dist/chunk-IHFNO6R3.js +0 -91
- package/dist/chunk-IYBFZNEH.js +0 -1224
- package/dist/chunk-QM2K42W7.js +0 -91
- package/dist/chunk-RM52T2X5.js +0 -1293
- package/dist/chunk-VOTN5CAZ.js +0 -91
- package/dist/chunk-ZBHU6VX2.js +0 -1291
package/dist/types.gen.d.ts
CHANGED
|
@@ -21,13 +21,13 @@ type TimeRange = {
|
|
|
21
21
|
* If a TimeRange is provided, either start or end must be provided - both fields cannot be empty.
|
|
22
22
|
*
|
|
23
23
|
*/
|
|
24
|
-
start
|
|
24
|
+
start: string;
|
|
25
25
|
/**
|
|
26
26
|
* If missing, the interval ends at plus infinity.
|
|
27
27
|
* If a TimeRange is provided, either start or end must be provided - both fields cannot be empty.
|
|
28
28
|
*
|
|
29
29
|
*/
|
|
30
|
-
end
|
|
30
|
+
end: string;
|
|
31
31
|
};
|
|
32
32
|
/**
|
|
33
33
|
* An alert, indicating some sort of incident in the public transit network.
|
|
@@ -160,11 +160,56 @@ type Token = [
|
|
|
160
160
|
* location type
|
|
161
161
|
*/
|
|
162
162
|
type LocationType = 'ADDRESS' | 'PLACE' | 'STOP';
|
|
163
|
+
/**
|
|
164
|
+
* # Street modes
|
|
165
|
+
*
|
|
166
|
+
* - `WALK`
|
|
167
|
+
* - `BIKE`
|
|
168
|
+
* - `RENTAL` Experimental. Expect unannounced breaking changes (without version bumps) for all parameters and returned structs.
|
|
169
|
+
* - `CAR`
|
|
170
|
+
* - `CAR_PARKING` Experimental. Expect unannounced breaking changes (without version bumps) for all parameters and returned structs.
|
|
171
|
+
* - `CAR_DROPOFF` Experimental. Expect unannounced breaking changes (without version bumps) for all perameters and returned structs.
|
|
172
|
+
* - `ODM` on-demand taxis from the Prima+ÖV Project
|
|
173
|
+
* - `RIDE_SHARING` ride sharing from the Prima+ÖV Project
|
|
174
|
+
* - `FLEX` flexible transports
|
|
175
|
+
*
|
|
176
|
+
* # Transit modes
|
|
177
|
+
*
|
|
178
|
+
* - `TRANSIT`: translates to `RAIL,TRAM,BUS,FERRY,AIRPLANE,COACH,CABLE_CAR,FUNICULAR,AREAL_LIFT,OTHER`
|
|
179
|
+
* - `TRAM`: trams
|
|
180
|
+
* - `SUBWAY`: subway trains (Paris Metro, London Underground, but also NYC Subway, Hamburger Hochbahn, and other non-underground services)
|
|
181
|
+
* - `FERRY`: ferries
|
|
182
|
+
* - `AIRPLANE`: airline flights
|
|
183
|
+
* - `BUS`: short distance buses (does not include `COACH`)
|
|
184
|
+
* - `COACH`: long distance buses (does not include `BUS`)
|
|
185
|
+
* - `RAIL`: translates to `HIGHSPEED_RAIL,LONG_DISTANCE,NIGHT_RAIL,REGIONAL_RAIL,REGIONAL_FAST_RAIL,SUBURBAN,SUBWAY`
|
|
186
|
+
* - `SUBURBAN`: suburban trains (e.g. S-Bahn, RER, Elizabeth Line, ...)
|
|
187
|
+
* - `HIGHSPEED_RAIL`: long distance high speed trains (e.g. TGV)
|
|
188
|
+
* - `LONG_DISTANCE`: long distance inter city trains
|
|
189
|
+
* - `NIGHT_RAIL`: long distance night trains
|
|
190
|
+
* - `REGIONAL_FAST_RAIL`: regional express routes that skip low traffic stops to be faster
|
|
191
|
+
* - `REGIONAL_RAIL`: regional train
|
|
192
|
+
* - `CABLE_CAR`: Cable tram. Used for street-level rail cars where the cable runs beneath the vehicle (e.g., cable car in San Francisco).
|
|
193
|
+
* - `FUNICULAR`: Funicular. Any rail system designed for steep inclines.
|
|
194
|
+
* - `AERIAL_LIFT`: Aerial lift, suspended cable car (e.g., gondola lift, aerial tramway). Cable transport where cabins, cars, gondolas or open chairs are suspended by means of one or more cables.
|
|
195
|
+
* - `AREAL_LIFT`: deprecated
|
|
196
|
+
* - `METRO`: deprecated
|
|
197
|
+
*
|
|
198
|
+
*/
|
|
199
|
+
type Mode = 'WALK' | 'BIKE' | 'RENTAL' | 'CAR' | 'CAR_PARKING' | 'CAR_DROPOFF' | 'ODM' | 'RIDE_SHARING' | 'FLEX' | 'TRANSIT' | 'TRAM' | 'SUBWAY' | 'FERRY' | 'AIRPLANE' | 'SUBURBAN' | 'BUS' | 'COACH' | 'RAIL' | 'HIGHSPEED_RAIL' | 'LONG_DISTANCE' | 'NIGHT_RAIL' | 'REGIONAL_FAST_RAIL' | 'REGIONAL_RAIL' | 'CABLE_CAR' | 'FUNICULAR' | 'AERIAL_LIFT' | 'OTHER' | 'AREAL_LIFT' | 'METRO';
|
|
163
200
|
/**
|
|
164
201
|
* GeoCoding match
|
|
165
202
|
*/
|
|
166
203
|
type Match = {
|
|
167
204
|
type: LocationType;
|
|
205
|
+
/**
|
|
206
|
+
* Experimental. Type categories might be adjusted.
|
|
207
|
+
*
|
|
208
|
+
* For OSM stop locations: the amenity type based on
|
|
209
|
+
* https://wiki.openstreetmap.org/wiki/OpenStreetMap_Carto/Symbols
|
|
210
|
+
*
|
|
211
|
+
*/
|
|
212
|
+
category?: string;
|
|
168
213
|
/**
|
|
169
214
|
* list of non-overlapping tokens that were matched
|
|
170
215
|
*/
|
|
@@ -219,6 +264,14 @@ type Match = {
|
|
|
219
264
|
* score according to the internal scoring system (the scoring algorithm might change in the future)
|
|
220
265
|
*/
|
|
221
266
|
score: number;
|
|
267
|
+
/**
|
|
268
|
+
* available transport modes for stops
|
|
269
|
+
*/
|
|
270
|
+
modes?: Array<Mode>;
|
|
271
|
+
/**
|
|
272
|
+
* importance of a stop, normalized from [0, 1]
|
|
273
|
+
*/
|
|
274
|
+
importance?: number;
|
|
222
275
|
};
|
|
223
276
|
/**
|
|
224
277
|
* Different elevation cost profiles for street routing.
|
|
@@ -242,42 +295,6 @@ type PedestrianSpeed = number;
|
|
|
242
295
|
* Average speed for bike routing in meters per second
|
|
243
296
|
*/
|
|
244
297
|
type CyclingSpeed = number;
|
|
245
|
-
/**
|
|
246
|
-
* # Street modes
|
|
247
|
-
*
|
|
248
|
-
* - `WALK`
|
|
249
|
-
* - `BIKE`
|
|
250
|
-
* - `RENTAL` Experimental. Expect unannounced breaking changes (without version bumps) for all parameters and returned structs.
|
|
251
|
-
* - `CAR`
|
|
252
|
-
* - `CAR_PARKING` Experimental. Expect unannounced breaking changes (without version bumps) for all parameters and returned structs.
|
|
253
|
-
* - `CAR_DROPOFF` Experimental. Expect unannounced breaking changes (without version bumps) for all perameters and returned structs.
|
|
254
|
-
* - `ODM` on-demand taxis from the Prima+ÖV Project
|
|
255
|
-
* - `FLEX` flexible transports
|
|
256
|
-
*
|
|
257
|
-
* # Transit modes
|
|
258
|
-
*
|
|
259
|
-
* - `TRANSIT`: translates to `RAIL,TRAM,BUS,FERRY,AIRPLANE,COACH,CABLE_CAR,FUNICULAR,AREAL_LIFT,OTHER`
|
|
260
|
-
* - `TRAM`: trams
|
|
261
|
-
* - `SUBWAY`: subway trains (Paris Metro, London Underground, but also NYC Subway, Hamburger Hochbahn, and other non-underground services)
|
|
262
|
-
* - `FERRY`: ferries
|
|
263
|
-
* - `AIRPLANE`: airline flights
|
|
264
|
-
* - `BUS`: short distance buses (does not include `COACH`)
|
|
265
|
-
* - `COACH`: long distance buses (does not include `BUS`)
|
|
266
|
-
* - `RAIL`: translates to `HIGHSPEED_RAIL,LONG_DISTANCE,NIGHT_RAIL,REGIONAL_RAIL,REGIONAL_FAST_RAIL,SUBURBAN,SUBWAY`
|
|
267
|
-
* - `SUBURBAN`: suburban trains (e.g. S-Bahn, RER, Elizabeth Line, ...)
|
|
268
|
-
* - `HIGHSPEED_RAIL`: long distance high speed trains (e.g. TGV)
|
|
269
|
-
* - `LONG_DISTANCE`: long distance inter city trains
|
|
270
|
-
* - `NIGHT_RAIL`: long distance night trains
|
|
271
|
-
* - `REGIONAL_FAST_RAIL`: regional express routes that skip low traffic stops to be faster
|
|
272
|
-
* - `REGIONAL_RAIL`: regional train
|
|
273
|
-
* - `CABLE_CAR`: Cable tram. Used for street-level rail cars where the cable runs beneath the vehicle (e.g., cable car in San Francisco).
|
|
274
|
-
* - `FUNICULAR`: Funicular. Any rail system designed for steep inclines.
|
|
275
|
-
* - `AERIAL_LIFT`: Aerial lift, suspended cable car (e.g., gondola lift, aerial tramway). Cable transport where cabins, cars, gondolas or open chairs are suspended by means of one or more cables.
|
|
276
|
-
* - `AREAL_LIFT`: deprecated
|
|
277
|
-
* - `METRO`: deprecated
|
|
278
|
-
*
|
|
279
|
-
*/
|
|
280
|
-
type Mode = 'WALK' | 'BIKE' | 'RENTAL' | 'CAR' | 'CAR_PARKING' | 'CAR_DROPOFF' | 'ODM' | 'FLEX' | 'TRANSIT' | 'TRAM' | 'SUBWAY' | 'FERRY' | 'AIRPLANE' | 'SUBURBAN' | 'BUS' | 'COACH' | 'RAIL' | 'HIGHSPEED_RAIL' | 'LONG_DISTANCE' | 'NIGHT_RAIL' | 'REGIONAL_FAST_RAIL' | 'REGIONAL_RAIL' | 'CABLE_CAR' | 'FUNICULAR' | 'AERIAL_LIFT' | 'OTHER' | 'AREAL_LIFT' | 'METRO';
|
|
281
298
|
/**
|
|
282
299
|
* - `NORMAL` - latitude / longitude coordinate or address
|
|
283
300
|
* - `BIKESHARE` - bike sharing station
|
|
@@ -300,6 +317,14 @@ type Place = {
|
|
|
300
317
|
* The ID of the stop. This is often something that users don't care about.
|
|
301
318
|
*/
|
|
302
319
|
stopId?: string;
|
|
320
|
+
/**
|
|
321
|
+
* If it's not a root stop, this field contains the `stopId` of the parent stop.
|
|
322
|
+
*/
|
|
323
|
+
parentId?: string;
|
|
324
|
+
/**
|
|
325
|
+
* The importance of the stop between 0-1.
|
|
326
|
+
*/
|
|
327
|
+
importance?: number;
|
|
303
328
|
/**
|
|
304
329
|
* latitude
|
|
305
330
|
*/
|
|
@@ -447,6 +472,8 @@ type StopTime = {
|
|
|
447
472
|
agencyId: string;
|
|
448
473
|
agencyName: string;
|
|
449
474
|
agencyUrl: string;
|
|
475
|
+
routeId: string;
|
|
476
|
+
directionId: string;
|
|
450
477
|
routeColor?: string;
|
|
451
478
|
routeTextColor?: string;
|
|
452
479
|
tripId: string;
|
|
@@ -629,6 +656,14 @@ type RentalReturnConstraint = 'NONE' | 'ANY_STATION' | 'ROUNDTRIP_STATION';
|
|
|
629
656
|
* Vehicle rental
|
|
630
657
|
*/
|
|
631
658
|
type Rental = {
|
|
659
|
+
/**
|
|
660
|
+
* Rental provider ID
|
|
661
|
+
*/
|
|
662
|
+
providerId: string;
|
|
663
|
+
/**
|
|
664
|
+
* Rental provider group ID
|
|
665
|
+
*/
|
|
666
|
+
providerGroupId: string;
|
|
632
667
|
/**
|
|
633
668
|
* Vehicle share system ID
|
|
634
669
|
*/
|
|
@@ -641,6 +676,12 @@ type Rental = {
|
|
|
641
676
|
* URL of the vehicle share system
|
|
642
677
|
*/
|
|
643
678
|
url?: string;
|
|
679
|
+
/**
|
|
680
|
+
* Color associated with this provider, in hexadecimal RGB format
|
|
681
|
+
* (e.g. "#FF0000" for red). Can be empty.
|
|
682
|
+
*
|
|
683
|
+
*/
|
|
684
|
+
color?: string;
|
|
644
685
|
/**
|
|
645
686
|
* Name of the station
|
|
646
687
|
*/
|
|
@@ -669,6 +710,305 @@ type Rental = {
|
|
|
669
710
|
propulsionType?: RentalPropulsionType;
|
|
670
711
|
returnConstraint?: RentalReturnConstraint;
|
|
671
712
|
};
|
|
713
|
+
/**
|
|
714
|
+
* A multi-polygon contains a number of polygons, each containing a number
|
|
715
|
+
* of rings, which are encoded as polylines (with precision 6).
|
|
716
|
+
*
|
|
717
|
+
* For each polygon, the first ring is the outer ring, all subsequent rings
|
|
718
|
+
* are inner rings (holes).
|
|
719
|
+
*
|
|
720
|
+
*/
|
|
721
|
+
type MultiPolygon = Array<Array<EncodedPolyline>>;
|
|
722
|
+
type RentalZoneRestrictions = {
|
|
723
|
+
/**
|
|
724
|
+
* List of vehicle types (as indices into the provider's vehicle types
|
|
725
|
+
* array) to which these restrictions apply.
|
|
726
|
+
* If empty, the restrictions apply to all vehicle types of the provider.
|
|
727
|
+
*
|
|
728
|
+
*/
|
|
729
|
+
vehicleTypeIdxs: Array<(number)>;
|
|
730
|
+
/**
|
|
731
|
+
* whether the ride is allowed to start in this zone
|
|
732
|
+
*/
|
|
733
|
+
rideStartAllowed: boolean;
|
|
734
|
+
/**
|
|
735
|
+
* whether the ride is allowed to end in this zone
|
|
736
|
+
*/
|
|
737
|
+
rideEndAllowed: boolean;
|
|
738
|
+
/**
|
|
739
|
+
* whether the ride is allowed to pass through this zone
|
|
740
|
+
*/
|
|
741
|
+
rideThroughAllowed: boolean;
|
|
742
|
+
/**
|
|
743
|
+
* whether vehicles can only be parked at stations in this zone
|
|
744
|
+
*/
|
|
745
|
+
stationParking?: boolean;
|
|
746
|
+
};
|
|
747
|
+
type RentalVehicleType = {
|
|
748
|
+
/**
|
|
749
|
+
* Unique identifier of the vehicle type (unique within the provider)
|
|
750
|
+
*/
|
|
751
|
+
id: string;
|
|
752
|
+
/**
|
|
753
|
+
* Public name of the vehicle type (can be empty)
|
|
754
|
+
*/
|
|
755
|
+
name?: string;
|
|
756
|
+
formFactor: RentalFormFactor;
|
|
757
|
+
propulsionType: RentalPropulsionType;
|
|
758
|
+
returnConstraint: RentalReturnConstraint;
|
|
759
|
+
/**
|
|
760
|
+
* Whether the return constraint was guessed instead of being specified by the rental provider
|
|
761
|
+
*/
|
|
762
|
+
returnConstraintGuessed: boolean;
|
|
763
|
+
};
|
|
764
|
+
type RentalProvider = {
|
|
765
|
+
/**
|
|
766
|
+
* Unique identifier of the rental provider
|
|
767
|
+
*/
|
|
768
|
+
id: string;
|
|
769
|
+
/**
|
|
770
|
+
* Name of the provider to be displayed to customers
|
|
771
|
+
*/
|
|
772
|
+
name: string;
|
|
773
|
+
/**
|
|
774
|
+
* Id of the rental provider group this provider belongs to
|
|
775
|
+
*/
|
|
776
|
+
groupId: string;
|
|
777
|
+
/**
|
|
778
|
+
* Name of the system operator
|
|
779
|
+
*/
|
|
780
|
+
operator?: string;
|
|
781
|
+
/**
|
|
782
|
+
* URL of the vehicle share system
|
|
783
|
+
*/
|
|
784
|
+
url?: string;
|
|
785
|
+
/**
|
|
786
|
+
* URL where a customer can purchase a membership
|
|
787
|
+
*/
|
|
788
|
+
purchaseUrl?: string;
|
|
789
|
+
/**
|
|
790
|
+
* Color associated with this provider, in hexadecimal RGB format
|
|
791
|
+
* (e.g. "#FF0000" for red). Can be empty.
|
|
792
|
+
*
|
|
793
|
+
*/
|
|
794
|
+
color?: string;
|
|
795
|
+
/**
|
|
796
|
+
* Bounding box of the area covered by this rental provider,
|
|
797
|
+
* [west, south, east, north] as [lon, lat, lon, lat]
|
|
798
|
+
*
|
|
799
|
+
*/
|
|
800
|
+
bbox: [
|
|
801
|
+
number,
|
|
802
|
+
number,
|
|
803
|
+
number,
|
|
804
|
+
number
|
|
805
|
+
];
|
|
806
|
+
vehicleTypes: Array<RentalVehicleType>;
|
|
807
|
+
/**
|
|
808
|
+
* List of form factors offered by this provider
|
|
809
|
+
*/
|
|
810
|
+
formFactors: Array<RentalFormFactor>;
|
|
811
|
+
defaultRestrictions: RentalZoneRestrictions;
|
|
812
|
+
globalGeofencingRules: Array<RentalZoneRestrictions>;
|
|
813
|
+
};
|
|
814
|
+
type RentalProviderGroup = {
|
|
815
|
+
/**
|
|
816
|
+
* Unique identifier of the rental provider group
|
|
817
|
+
*/
|
|
818
|
+
id: string;
|
|
819
|
+
/**
|
|
820
|
+
* Name of the provider group to be displayed to customers
|
|
821
|
+
*/
|
|
822
|
+
name: string;
|
|
823
|
+
/**
|
|
824
|
+
* Color associated with this provider group, in hexadecimal RGB format
|
|
825
|
+
* (e.g. "#FF0000" for red). Can be empty.
|
|
826
|
+
*
|
|
827
|
+
*/
|
|
828
|
+
color?: string;
|
|
829
|
+
/**
|
|
830
|
+
* List of rental provider IDs that belong to this group
|
|
831
|
+
*/
|
|
832
|
+
providers: Array<(string)>;
|
|
833
|
+
/**
|
|
834
|
+
* List of form factors offered by this provider group
|
|
835
|
+
*/
|
|
836
|
+
formFactors: Array<RentalFormFactor>;
|
|
837
|
+
};
|
|
838
|
+
type RentalStation = {
|
|
839
|
+
/**
|
|
840
|
+
* Unique identifier of the rental station
|
|
841
|
+
*/
|
|
842
|
+
id: string;
|
|
843
|
+
/**
|
|
844
|
+
* Unique identifier of the rental provider
|
|
845
|
+
*/
|
|
846
|
+
providerId: string;
|
|
847
|
+
/**
|
|
848
|
+
* Unique identifier of the rental provider group
|
|
849
|
+
*/
|
|
850
|
+
providerGroupId: string;
|
|
851
|
+
/**
|
|
852
|
+
* Public name of the station
|
|
853
|
+
*/
|
|
854
|
+
name: string;
|
|
855
|
+
/**
|
|
856
|
+
* latitude
|
|
857
|
+
*/
|
|
858
|
+
lat: number;
|
|
859
|
+
/**
|
|
860
|
+
* longitude
|
|
861
|
+
*/
|
|
862
|
+
lon: number;
|
|
863
|
+
/**
|
|
864
|
+
* Address where the station is located
|
|
865
|
+
*/
|
|
866
|
+
address?: string;
|
|
867
|
+
/**
|
|
868
|
+
* Cross street or landmark where the station is located
|
|
869
|
+
*/
|
|
870
|
+
crossStreet?: string;
|
|
871
|
+
/**
|
|
872
|
+
* Rental URI for Android (deep link to the specific station)
|
|
873
|
+
*/
|
|
874
|
+
rentalUriAndroid?: string;
|
|
875
|
+
/**
|
|
876
|
+
* Rental URI for iOS (deep link to the specific station)
|
|
877
|
+
*/
|
|
878
|
+
rentalUriIOS?: string;
|
|
879
|
+
/**
|
|
880
|
+
* Rental URI for web (deep link to the specific station)
|
|
881
|
+
*/
|
|
882
|
+
rentalUriWeb?: string;
|
|
883
|
+
/**
|
|
884
|
+
* true if vehicles can be rented from this station, false if it is temporarily out of service
|
|
885
|
+
*/
|
|
886
|
+
isRenting: boolean;
|
|
887
|
+
/**
|
|
888
|
+
* true if vehicles can be returned to this station, false if it is temporarily out of service
|
|
889
|
+
*/
|
|
890
|
+
isReturning: boolean;
|
|
891
|
+
/**
|
|
892
|
+
* Number of vehicles available for rental at this station
|
|
893
|
+
*/
|
|
894
|
+
numVehiclesAvailable: number;
|
|
895
|
+
/**
|
|
896
|
+
* List of form factors available for rental and/or return at this station
|
|
897
|
+
*/
|
|
898
|
+
formFactors: Array<RentalFormFactor>;
|
|
899
|
+
/**
|
|
900
|
+
* List of vehicle types currently available at this station (vehicle type ID -> count)
|
|
901
|
+
*/
|
|
902
|
+
vehicleTypesAvailable: {
|
|
903
|
+
[key: string]: (number);
|
|
904
|
+
};
|
|
905
|
+
/**
|
|
906
|
+
* List of vehicle docks currently available at this station (vehicle type ID -> count)
|
|
907
|
+
*/
|
|
908
|
+
vehicleDocksAvailable: {
|
|
909
|
+
[key: string]: (number);
|
|
910
|
+
};
|
|
911
|
+
stationArea?: MultiPolygon;
|
|
912
|
+
/**
|
|
913
|
+
* Bounding box of the area covered by this station,
|
|
914
|
+
* [west, south, east, north] as [lon, lat, lon, lat]
|
|
915
|
+
*
|
|
916
|
+
*/
|
|
917
|
+
bbox: [
|
|
918
|
+
number,
|
|
919
|
+
number,
|
|
920
|
+
number,
|
|
921
|
+
number
|
|
922
|
+
];
|
|
923
|
+
};
|
|
924
|
+
type RentalVehicle = {
|
|
925
|
+
/**
|
|
926
|
+
* Unique identifier of the rental vehicle
|
|
927
|
+
*/
|
|
928
|
+
id: string;
|
|
929
|
+
/**
|
|
930
|
+
* Unique identifier of the rental provider
|
|
931
|
+
*/
|
|
932
|
+
providerId: string;
|
|
933
|
+
/**
|
|
934
|
+
* Unique identifier of the rental provider group
|
|
935
|
+
*/
|
|
936
|
+
providerGroupId: string;
|
|
937
|
+
/**
|
|
938
|
+
* Vehicle type ID (unique within the provider)
|
|
939
|
+
*/
|
|
940
|
+
typeId: string;
|
|
941
|
+
/**
|
|
942
|
+
* latitude
|
|
943
|
+
*/
|
|
944
|
+
lat: number;
|
|
945
|
+
/**
|
|
946
|
+
* longitude
|
|
947
|
+
*/
|
|
948
|
+
lon: number;
|
|
949
|
+
formFactor: RentalFormFactor;
|
|
950
|
+
propulsionType: RentalPropulsionType;
|
|
951
|
+
returnConstraint: RentalReturnConstraint;
|
|
952
|
+
/**
|
|
953
|
+
* Station ID if the vehicle is currently at a station
|
|
954
|
+
*/
|
|
955
|
+
stationId?: string;
|
|
956
|
+
/**
|
|
957
|
+
* Station ID where the vehicle must be returned, if applicable
|
|
958
|
+
*/
|
|
959
|
+
homeStationId?: string;
|
|
960
|
+
/**
|
|
961
|
+
* true if the vehicle is currently reserved by a customer, false otherwise
|
|
962
|
+
*/
|
|
963
|
+
isReserved: boolean;
|
|
964
|
+
/**
|
|
965
|
+
* true if the vehicle is out of service, false otherwise
|
|
966
|
+
*/
|
|
967
|
+
isDisabled: boolean;
|
|
968
|
+
/**
|
|
969
|
+
* Rental URI for Android (deep link to the specific vehicle)
|
|
970
|
+
*/
|
|
971
|
+
rentalUriAndroid?: string;
|
|
972
|
+
/**
|
|
973
|
+
* Rental URI for iOS (deep link to the specific vehicle)
|
|
974
|
+
*/
|
|
975
|
+
rentalUriIOS?: string;
|
|
976
|
+
/**
|
|
977
|
+
* Rental URI for web (deep link to the specific vehicle)
|
|
978
|
+
*/
|
|
979
|
+
rentalUriWeb?: string;
|
|
980
|
+
};
|
|
981
|
+
type RentalZone = {
|
|
982
|
+
/**
|
|
983
|
+
* Unique identifier of the rental provider
|
|
984
|
+
*/
|
|
985
|
+
providerId: string;
|
|
986
|
+
/**
|
|
987
|
+
* Unique identifier of the rental provider group
|
|
988
|
+
*/
|
|
989
|
+
providerGroupId: string;
|
|
990
|
+
/**
|
|
991
|
+
* Public name of the geofencing zone
|
|
992
|
+
*/
|
|
993
|
+
name?: string;
|
|
994
|
+
/**
|
|
995
|
+
* Zone precedence / z-index (higher number = higher precedence)
|
|
996
|
+
*/
|
|
997
|
+
z: number;
|
|
998
|
+
/**
|
|
999
|
+
* Bounding box of the area covered by this zone,
|
|
1000
|
+
* [west, south, east, north] as [lon, lat, lon, lat]
|
|
1001
|
+
*
|
|
1002
|
+
*/
|
|
1003
|
+
bbox: [
|
|
1004
|
+
number,
|
|
1005
|
+
number,
|
|
1006
|
+
number,
|
|
1007
|
+
number
|
|
1008
|
+
];
|
|
1009
|
+
area: MultiPolygon;
|
|
1010
|
+
rules: Array<RentalZoneRestrictions>;
|
|
1011
|
+
};
|
|
672
1012
|
type Leg = {
|
|
673
1013
|
/**
|
|
674
1014
|
* Transport mode for this leg
|
|
@@ -736,6 +1076,8 @@ type Leg = {
|
|
|
736
1076
|
* final stop of this trip (can differ from headsign)
|
|
737
1077
|
*/
|
|
738
1078
|
tripTo?: Place;
|
|
1079
|
+
routeId?: string;
|
|
1080
|
+
directionId?: string;
|
|
739
1081
|
routeColor?: string;
|
|
740
1082
|
routeTextColor?: string;
|
|
741
1083
|
routeType?: number;
|
|
@@ -950,6 +1292,53 @@ type Transfer = {
|
|
|
950
1292
|
*/
|
|
951
1293
|
car?: number;
|
|
952
1294
|
};
|
|
1295
|
+
type OneToManyParams = {
|
|
1296
|
+
/**
|
|
1297
|
+
* geo location as latitude;longitude
|
|
1298
|
+
*/
|
|
1299
|
+
one: string;
|
|
1300
|
+
/**
|
|
1301
|
+
* geo locations as latitude;longitude,latitude;longitude,...
|
|
1302
|
+
*/
|
|
1303
|
+
many: Array<(string)>;
|
|
1304
|
+
/**
|
|
1305
|
+
* routing profile to use (currently supported: \`WALK\`, \`BIKE\`, \`CAR\`)
|
|
1306
|
+
*
|
|
1307
|
+
*/
|
|
1308
|
+
mode: Mode;
|
|
1309
|
+
/**
|
|
1310
|
+
* maximum travel time in seconds
|
|
1311
|
+
*/
|
|
1312
|
+
max: number;
|
|
1313
|
+
/**
|
|
1314
|
+
* maximum matching distance in meters to match geo coordinates to the street network
|
|
1315
|
+
*/
|
|
1316
|
+
maxMatchingDistance: number;
|
|
1317
|
+
/**
|
|
1318
|
+
* Optional. Default is `NONE`.
|
|
1319
|
+
*
|
|
1320
|
+
* Set an elevation cost profile, to penalize routes with incline.
|
|
1321
|
+
* - `NONE`: No additional costs for elevations. This is the default behavior
|
|
1322
|
+
* - `LOW`: Add a low cost for increase in elevation and incline along the way. This will prefer routes with less ascent, if small detours are required.
|
|
1323
|
+
* - `HIGH`: Add a high cost for increase in elevation and incline along the way. This will prefer routes with less ascent, if larger detours are required.
|
|
1324
|
+
*
|
|
1325
|
+
* As using an elevation costs profile will increase the travel duration,
|
|
1326
|
+
* routing through steep terrain may exceed the maximal allowed duration,
|
|
1327
|
+
* causing a location to appear unreachable.
|
|
1328
|
+
* Increasing the maximum travel time for these segments may resolve this issue.
|
|
1329
|
+
*
|
|
1330
|
+
* Elevation cost profiles are currently used by following street modes:
|
|
1331
|
+
* - `BIKE`
|
|
1332
|
+
*
|
|
1333
|
+
*/
|
|
1334
|
+
elevationCosts: ElevationCosts;
|
|
1335
|
+
/**
|
|
1336
|
+
* true = many to one
|
|
1337
|
+
* false = one to many
|
|
1338
|
+
*
|
|
1339
|
+
*/
|
|
1340
|
+
arriveBy: boolean;
|
|
1341
|
+
};
|
|
953
1342
|
type Error = {
|
|
954
1343
|
error?: string;
|
|
955
1344
|
};
|
|
@@ -965,7 +1354,7 @@ type PlanData = {
|
|
|
965
1354
|
/**
|
|
966
1355
|
* algorithm to use
|
|
967
1356
|
*/
|
|
968
|
-
algorithm?: 'RAPTOR' | 'TB';
|
|
1357
|
+
algorithm?: 'RAPTOR' | 'PONG' | 'TB';
|
|
969
1358
|
/**
|
|
970
1359
|
* Optional. Default is `false`.
|
|
971
1360
|
*
|
|
@@ -1027,6 +1416,16 @@ type PlanData = {
|
|
|
1027
1416
|
*
|
|
1028
1417
|
*/
|
|
1029
1418
|
directRentalPropulsionTypes?: Array<RentalPropulsionType>;
|
|
1419
|
+
/**
|
|
1420
|
+
* Experimental. Expect unannounced breaking changes (without version bumps).
|
|
1421
|
+
*
|
|
1422
|
+
* Optional. Only applies to direct connections.
|
|
1423
|
+
*
|
|
1424
|
+
* A list of rental provider groups that are allowed to be used for direct connections.
|
|
1425
|
+
* If empty (the default), all providers are allowed.
|
|
1426
|
+
*
|
|
1427
|
+
*/
|
|
1428
|
+
directRentalProviderGroups?: Array<(string)>;
|
|
1030
1429
|
/**
|
|
1031
1430
|
* Experimental. Expect unannounced breaking changes (without version bumps).
|
|
1032
1431
|
*
|
|
@@ -1128,7 +1527,7 @@ type PlanData = {
|
|
|
1128
1527
|
* (usually BCP-47 / ISO 639-1, or ISO 639-2 if there's no ISO 639-1)
|
|
1129
1528
|
*
|
|
1130
1529
|
*/
|
|
1131
|
-
language?: string
|
|
1530
|
+
language?: Array<(string)>;
|
|
1132
1531
|
/**
|
|
1133
1532
|
* Optional. Experimental. Number of luggage pieces; base unit: airline cabin luggage (e.g. for ODM or price calculation)
|
|
1134
1533
|
*
|
|
@@ -1141,6 +1540,23 @@ type PlanData = {
|
|
|
1141
1540
|
*
|
|
1142
1541
|
*/
|
|
1143
1542
|
maxDirectTime?: number;
|
|
1543
|
+
/**
|
|
1544
|
+
* Optional. By default all computed itineraries will be returned
|
|
1545
|
+
*
|
|
1546
|
+
* The maximum number of itineraries to compute.
|
|
1547
|
+
* This is only relevant if `timetableView=true`.
|
|
1548
|
+
*
|
|
1549
|
+
* Note: With the current implementation, setting this to a lower
|
|
1550
|
+
* number will not result in any speedup.
|
|
1551
|
+
*
|
|
1552
|
+
* Note: The number of returned itineraries might be slightly higher
|
|
1553
|
+
* than `maxItineraries` as there might be several itineraries with
|
|
1554
|
+
* the same departure time but different number of transfers. In order
|
|
1555
|
+
* to not miss any itineraries for paging, either none or all
|
|
1556
|
+
* itineraries with the same departure time have to be returned.
|
|
1557
|
+
*
|
|
1558
|
+
*/
|
|
1559
|
+
maxItineraries?: number;
|
|
1144
1560
|
/**
|
|
1145
1561
|
* Optional. Default is 25 meters.
|
|
1146
1562
|
*
|
|
@@ -1263,6 +1679,16 @@ type PlanData = {
|
|
|
1263
1679
|
*
|
|
1264
1680
|
*/
|
|
1265
1681
|
postTransitRentalPropulsionTypes?: Array<RentalPropulsionType>;
|
|
1682
|
+
/**
|
|
1683
|
+
* Experimental. Expect unannounced breaking changes (without version bumps).
|
|
1684
|
+
*
|
|
1685
|
+
* Optional. Only applies if the `to` place is a coordinate (not a transit stop). Does not apply to direct connections (see `directRentalProviderGroups`).
|
|
1686
|
+
*
|
|
1687
|
+
* A list of rental provider groups that are allowed to be used from the last transit stop to the `to` coordinate.
|
|
1688
|
+
* If empty (the default), all providers are allowed.
|
|
1689
|
+
*
|
|
1690
|
+
*/
|
|
1691
|
+
postTransitRentalProviderGroups?: Array<(string)>;
|
|
1266
1692
|
/**
|
|
1267
1693
|
* Experimental. Expect unannounced breaking changes (without version bumps).
|
|
1268
1694
|
*
|
|
@@ -1302,6 +1728,16 @@ type PlanData = {
|
|
|
1302
1728
|
*
|
|
1303
1729
|
*/
|
|
1304
1730
|
preTransitRentalPropulsionTypes?: Array<RentalPropulsionType>;
|
|
1731
|
+
/**
|
|
1732
|
+
* Experimental. Expect unannounced breaking changes (without version bumps).
|
|
1733
|
+
*
|
|
1734
|
+
* Optional. Only applies if the `from` place is a coordinate (not a transit stop). Does not apply to direct connections (see `directRentalProviderGroups`).
|
|
1735
|
+
*
|
|
1736
|
+
* A list of rental provider groups that are allowed to be used from the `from` coordinate to the first transit stop.
|
|
1737
|
+
* If empty (the default), all providers are allowed.
|
|
1738
|
+
*
|
|
1739
|
+
*/
|
|
1740
|
+
preTransitRentalProviderGroups?: Array<(string)>;
|
|
1305
1741
|
/**
|
|
1306
1742
|
* Experimental. Expect unannounced breaking changes (without version bumps).
|
|
1307
1743
|
*
|
|
@@ -1327,9 +1763,9 @@ type PlanData = {
|
|
|
1327
1763
|
*/
|
|
1328
1764
|
requireCarTransport?: boolean;
|
|
1329
1765
|
/**
|
|
1330
|
-
* Optional. Default is
|
|
1766
|
+
* Optional. Default is 15 minutes which is `900`.
|
|
1331
1767
|
*
|
|
1332
|
-
* The length of the search-window in seconds. Default value
|
|
1768
|
+
* The length of the search-window in seconds. Default value 15 minutes.
|
|
1333
1769
|
*
|
|
1334
1770
|
* - `arriveBy=true`: number of seconds between the earliest departure time and latest departure time
|
|
1335
1771
|
* - `arriveBy=false`: number of seconds between the earliest arrival time and the latest arrival time
|
|
@@ -1736,7 +2172,13 @@ type GeocodeData = {
|
|
|
1736
2172
|
* (usually ISO 639-1, or ISO 639-2 if there's no ISO 639-1)
|
|
1737
2173
|
*
|
|
1738
2174
|
*/
|
|
1739
|
-
language?: string
|
|
2175
|
+
language?: Array<(string)>;
|
|
2176
|
+
/**
|
|
2177
|
+
* Optional. Filter stops by available transport modes.
|
|
2178
|
+
* Defaults to applying no filter.
|
|
2179
|
+
*
|
|
2180
|
+
*/
|
|
2181
|
+
mode?: Array<Mode>;
|
|
1740
2182
|
/**
|
|
1741
2183
|
* Optional. Used for biasing results towards the coordinate.
|
|
1742
2184
|
*
|
|
@@ -1782,7 +2224,7 @@ type TripData = {
|
|
|
1782
2224
|
* (usually BCP-47 / ISO 639-1, or ISO 639-2 if there's no ISO 639-1)
|
|
1783
2225
|
*
|
|
1784
2226
|
*/
|
|
1785
|
-
language?: string
|
|
2227
|
+
language?: Array<(string)>;
|
|
1786
2228
|
/**
|
|
1787
2229
|
* trip identifier (e.g. from an itinerary leg or stop event)
|
|
1788
2230
|
*/
|
|
@@ -1839,7 +2281,7 @@ type StoptimesData = {
|
|
|
1839
2281
|
* (usually BCP-47 / ISO 639-1, or ISO 639-2 if there's no ISO 639-1)
|
|
1840
2282
|
*
|
|
1841
2283
|
*/
|
|
1842
|
-
language?: string
|
|
2284
|
+
language?: Array<(string)>;
|
|
1843
2285
|
/**
|
|
1844
2286
|
* Optional. Default is all transit modes.
|
|
1845
2287
|
*
|
|
@@ -1976,6 +2418,60 @@ type LevelsData = {
|
|
|
1976
2418
|
};
|
|
1977
2419
|
type LevelsResponse = (Array<(number)>);
|
|
1978
2420
|
type LevelsError = (Error);
|
|
2421
|
+
type RentalsData = {
|
|
2422
|
+
query?: {
|
|
2423
|
+
/**
|
|
2424
|
+
* latitude,longitude pair of the upper left coordinate
|
|
2425
|
+
*/
|
|
2426
|
+
max?: string;
|
|
2427
|
+
/**
|
|
2428
|
+
* latitude,longitude pair of the lower right coordinate
|
|
2429
|
+
*/
|
|
2430
|
+
min?: string;
|
|
2431
|
+
/**
|
|
2432
|
+
* A list of rental provider groups to return.
|
|
2433
|
+
* If both `providerGroups` and `providers` are empty/not specified,
|
|
2434
|
+
* all providers in the map section are returned.
|
|
2435
|
+
*
|
|
2436
|
+
*/
|
|
2437
|
+
providerGroups?: Array<(string)>;
|
|
2438
|
+
/**
|
|
2439
|
+
* A list of rental providers to return.
|
|
2440
|
+
* If both `providerGroups` and `providers` are empty/not specified,
|
|
2441
|
+
* all providers in the map section are returned.
|
|
2442
|
+
*
|
|
2443
|
+
*/
|
|
2444
|
+
providers?: Array<(string)>;
|
|
2445
|
+
/**
|
|
2446
|
+
* Optional. Include providers in output. If false, only provider
|
|
2447
|
+
* groups are returned.
|
|
2448
|
+
*
|
|
2449
|
+
* Also affects the providers list for each provider group.
|
|
2450
|
+
*
|
|
2451
|
+
*/
|
|
2452
|
+
withProviders?: boolean;
|
|
2453
|
+
/**
|
|
2454
|
+
* Optional. Include stations in output (requires at least min+max or providers filter).
|
|
2455
|
+
*/
|
|
2456
|
+
withStations?: boolean;
|
|
2457
|
+
/**
|
|
2458
|
+
* Optional. Include free-floating vehicles in output (requires at least min+max or providers filter).
|
|
2459
|
+
*/
|
|
2460
|
+
withVehicles?: boolean;
|
|
2461
|
+
/**
|
|
2462
|
+
* Optional. Include geofencing zones in output (requires at least min+max or providers filter).
|
|
2463
|
+
*/
|
|
2464
|
+
withZones?: boolean;
|
|
2465
|
+
};
|
|
2466
|
+
};
|
|
2467
|
+
type RentalsResponse = ({
|
|
2468
|
+
providerGroups: Array<RentalProviderGroup>;
|
|
2469
|
+
providers: Array<RentalProvider>;
|
|
2470
|
+
stations: Array<RentalStation>;
|
|
2471
|
+
vehicles: Array<RentalVehicle>;
|
|
2472
|
+
zones: Array<RentalZone>;
|
|
2473
|
+
});
|
|
2474
|
+
type RentalsError = (Error);
|
|
1979
2475
|
type TransfersData = {
|
|
1980
2476
|
query: {
|
|
1981
2477
|
/**
|
|
@@ -1986,6 +2482,8 @@ type TransfersData = {
|
|
|
1986
2482
|
};
|
|
1987
2483
|
type TransfersResponse = ({
|
|
1988
2484
|
place: Place;
|
|
2485
|
+
root: Place;
|
|
2486
|
+
equivalences: Array<Place>;
|
|
1989
2487
|
/**
|
|
1990
2488
|
* true if the server has foot transfers computed
|
|
1991
2489
|
*/
|
|
@@ -2005,4 +2503,4 @@ type TransfersResponse = ({
|
|
|
2005
2503
|
});
|
|
2006
2504
|
type TransfersError = unknown;
|
|
2007
2505
|
|
|
2008
|
-
export type { Alert, AlertCause, AlertEffect, AlertSeverityLevel, Area, CyclingSpeed, Direction, Duration, ElevationCosts, EncodedPolyline, Error, FareMedia, FareMediaType, FareProduct, FareTransfer, FareTransferRule, GeocodeData, GeocodeError, GeocodeResponse, InitialError, InitialResponse, Itinerary, Leg, LevelsData, LevelsError, LevelsResponse, LocationType, Match, Mode, OneToAllData, OneToAllError, OneToAllResponse, OneToManyData, OneToManyError, OneToManyResponse, PedestrianProfile, PedestrianSpeed, PickupDropoffType, Place, PlanData, PlanError, PlanResponse, Reachable, ReachablePlace, Rental, RentalFormFactor, RentalPropulsionType, RentalReturnConstraint, ReverseGeocodeData, ReverseGeocodeError, ReverseGeocodeResponse, RiderCategory, StepInstruction, StopTime, StopsData, StopsError, StopsResponse, StoptimesData, StoptimesError, StoptimesResponse, TimeRange, Token, Transfer, TransfersData, TransfersError, TransfersResponse, TripData, TripError, TripInfo, TripResponse, TripSegment, TripsData, TripsError, TripsResponse, VertexType };
|
|
2506
|
+
export type { Alert, AlertCause, AlertEffect, AlertSeverityLevel, Area, CyclingSpeed, Direction, Duration, ElevationCosts, EncodedPolyline, Error, FareMedia, FareMediaType, FareProduct, FareTransfer, FareTransferRule, GeocodeData, GeocodeError, GeocodeResponse, InitialError, InitialResponse, Itinerary, Leg, LevelsData, LevelsError, LevelsResponse, LocationType, Match, Mode, MultiPolygon, OneToAllData, OneToAllError, OneToAllResponse, OneToManyData, OneToManyError, OneToManyParams, OneToManyResponse, PedestrianProfile, PedestrianSpeed, PickupDropoffType, Place, PlanData, PlanError, PlanResponse, Reachable, ReachablePlace, Rental, RentalFormFactor, RentalPropulsionType, RentalProvider, RentalProviderGroup, RentalReturnConstraint, RentalStation, RentalVehicle, RentalVehicleType, RentalZone, RentalZoneRestrictions, RentalsData, RentalsError, RentalsResponse, ReverseGeocodeData, ReverseGeocodeError, ReverseGeocodeResponse, RiderCategory, StepInstruction, StopTime, StopsData, StopsError, StopsResponse, StoptimesData, StoptimesError, StoptimesResponse, TimeRange, Token, Transfer, TransfersData, TransfersError, TransfersResponse, TripData, TripError, TripInfo, TripResponse, TripSegment, TripsData, TripsError, TripsResponse, VertexType };
|