0

PlaceFinder API v2 released?

Hi.

Yahoo PlaceFinder API seems to have upgraded from version 1.0 to version 2.0 in the past few days.

See the following URL: http://where.yahooapis.com/geocode?location=San+Francisco,+CA&flags=J&appid=yourappid

This now returns json 
{"@lang":"en-US","ResultSet":{"@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US","Found":"1","Quality":"40","Result":{"quality":"40","latitude":"37.777119","longitude":"-122.41964","offsetlat":"37.777119","offsetlon":"-122.41964","radius":"8800","name":"","line1":"","line2":"San Francisco, CA","line3":"","line4":"United States","house":"","street":"","xstreet":"","unittype":"","unit":"","postal":"","neighborhood":"","city":"San Francisco","county":"San Francisco County","state":"California","country":"United States","countrycode":"US","statecode":"CA","countycode":"","uzip":"94102","hash":"","woeid":"2487956","woetype":"7"}}}

Changes I've noticed are that the 'Error' field is now a String not an Integer, and the 'Results' field has been renamed to 'Result'.

Version 2.0 of the API doesn't seem to be documented anywhere.

Can anyone help? This has broken a test application I've been developing.

Thanks.

by
19 Replies
  • This happened once before (http://developer.yahoo.com/forum/PlaceFinder-General-Discussion/API-Response-change-for-JSON-/1339444613437-f03c7335-5cfa-42d1-94fe-cabab70e9ee6), and they reverted back to version 1.0 within a day without explanation. Hopefully that's the case this time.


    QUOTE(James @ 1 Oct 2012 5:57 AM)
    Hi.

    Yahoo PlaceFinder API seems to have upgraded from version 1.0 to version 2.0 in the past few days.

    See the following URL: http://where.yahooapis.com/geocode?location=San+Francisco,+CA&flags=J&appid=yourappid

    This now returns json 
    {"@lang":"en-US","ResultSet":{"@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US","Found":"1","Quality":"40","Result":{"quality":"40","latitude":"37.777119","longitude":"-122.41964","offsetlat":"37.777119","offsetlon":"-122.41964","radius":"8800","name":"","line1":"","line2":"San Francisco, CA","line3":"","line4":"United States","house":"","street":"","xstreet":"","unittype":"","unit":"","postal":"","neighborhood":"","city":"San Francisco","county":"San Francisco County","state":"California","country":"United States","countrycode":"US","statecode":"CA","countycode":"","uzip":"94102","hash":"","woeid":"2487956","woetype":"7"}}}

    Changes I've noticed are that the 'Error' field is now a String not an Integer, and the 'Results' field has been renamed to 'Result'.

    Version 2.0 of the API doesn't seem to be documented anywhere.

    Can anyone help? This has broken a test application I've been developing.

    Thanks.
    0
  • Where can we find documentation on the change? Is there a way we can specify the earlier API?

    This is causing problems for my site as well. Quote from http://developer.yahoo.com/blogs/ydn/posts/2012/09/introducing-boss-geo-%E2%80%93-the-next-chapter-for-boss/

    "We intend to shut down the current free versions of PlaceFinder and PlaceMaker on November 17, 2012."

    Also, see the pricing on this page.

    http://info.yahoo.com/legal/us/yahoo/boss/pricing/
    0
  • I too discovered this today. My client was expecting a Results node, but was getting a Result node. Does this mean that a single PlaceFinder request will max out at a single result? Or is it still possible for the service to return multiple results, and only the name of the node has changed?
    0
  • I've found it's even worse.  When you have 1 found result, "result" is a single object.  But when you have more than one result, it's an array!

    {"@lang":"en-US","ResultSet":{"@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US",
    "Found":"1",
    "Quality":"87",
    "Result":{"quality":"87",... }}}

    vs.
    {"@lang":"en-US","ResultSet":{
    "@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US",
    "Found":"2",
    "Quality":"87",
    "Result":[{"quality":"87", ...},{"quality":"39", ... }]
    }}

    Sigh.... 
    0
  • I've also found that you can put in a zip of 00000 or xxxxx ( yes x's  for zip) and no error is thrown and Found = 1. That makes no sense. I also noticed the single object vs. array problem.

    Try this: http://where.yahooapis.com/geocode?postal=xxxxx&appid=yourID&flags=J&country=USA

    {"@lang":"en-US","ResultSet":{"@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US","Found":"1","Quality":"9"



    QUOTE(John @ 1 Oct 2012 10:10 AM)
    I've found it's even worse.  When you have 1 found result, "result" is a single object.  But when you have more than one result, it's an array!

    {"@lang":"en-US","ResultSet":{"@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US",
    "Found":"1",
    "Quality":"87",
    "Result":{"quality":"87",... }}}

    vs.
    {"@lang":"en-US","ResultSet":{
    "@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US",
    "Found":"2",
    "Quality":"87",
    "Result":[{"quality":"87", ...},{"quality":"39", ... }]
    }}

    Sigh.... 
    0
  • Im so confused! My script is broken now since it needs to have the house field returned and i cant seam to get it to be returned. Its empty in the resultset.
    if ($data->ResultSet->Error == '0' && $data->ResultSet->Found && $data->ResultSet->Result->house != "")
    So im really confused about their services, are they no longer going to offer the free placefinder? Any insight would be great.
    0
  • Thanks Yahoo.  Totally broke this.  6 weeks ahead of scheduled shut-off.


    QUOTE(James @ 1 Oct 2012 5:57 AM)
    Hi.

    Yahoo PlaceFinder API seems to have upgraded from version 1.0 to version 2.0 in the past few days.

    See the following URL: http://where.yahooapis.com/geocode?location=San+Francisco,+CA&flags=J&appid=yourappid

    This now returns json 
    {"@lang":"en-US","ResultSet":{"@version":"2.0","@lang":"en-US","Error":"0","ErrorMessage":"No error","Locale":"en-US","Found":"1","Quality":"40","Result":{"quality":"40","latitude":"37.777119","longitude":"-122.41964","offsetlat":"37.777119","offsetlon":"-122.41964","radius":"8800","name":"","line1":"","line2":"San Francisco, CA","line3":"","line4":"United States","house":"","street":"","xstreet":"","unittype":"","unit":"","postal":"","neighborhood":"","city":"San Francisco","county":"San Francisco County","state":"California","country":"United States","countrycode":"US","statecode":"CA","countycode":"","uzip":"94102","hash":"","woeid":"2487956","woetype":"7"}}}

    Changes I've noticed are that the 'Error' field is now a String not an Integer, and the 'Results' field has been renamed to 'Result'.

    Version 2.0 of the API doesn't seem to be documented anywhere.

    Can anyone help? This has broken a test application I've been developing.

    Thanks.
    0
  • Even the flags=P doesn't work anymore. Supposed to return Serialized data, but returns XML ???
    0
  • Just noticed, there shutting down PlaceFinder in november.??
    0
  • To answer my own question, yes, it is possible for it to return multiple results.

    @John, yep. When Found=1 it's returning a single json object, but when Found>1 it's returning a json array. This is making it painful for my NGeo wcf client to deserialize. I can't come up with any creative solutions, will have to deal with brute force.

    @Yahoo - the "step by step" tutorial link from your placefinder landing page is leading to a 404. 

    @George - is it really going away? Or will it just become a paid service?

    0
  • It also looks like the gflags=Q (quick mode) is not performing as it was before. I get non-exact matches even when this parameter is included in a request.
    0
  • It also looks like gflags=Q (quick mode) is not working either. I am getting non-exact matches even when this flag is passed in the request.
    0
  • Version 1 is back in action now?

    It's being changed to BOSS or something.

    See:

    http://developer.yahoo.com/geo/placefinder/
    http://www.ysearchblog.com/2012/09/26/boss-geo/
    http://developer.yahoo.com/boss/geo/
    0
  • ARE YOU KIDDING ME YAHOO? I spent the day yesterday rewriting my client against these changes, and now I have to go back? THIS IS ABSOLUTELY RIDICULOUS!!!!!
    0
  • @George, it seems like this is more of a name change / rebranding / move to a paid service than a "shut down", would you agree?
    0
  • The change wasn't intentional, and it should be back to normal now.  I apologize for the inconvenience!

    Please let us know if you see other problems.
    0
  • Thanks for the update! What about the last time this happened (June 11)? Was that a mistake too? I don't think we ever got an explanation for what happened back then.

    QUOTE(duzins @ 3 Oct 2012 12:14 PM)
    The change wasn't intentional, and it should be back to normal now.  I apologize for the inconvenience!

    Please let us know if you see other problems.
    0
  • I'm not sure, I can only report on what I know.  Sorry.
    0
  • No problem, I was just curious. Thanks for all your help!

    QUOTE(duzins @ 4 Oct 2012 7:21 AM)
    I'm not sure, I can only report on what I know.  Sorry.
    0
This forum is locked.

Recent Posts

in PlaceFinder General Discussion