Quick tip: Twitter OAuth Authority (Nodo vs Mango)

I resolved a small bug in my Twitter OAuth code today that others might find useful.  The bug was found on a phone with Nodo but didn’t exist on Mango phones.  I’ve been using the Mango beta tools for a while now and haven’t really had any problems going back and forth between OS versions so this was a bit surprising to find. 

I am currently using the Hammock framework for making OAuth calls to Twitter and Facebook.  In final testing for this app a tester found that the Twitter login page was erroring out on a Nodo phone.  I confirmed the error page in the Nodo emulator and my Nodo device.  Also confirmed that the login page worked fine on Mango.  Here is an image of the error in the emulator:

image

In debugging I found the initial web request to obtain the OAuth token was failing.  As a result we were passing garbage as the OAuth token to the authorized page which resulted in the error above. 

After searching around some I found this post which says to set the RestClient Authority to

“http://twitter.com/oauth”

which was slightly different than what I had


“http://api.twitter.com/oauth”

After making the change Twitter login worked perfectly on both Nodo and Mango phones. 

Happy Coding

Leave a Reply