eklem / idx-tests

Search-index tests
MIT License
2 stars 0 forks source link

Geo-search test #15

Open eklem opened 2 years ago

eklem commented 2 years ago

Use data from this set to test: https://api.flickr.com/services/rest/?method=flickr.photosets.getPhotos&api_key=[API-key]&format=json&nojsoncallback=1&id=breial&photoset_id=72157600841917142

eklem commented 2 years ago

API for getting list of photos from a set: https://www.flickr.com/services/api/flickr.photosets.getPhotos.html

API for getting actual photos (urls, titles, description etc): https://www.flickr.com/services/api/flickr.photos.getInfo.html URL: https://api.flickr.com/services/rest/?method=flickr.photos.getInfo&api_key=[API-key]&format=json&nojsoncallback=1&photo_id=9249905857

API for getting geo-location: https://www.flickr.com/services/api/flickr.photos.geo.getLocation.html URL: https://api.flickr.com/services/rest/?method=flickr.photos.geo.getLocation&api_key=[API-key]&format=json&nojsoncallback=1&photo_id=1126692701 (need a photo w/ location registered on it)

eklem commented 2 years ago

Don't think you need the geo-location stuff. If geo-located, it will show in the flickr.photos.getInfo method.

eklem commented 1 year ago

Just crawl all photos with "longtitude" and "latitude" present: https://api.flickr.com/services/rest/?method=flickr.photos.getInfo&api_key=[API-key]&format=json&nojsoncallback=1&photo_id=32728799315

Could also crawl "country", "region" and "neighbourhood" and use as filters.

eklem commented 1 year ago

Can get lon&lat from photoset, so skip country, region and neighbourhood. https://api.flickr.com/services/rest/?method=flickr.photosets.getPhotos&api_key=[API-key]&format=json&nojsoncallback=1&id=breial&photoset_id=72157600841917142&extras=geo,license,owner_name,tags,views,url_l

So, this will be easy to set up as a search-engine running in a browse. Only get the content of the URL and index all images that have lat&lon registered.