Skip to main content

Automates creation of requests to, and parsing of response from Google's geocoding API.

Project description

A simple wrapper for Google's geocoding api.

Get address data from coordinates or coordinates from an address in one function call. No need to bother with creation of requests and parsing of responses. Distance from a Location to another is available as a method.

from gloc import Location

location = Location.from_coordinates(57.696994, 11.986500)

same_location = Location.from_address("Skånegatan 59, 412 52 Göteborg, Sweden")

distance = location.distance_to(same_location)

Put an api-key in a file named google_api_key.txt in working directory or set environment variable GOOGLE_API_KEY.

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

gloc-0.2.1.tar.gz (10.0 kB view hashes)

Uploaded Source

Built Distribution

gloc-0.2.1-py3-none-any.whl (6.8 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page