{"id":17269067,"url":"https://github.com/bennylope/pygeocodio","last_synced_at":"2025-05-16T04:03:35.565Z","repository":{"id":13439686,"uuid":"16128840","full_name":"bennylope/pygeocodio","owner":"bennylope","description":":globe_with_meridians: A Python wrapper for the Geocodio geolocation service API","archived":false,"fork":false,"pushed_at":"2024-10-30T19:12:21.000Z","size":184,"stargazers_count":99,"open_issues_count":3,"forks_count":21,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-05-06T20:51:00.592Z","etag":null,"topics":["api","api-client","geocoding","geocodio","python"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bennylope.png","metadata":{"files":{"readme":"README.rst","changelog":"HISTORY.rst","contributing":"CONTRIBUTING.rst","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS.rst","dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-01-22T04:34:55.000Z","updated_at":"2025-03-06T17:11:31.000Z","dependencies_parsed_at":"2024-06-18T21:33:43.694Z","dependency_job_id":"ca084213-f145-41ff-bddb-f3a97a128fc2","html_url":"https://github.com/bennylope/pygeocodio","commit_stats":null,"previous_names":[],"tags_count":26,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bennylope%2Fpygeocodio","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bennylope%2Fpygeocodio/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bennylope%2Fpygeocodio/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bennylope%2Fpygeocodio/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bennylope","download_url":"https://codeload.github.com/bennylope/pygeocodio/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254464891,"owners_count":22075570,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","api-client","geocoding","geocodio","python"],"created_at":"2024-10-15T08:15:15.641Z","updated_at":"2025-05-16T04:03:35.232Z","avatar_url":"https://github.com/bennylope.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"===========\nPy-Geocodio\n===========\n\n.. image:: https://badge.fury.io/py/pygeocodio.svg\n    :target: http://badge.fury.io/py/pygeocodio\n\n.. image:: https://github.com/bennylope/pygeocodio/actions/workflows/tests.yml/badge.svg?branch=master\n    :target: https://github.com/bennylope/pygeocodio/actions\n\n.. image:: https://img.shields.io/pypi/dm/pygeocodio.svg\n        :target: https://img.shields.io/pypi/dm/pygeocodio.svg\n\n\nPython wrapper for `Geocodio geocoding API \u003chttp://geocod.io/docs/\u003e`_.\n\nFull documentation on `Read the Docs \u003chttp://pygeocodio.readthedocs.org/en/latest/\u003e`_.\n\n**If you are upgrading from a version prior to 0.2.0 please see the changelog\nin HISTORY.rst. The default coordinate ordering has changed to something a bit\nmore sensible for most users.**\n\nGeocodio API Features\n=====================\n\n* Geocode an individual address\n* Batch geocode up to 10,000 addresses at a time\n* Parse an address into its identifiable components\n* Reverse geocode an individual geographic point\n* Batch reverse geocode up to 10,000 points at a time\n* Perform operations using the HIPAA API URL\n\nThe service is limited to U.S. and Canada addresses for the time being.\n\nRead the complete `Geocodio documentation \u003chttp://geocod.io/docs/\u003e`_ for\nservice documentation.\n\nInstallation\n============\n\npygeocodio requires `requests` 1.0.0 or greater and will ensure requests is\ninstalled::\n\n    pip install pygeocodio\n\nBasic usage\n===========\n\nImport the API client and ensure you have a valid API key::\n\n    \u003e\u003e\u003e from geocodio import GeocodioClient\n    \u003e\u003e\u003e client = GeocodioClient(YOUR_API_KEY)\n\nNote that you can pass in a timeout value in seconds (the default is no timeout)::\n\n    \u003e\u003e\u003e client = GeocodioClient(YOUR_API_KEY, timeout=15)\n\nGeocoding\n---------\n\nGeocoding an individual address::\n\n    \u003e\u003e\u003e geocoded_location = client.geocode(\"42370 Bob Hope Drive, Rancho Mirage CA\")\n    \u003e\u003e\u003e geocoded_location.coords\n    (33.738987255507, -116.40833849559)\n\n\nGeocode a set of address components::\n\n    \u003e\u003e\u003e geocoded_location = client.geocode(components_data={\n      \"postal_code\": \"02210\",\n      \"country\": \"US\"\n    })\n    \u003e\u003e\u003e geocoded_location.coords\n    (42.347547, -71.040645)\n\nBatch geocoding\n---------------\n\nYou can also geocode a list of addresses::\n\n    \u003e\u003e\u003e geocoded_addresses = client.geocode([\n            '2 15th St NW, Washington, DC 20024',\n            '3101 Patterson Ave, Richmond, VA, 23221'\n        ])\n\nReturn a list of just the coordinates for the resultant geocoded addresses::\n\n    \u003e\u003e\u003e geocoded_addresses.coords\n    [(38.890083, -76.983822), (37.560446, -77.476008)]\n    \u003e\u003e\u003e geocoded_addresses[0].coords\n    (38.890083, -76.983822)\n\nLookup an address by the queried address::\n\n    \u003e\u003e\u003e geocoded_addresses.get('2 15th St NW, Washington, DC 20024').coords\n    (38.879138, -76.981879))\n\n\nYou can also geocode a list of address component dictionaries::\n\n    \u003e\u003e\u003e geocoded_addresses = client.geocode(components_data=[{\n            'street': '1109 N Highland St',\n            'city': 'Arlington',\n            'state': 'VA'\n        }, {\n            'city': 'Toronto',\n            'country': 'CA'\n        }])\n\n\nAnd geocode a keyed mapping of address components::\n\n    \u003e\u003e\u003e gecoded_addresses = client.geocode(components_data={\n            \"1\": {\n                \"street\": \"1109 N Highland St\",\n                \"city\": \"Arlington\",\n                \"state\": \"VA\"\n            },\n            \"2\": {\n                \"city\": \"Toronto\",\n                \"country\": \"CA\"\n            }})\n\n\nAnd geocode even a keyed mapping of addresses::\n\n    \u003e\u003e\u003e geocoded_addresses = client.geocode({\n            \"1\": \"3101 patterson ave, richmond, va\",\n            \"2\": \"1657 W Broad St, Richmond, VA\"\n        })\n\nReturn a list of just the coordinates for the resultant geocoded addresses::\n\n    \u003e\u003e\u003e geocoded_addresses.coords\n    {'1': (37.560454, -77.47601), '2': (37.555176, -77.458273)}\n\n\nLookup an address by its key::\n\n    \u003e\u003e\u003e geocoded_addresses.get(\"1\").coords\n    (37.560454, -77.47601)\n\n\nAddress parsing\n---------------\n\nAnd if you just want to parse an individual address into its components::\n\n  \u003e\u003e\u003e client.parse('1600 Pennsylvania Ave, Washington DC')\n    {\n        \"address_components\": {\n            \"number\": \"1600\",\n            \"street\": \"Pennsylvania\",\n            \"suffix\": \"Ave\",\n            \"city\": \"Washington\",\n            \"state\": \"DC\"\n        },\n        \"formatted_address\": \"1600 Pennsylvania Ave, Washington DC\"\n    }\n    \nReverse geocoding\n-----------------\n\nReverse geocode a point to find a matching address::\n\n    \u003e\u003e\u003e location = client.reverse((33.738987, -116.4083))\n    \u003e\u003e\u003e location.formatted_address\n    \"42370 Bob Hope Dr, Rancho Mirage CA, 92270\"\n\nBatch reverse geocoding\n-----------------------\n\nAnd multiple points at a time::\n\n    \u003e\u003e\u003e locations = client.reverse([\n            (33.738987, -116.4083),\n            (33.738987, -116.4083),\n            (38.890083, -76.983822)\n        ])\n\nReturn the list of formatted addresses::\n\n    \u003e\u003e\u003e locations.formatted_addresses\n    [\"42370 Bob Hope Dr, Rancho Mirage CA, 92270\",  \"42370 Bob Hope Dr, Rancho Mirage CA, 92270\", \"2 15th St NW, Washington, DC 20024\"]\n\nAccess a specific address by the queried point tuple::\n\n    \u003e\u003e\u003e locations.get(\"38.890083,-76.983822\").formatted_address\n    \"2 15th St NW, Washington, DC 20024\"\n\nOr by the more natural key of the queried point tuple::\n\n    \u003e\u003e\u003e locations.get((38.890083, -76.983822)).formatted_address\n    \"2 15th St NW, Washington, DC 20024\"\n\nCLI usage\n=========\n\nIn the works!\n\nDocumentation\n=============\n\nFor complete documentation see `the docs\n\u003chttp://pygeocodio.readthedocs.org/en/latest/\u003e`_.\n\nLicense\n=======\n\nBSD License\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbennylope%2Fpygeocodio","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbennylope%2Fpygeocodio","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbennylope%2Fpygeocodio/lists"}