Search code examples
iosxcodetwitter

Twitter for both iOS and web site


I have a twitter app so one can log in to my web site with Twitter accounts. Is it possible to use the same Twitter app for those who try to log in from a native iOS app? What I ask is if was possible to have two callback targets: one for the web site and the other for the iPhone app.


Solution

  • Yes. When you get a request token you can pass a oauth_callback parameter for the location you want the user returned to. Be sure to also pass the oauth_verifier from when the user returns to the callback with the request token during the exchange for an access token. You can read more about it in Twitter authentication section.