Journey Planner API client library
Project description
Journeyplanner
A client for accessing the Journey Planner (Rejseplanen) API.
Installation
The journeyplanner library can be installed using pip:
$ pip install journeyplanner
Examples
client = JourneyPlanner()
dt = datetime(2019, 1, 8, 12, 0, 0)
origin = Endpoint(latitude=55.68325233, longitude=12.57150292, name="noerreport")
destination = Endpoint(latitude=55.67271128, longitude=12.56635308, name="hovedbanen")
trip = client.trip(origin, destination, date=dt.date(), time=dt.time())
print(list(trip))
Authentication
client = JourneyPlanner()
client.authenticate('USERNAME', 'PASSWORD')
API reference
Trip objects
Trip instances have the following attributes:
Trip.legs
List of leg instances
Leg objects
Leg instances have the following attributes:
Leg.name
Leg.type
Leg.origin
Leg.destination
Leg.notes
Project details
Release history Release notifications
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size journeyplanner-1.0.1-py3-none-any.whl (8.4 kB) | File type Wheel | Python version py3 | Upload date | Hashes View hashes |
Filename, size journeyplanner-1.0.1.tar.gz (6.3 kB) | File type Source | Python version None | Upload date | Hashes View hashes |
Close
Hashes for journeyplanner-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4c674c00936b5297dc74f6fb19ef0b97ce0864e1b33be01f71a358b1b08a74e0 |
|
MD5 | f28fdac7120b52816373349dc216d3ef |
|
BLAKE2-256 | b4152585173f7b40c81ee9e4ba3658ca8d38ad13760d228e140553067a28a84e |