2

I'm trying to use the TwitterAuthProvider, but it seems like the implementation is deprecated since it uses twitter 1.0, I´m getting the following exception:

The remote server returned an error: (410) Gone.

It happens after the user auth when it´s time to load the userInfo and try to parse the response into json:

protected override void LoadUserAuthInfo(AuthUserSession userSession, IAuthTokens tokens, Dictionary<string, string> authInfo)
{
    ...
    var json = AuthHttpGateway.DownloadTwitterUserInfo(tokens.UserId);
    var objs = JsonObject.ParseArray(json);
    ...
}

Download Twitter User Info:

public const string TwitterUserUrl = "http://api.twitter.com/1/users/lookup.json?user_id={0}";
public string DownloadTwitterUserInfo(string twitterUserId)
{
    twitterUserId.ThrowIfNullOrEmpty("twitterUserId");
    var url = TwitterUserUrl.Fmt(twitterUserId);
    var json = url.GetStringFromUrl();
    return json;
}
Scott
  • 21,211
  • 8
  • 65
  • 72
pedrommuller
  • 15,741
  • 10
  • 76
  • 126
  • http://api.twitter.com/1/users/lookup.json? Is not used any more you need to use open auth to connect to twitter api now. – Dynamikus Oct 21 '13 at 13:33
  • yeah I understand, the problem is that I haven´t seen an update for the twitter auth for SS and a twitter api call using get instead of post – pedrommuller Oct 22 '13 at 17:03

0 Answers0