Python client library for Neshan maps
Project description
Python Client for Neshan Services
Description
This library is a duplication of https://github.com/googlemaps/google-maps-services-python which is changed to work with Neshan APIs. Please open an issue if you have any questions.
The Python Client for Neshan Services is a Python Client library for the following Neshan APIs:
- Static Maps
- Directions API
- Distance Matrix API
- Reverse Geocoding API
- Map Matching API
- Search API
Requirements
- Python 3.5 or later.
- A Neshan API key.
Installation
$ pip install -U neshan
Note that you will need requests 2.4.0 or higher if you want to specify connect/read timeouts.
Usage
This example uses the Geocoding API and the Directions API with an API key:
import neshan
from datetime import datetime
nmaps = neshan.Client(key='Add Your Key here')
# Look up an address with reverse geocoding
reverse_geocode_result = nmaps.reverse_geocode((40.714224, -73.961452))
# Request directions via public transit
now = datetime.now()
directions_result = nmaps.direction((36.268706, 59.610011),
(36.287607, 59.599527))
Features
Retry on Failure
Automatically retry when intermittent failures occur. That is, when any of the retriable 5xx errors are returned from the API.
Building the Project
# Installing nox
$ pip install nox
# Running tests
$ nox
# Generating documentation
$ nox -e docs
# Copy docs to gh-pages
$ nox -e docs && mv docs/_build/html generated_docs && git clean -Xdi && git checkout gh-pages
Documentation & resources
API docs
- Get Started with Neshan Platform
- Directions API
- Distance Matrix API
- Reverse Geocoding API
- Map Matching API
- Search API
Support
Changelog
All notable changes to this project will be documented in this file.
[v1.1.1]
Fixed
- Readme.md and pypi package description
[v1.1.0]
Added
- Static maps api
[v1.0.0]
Added
- Initial version
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
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 neshan-1.1.1.tar.gz.
File metadata
- Download URL: neshan-1.1.1.tar.gz
- Upload date:
- Size: 22.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f1cef53a7ace92b446b93f20a01da66b9d1d54c0556ba127b53b028a089ec51f
|
|
| MD5 |
694e2e85a02db5c80187cff8ef1c7db3
|
|
| BLAKE2b-256 |
c40e9cb118f72298133e73599123f5bcae360e72658042e1d033a0f9e00eec6f
|
File details
Details for the file neshan-1.1.1-py3-none-any.whl.
File metadata
- Download URL: neshan-1.1.1-py3-none-any.whl
- Upload date:
- Size: 22.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
20b3bb29f27c3d3e5d11db69715403c7b120296542defd339089d91e78469f96
|
|
| MD5 |
07955990247bd9d6f49aaf195c6889fd
|
|
| BLAKE2b-256 |
0ef9d1e6927aedd06b91fd4c700dcfac3e8111e274fe6c4f888b75d5554a3dad
|