Asynchronous Python client for the HERE Routing V8 API
Project description
here_routing
Asynchronous Python client for the HERE Routing V8 API
Installation
pip install here_routing
Usage
import asyncio
from here_routing import HERERoutingApi, Place, Return, TransportMode
API_KEY = "<YOUR_API_KEY>"
async def main() -> None:
"""Show example how to get duration of your route."""
async with HERERoutingApi(api_key=API_KEY) as here_routing:
response = await here_routing.route(
transport_mode=TransportMode.CAR,
origin=Place(latitude=50.12778680095556, longitude=8.582081794738771),
destination=Place(latitude=50.060940891421765, longitude=8.336477279663088),
return_values=[Return.SUMMARY],
)
print(
f"Duration is: {response['routes'][0]['sections'][0]['summary']['duration']}"
)
if __name__ == "__main__":
asyncio.run(main())
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
here_routing-0.2.0.tar.gz
(6.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file here_routing-0.2.0.tar.gz.
File metadata
- Download URL: here_routing-0.2.0.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.9.2 readme-renderer/37.3 requests/2.28.1 requests-toolbelt/0.10.1 urllib3/1.26.13 tqdm/4.64.1 importlib-metadata/5.1.0 keyring/23.11.0 rfc3986/2.0.0 colorama/0.4.6 CPython/3.9.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3764b837857f71a4892ca99f7da92eb8ee04d36ac5571099195a2fe3bd56c39d
|
|
| MD5 |
1106720cbea4a652966303aaecc209be
|
|
| BLAKE2b-256 |
b7b91ab6a5065c29fa396394dfe6e034b23781c8692c5d23412b86ee25b9a425
|
File details
Details for the file here_routing-0.2.0-py3-none-any.whl.
File metadata
- Download URL: here_routing-0.2.0-py3-none-any.whl
- Upload date:
- Size: 6.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.9.2 readme-renderer/37.3 requests/2.28.1 requests-toolbelt/0.10.1 urllib3/1.26.13 tqdm/4.64.1 importlib-metadata/5.1.0 keyring/23.11.0 rfc3986/2.0.0 colorama/0.4.6 CPython/3.9.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c9b15fd6a3453486853f6dbad4c5d04f9d4f6b53de684705251f546be83f848e
|
|
| MD5 |
13afe2300a77ee3cb9c26facb8a6dcff
|
|
| BLAKE2b-256 |
570472d5e637dfebc3758cfaf1b88f529d24abefb1ca9e404da7d83f2d2e7919
|