You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+116Lines changed: 116 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -752,3 +752,119 @@ async def main():
752
752
753
753
asyncio.run(main())
754
754
```
755
+
756
+
## Parameter usage examples
757
+
758
+
### Transportation
759
+
760
+
In [traveltime.py](https://github.com/traveltime-dev/traveltime-python-sdk/blob/master/traveltimepy/dto/transportation.py)
761
+
you can find all implemented transportation types, their sub-parameters and their default values.
762
+
763
+
These examples don't apply to proto / fast endpoints. For more examples you can always refer to [Unit Tests](https://github.com/traveltime-dev/traveltime-python-sdk/tree/master/tests)
from traveltimepy import PublicTransport, MaxChanges
821
+
822
+
transportation=PublicTransport() # type="public_transport" - any public transport
823
+
transportation=PublicTransport(type="train")
824
+
transportation=PublicTransport(type="bus")
825
+
transportation=PublicTransport(type="coach")
826
+
827
+
transportation=PublicTransport(
828
+
pt_change_delay=300,
829
+
walking_time=500,
830
+
max_changes=MaxChanges(enabled=True, limit=3)
831
+
)
832
+
```
833
+
834
+
#### CyclingPublicTransport
835
+
836
+
```python
837
+
from traveltimepy import CyclingPublicTransport, MaxChanges
838
+
839
+
transportation=CyclingPublicTransport()
840
+
841
+
transportation=CyclingPublicTransport(
842
+
walking_time=500,
843
+
pt_change_delay=300,
844
+
cycling_time_to_station=300,
845
+
parking_time=800,
846
+
boarding_time=300,
847
+
max_changes=MaxChanges(enabled=True, limit=3)
848
+
)
849
+
```
850
+
851
+
### Level of Detail
852
+
853
+
`level_of_detail` can be used to specify how detailed the isochrone result should be.
854
+
855
+
For a more detailed description of how to use this parameter, you can refer to our [API Docs](https://docs.traveltime.com/api/reference/isochrones#arrival_searches-level_of_detail)
0 commit comments