danludwig
danludwig

Reputation: 47375

Does Yahoo's PlaceFinder API always return 0 or 1 result for a reverse (lat/lng) lookup?

I'm familiar with the geonames API, whose findNearbyPlaceName resource takes an optional radius parameter and can return multiple places for a given lat/lng pair.

When doing a similar lookup in YDN PlaceFinder, using the R gflag to do a reverse lookup from a lat/lng, will there ever be more than 1 result returned? I have not found any instances yet, and from what I can tell, the PlaceFinder API doesn't allow for radius (though you can request offset from street).

Upvotes: 0

Views: 354

Answers (1)

BrianC
BrianC

Reputation: 10721

Yes, the PlaceFinder service will only return a single location. (In the case of an error or location not found, you would get 0 results.) It's designed to go between a place description and location (e.g., street address to lat/long).

I'm not sure what your needs are, but you could also check out the Yahoo GeoPlanet API which provides more hierarchical data around the point of interest. PlaceFinder and GeoPlanet can be used together in this way.

Here are a couple of hack projects that help demonstrate each of these APIs:

Upvotes: 1

Related Questions