"Request a token or token not specified in the server response." when trying to get a request token

I am using the Twitter API with Signpost and Twitter4J on Android.

My code does not work here:

consumer = new CommonsHttpOAuthConsumer(TWITTER_KEY, TWITTER_SECRET); provider = new DefaultOAuthProvider("https://api.twitter.com/oauth/request_token", "https://api.twitter.com/oauth/access_token", "https://api.twitter.com/oauth/authorize"); // Here: String authUrl = provider.retrieveRequestToken(consumer, CALLBACK); 

After a long wait for the API, I get an exception:

Request a token token or token not specified in the server response. The service provider you are using is probably defective.

I doubt this is a problem with Twitter, so why is this happening and how can I fix it?

+4
source share

All Articles