Skip to main content

Python Client for Neshan Services

Build Status PyPI version

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

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

Metadata

Release files for neshan 1.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for neshan 1.1.1
File Size Uploaded Provenance
neshan-1.1.1.tar.gz 22.4 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for neshan 1.1.1
File Interpreter ABI Platform
neshan-1.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 44.6 kB

Release files / neshan-1.1.1.tar.gz

Download URL neshan-1.1.1.tar.gz
Size 22.4 kB
Tags Source
SHA-256 checksum
How to use checksums
f1cef53a7ace92b446b93f20a01da66b9d1d54c0556ba127b53b028a089ec51f
BLAKE2b-256 checksum
How to use checksums
c40e9cb118f72298133e73599123f5bcae360e72658042e1d033a0f9e00eec6f
Upload date
Uploaded using Trusted Publishing?
What is 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

Release files / neshan-1.1.1-py3-none-any.whl

Download URL neshan-1.1.1-py3-none-any.whl
Size 22.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
20b3bb29f27c3d3e5d11db69715403c7b120296542defd339089d91e78469f96
BLAKE2b-256 checksum
How to use checksums
0ef9d1e6927aedd06b91fd4c700dcfac3e8111e274fe6c4f888b75d5554a3dad
Upload date
Uploaded using Trusted Publishing?
What is 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

Security for neshan 1.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page