At Flickr we've got a really big database that lists a significant
percentage of the places that exist in the world, and a few that don't.
When you geotag a photo we try to identify the "place" (neighborhood,
village, city, county, state, or country) where the photo was taken. And
we assign that photo a "place ID".
A place ID is a globally unique identifier for a place on Earth. A city
has a place ID, so do counties, states, and countries. Even some
neighborhoods and landmarks have them, though Flickr isn't currently
tracking those. And we're starting to expose these place IDs around Flickr.
### Place IDs and flickr.photos.search()
The Flickr API method flickr.photos.search() now accepts place_id as an
argument. Along with all of the other parameters you can
search on you can now scope your search to a given place. Historically
you've been able to pass bounding boxes to the API, but calculating the
right bounding box for a city is tricky, and you can get noise and bad
results around the edge. Now you can pass a single non-ambiguous string
and get photos geotagged in San Francisco, CA, or Ohio, or Beijing.
(kH8dLOubBZRvX_YZ, LtkqzVqbApjAbJxv, and wpK7URqbAJnWB90W respectively)
The documentation has been updated at:
http://www.flickr.com/services/api/flickr.photos.search.html
### Sources of Place IDs
Place IDs are now returned from a number of source:
* flickr.photos.getInfo will return place IDs for geotagged photos
* available as a microformat on the appropriate Places page
* flickr.places.resolvePlaceURL, and flickr.places.resolvePlaceId are
available for round tripping Flickr Places URLs.
http://www.flickr.com/services/api/flickr.photos.getInfo.html
http://www.flickr.com/services/api/flickr.places.resolvePlaceURL.html
http://www.flickr.com/services/api/flickr.places.resolvePlaceId.html
### More Place IDs
Right now you can also place IDs in the places URL, and pass them to the
map like so:
* http://flickr.com/places/wpK7URqbAJnWB90W
* http://flickr.com/map?place_id=kH8dLOubBZRvX_YZ
### Place IDs elsewhere
The especially eagle-eyed among you might recognize Place IDs. Upcoming
has been quietly using them for months to uniquely identify their metros.
See events from San Francisco at:
http://upcoming.yahoo.com/place/kH8dLOubBZRvX_YZ
See photos from San Francisco at: http://flickr.com/places/kH8dLOubBZRvX_YZ
Additionally Yahoo's skunkworks project FireEagle will also support
place IDs.
And yes, there is more work to do, but we're exciting about this as a start.
Thanks,
-kellan