0

我是 oAuth2 的新手,并试图调整这个ActionScript3 oAuth2 库示例来授权 Twitter 应用程序而不是 Google。

// From the example:
var oauth2:OAuth2 = new OAuth2("https://accounts.google.com/o/oauth2/auth", "https://accounts.google.com/o/oauth2/token", LogSetupLevel.ALL);

var grant:IGrantType = new AuthorizationCodeGrant(stageWebView, "INSERT_CLIENT_ID_HERE", "INSERT_CLIENT_SECRET_HERE", "http://www.example.com", "https://www.googleapis.com/auth/userinfo.profile");

我的尝试:

var oauth2:OAuth2 = new OAuth2("https://api.twitter.com/oauth/authorize", "https://api.twitter.com/oauth/request_token", LogSetupLevel.ALL);

var grant:IGrantType = new ImplicitGrant(stageWebView, "Consumer-Key", "Consumer-Secret", "http://www.example.com", "https://api.twitter.com/oauth/access_token");

我遇到了这个错误:

“此页面没有请求令牌。这是我们要求使用您的 Twitter 帐户的应用程序所需的特殊密钥”

为什么没有找到请求令牌?

4

1 回答 1

2

据我所知,twitter 使用的是 OAuth1.0A 而不是 OAuth2.0

于 2013-05-26T06:30:59.157 回答