Any Solutions for the Twitter API1.1 and OAuth for ObjectiveC?

1k Views Asked by At

Have an app that is built in xcode and using Objective C, I'm currently using the MGTwitterEngine + OAuthConsumer framework to send out tweets. Worked great until yesterday when they finally moved to API1.1 and enforced oauth_callback in the OAuth requests.

I can pretty much get around the JSON issue in MGTwitterEngine since it's all source. I reworked it so it sends the JSON request instead of XML for what I need. The problem is that there is no option for oauth_callback in the OAUTHConsumer framework. It didn't exist years ago.

I just get Error Domain=HTTP Code=401 "The operation couldn’t be completed. (HTTP error 401.)

Anyone building OSX apps (or even iOS) seem to have a fix for this?

Thanks for some pointers.. seems everything for Xcode is about 3 years old. There were some quick fixes for the API change a while back and I did migrate to those but still nothing for OAUTH.

4

There are 4 best solutions below

3
sean808080 On

It sounds like OAuthConsumer is out of date. I have used Sharekit for these tasks and find it to be easy to implement and trouble free. http://getsharekit.com

0
the1pawan On

From Twitter v1.1 you need to send authentication parameters for all request.. they are updating there api ..you can use this library Click FHSTwitterEngine its working for me as i faced same problem

0
nst On

Check out the STTwitter Objective-C library.

It works on OS X and iOS.

It supports Twitter API v.1.1 including the new "App Only" mode.

1
Mitul Goti On

This is worked for me : You have to implement your code as it is like in twitter api 1.0. In new api 1.1, you have to add two jar file twitpic4j.jar and most important twitter4j-core-3.0.3.jar. then it's work fine. Enjoy and vote up.

Download jar file from here : http://code.google.com/p/comp3111-project-team201/downloads/detail?name=twitter4j-core-3.0.3.jar&can=2&q=