Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

beyondopen/geocode-cache-service

Repository files navigation

cache-geocode-service

Flask app to geocode locations and cache the results.

Using https://developer.here.com/documentation/geocoding-search-api/dev_guide/index.html.

https://developer.here.com/documentation/geocoding-search-api/api-reference-swagger.html

curl -u username:password https://geocode.app.vis.one/q=Berlin

API

Two endpoints:

GET

GET https://geocode.app.vis.one/?provider=here&city=Haldensleben&county=B%C3%B6rde&state=Sachsen-Anhalt&country=Deutschland
Return 400 if no location was found.
### POST

POST https://geocode.app.vis.one/


with data in body:
```json
{"provider": "here", "locations": [{"query": {"city":"Haldensleben", "county": "Börde", "state": "Sachsen-Anhalt", "country": "Deutschland"}}]}

NB: Returns 200 even if no location wasn't found (for one item). Iterate over the responding array to verify if matching geo coords were found.

Development

Create keys.txt and store a HERE API key in it.

docker-compose up

Deployment

Deploy with Dokku.

sudo dokku run geocode flask resetdb

License

MIT.

About

Flask app to geocode & cache

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

AltStyle によって変換されたページ (->オリジナル) /