Hello Guys, I am implementing twitter API in ASP.Net. I am facing the given issue. I have read al API 1.1 solution but no luck. Please suggest what I need to do.
{“errors”: [{“message”: "The Twitter REST API v1 is no longer active. Please migrate to API v1.1. https://dev.twitter.com/docs/api/1.1/overview.", “code”: 68}]}.
The following code is implemented by us.
Before Authorization
Works and asking to authorize.
AfterAuthorization
Got error in this step.
oAuthTwt.ConsumerKey = ConsumerKey;
oAuthTwt.ConsumerSecret = ConsumerSecret;
OAuthTokenResponse token1 = OAuthUtility.GetRequestToken(ConsumerKey, ConsumerSecret, Session[“TwtCallback”].ToString());
// OAuthTokenResponse token1 = OAuthUtility.GetAccessToken(ConsumerKey, ConsumerSecret,Request.QueryString[“oauth_token”], “”);
userAccessToken = token1.Token;
userAccessSecret = token1.TokenSecret;
userName = token1.ScreenName;
OAuthTokens tokens = new OAuthTokens();
tokens.AccessToken = userAccessToken; //
tokens.AccessTokenSecret = userAccessSecret;// userAccessSecret; //
tokens.ConsumerKey = ConsumerKey;
tokens.ConsumerSecret = ConsumerSecret;
string strTweet = Session["Tweet"].ToString();
//We got error in below line.
TwitterResponse<TwitterStatus> tweetResponse = TwitterStatus.Update(tokens, strTweet);