Why the hell is it so hard to use the BOSS Placefinder API?

Hey guys,

So, we were using the old (now deprecated without warning) PlaceFinder API, which worked great. So now we're trying to figure out how to use OAuth with PlaceFinder. Is anyone else here confused as hell on how to do this? There are no clear examples (this: http://developer.yahoo.com/boss/search/boss_api_guide/codeexamples.html does not work for me), and the step-by-step OAuth instructions (http://developer.yahoo.com/oauth/guide/oauth-auth-flow.html) don't make any sense if all I want to do is a simple geolocation call.

Simply put, there are no clear instructions/examples on how to use the PlaceFinder API call. I've tried using the get_token_request to get a token secret, but that always gives me an 'signature_invalid' error. (I've tried both PLAINTEXT and HMAC-SHA1 signature methods.) I've also tried using an empty string for a token secret, but of course to no avail.

This is really terrible...I can't imagine that anyone at Yahoo actually tried to set up a PlaceFinder API call from scratch. Why the hell do I need to use OAuth to get some simple damn coordinates? Why the hell can't they just make the API call through HTTPS? Why are there no simple instructions? Why is there no simple Yahoo BOSS client library for Python, Ruby, etc.? Why the hell haven't I heard anyone complaining about this? Am I just stupid, or is making this API call needlessly complicated?



4 Replies
  • I agree what a pain it was and had no notice of the change and have customers with problems still with it.

    It took me about 8+ hours to convert it and I can not get it to work on my clients servers now.

    I did it in C#


  • Here is the code I used in C#

                var uri = new Uri(@"http://yboss.yahooapis.com/geo/placefinder?Location=" + txtAdd1.Text + "+" + txtCity.Text.Replace(' ', '+') + "," + txtState.Text + "+" + txtZip.Text);
                var o = new OAuth.OAuthBase();
                string nonce = o.GenerateNonce();
                var timestamp = o.GenerateTimeStamp();
                string normalizedUrl;
                string normalizedParameters;
                string strConsumerkey = 
                strConsumerkey = txtConsumerkey.Text;
                strconsumerseceret = txtConsumerseceret.Text;
                string signature = System.Web.HttpUtility.UrlEncode(
                                        strconsumerseceret, null, null, "GET",
                                        timestamp, nonce, out normalizedUrl,
                                        out normalizedParameters));
                uri = new Uri(normalizedUrl + "?" + normalizedParameters + "&oauth_signature=" + signature);
                using (var httpClient = new System.Net.WebClient())
                    result = httpClient.DownloadString(uri.AbsoluteUri);
                System.Xml.XmlDocument xd = new System.Xml.XmlDocument();
  • Keith,

    The BOSS team does not participate in the YDN forums. I recommend you reach out to them directly in their Yahoo! Group at http://tech.groups.yahoo.com/group/ysearchboss/

  • Thanks Keith. I'm coming back to this now, I'm sure your snippet will come in handy.


Recent Posts

in Suggestions for YDN