开发者

Twitter @Anywhere Sign in Not Sure How to use Bridge_Code

开发者 https://www.devze.com 2023-04-13 00:44 出处:网络
I have setup an Application that uses @Anywhere from twitter to Authenticate the users. I moved this away from the older way I was doing it of Sending the user to a new tab, logging in to twitter, cli

I have setup an Application that uses @Anywhere from twitter to Authenticate the users. I moved this away from the older way I was doing it of Sending the user to a new tab, logging in to twitter, clicking authorize, and entering the PIN and username into my system because it was too many steps and users were getting confused.

The Problem I have now is I need to store the oauth_token and oauth_token_secret in the database so that I can get their information and associate it with my own userids allowing the user to reply to tweets inside the application.

However I dont get these fields when I make the call back I get an "ouath_access_token" which doesnt look very similar to the ones I was getting before using @Anywhere and also a "oauth_bridge_code"

I have seen some very vague docs on how to use this to get the real data I would like.

I tried doing something like this from a slide I had seen

    $.ajax({
            url:'http://api.twitter.com/oauth/access_token',
            type:'POST',
            data:bridge_code,
            success: function(data, jqXHR){
                         //investigate data returned
                         console.log(data,jqXHR);
                      }
           });

====================EDIT===================

Now I am getting a specific error when sending the above request

  XMLHttpRequest cannot load https://api.twitter.com/oauth/access_token. Origin http://127.0.0.1 is not allowed by Access-Control-Allow-Origin.

  POST https://api.twitter.com/oauth/access_token undefined (undefined)开发者_JAVA技巧


I believe this feature is Deprecated

https://groups.google.com/forum/#!msg/twitter-development-talk/UPzE8ozWtlk/mkot6N2xBRQJ

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号