Trying to connect to Twitter Streaming API using ROAuth, getting "Error: Forbidden"

72 Views Asked by At

I'm trying to use StreamR to get a stream of tweets originating from a particular location. Before I do that, I'm required to do a handshake using ROAuth. Here is what I do:

reqURL <- "https://api.twitter.com/oauth/request_token"
accessURL <- "http://api.twitter.com/oauth/access_token"
authURL <- "http://api.twitter.com/oauth/authorize"
consumerKey <- "FCVbysnkgqLGAwlkgVTuQA9BJ"
consumerSecret <- "x5wA44qtm5Fj5OD1V1O9qYsWfdgLzQxRfpxqVIpzdEZE7FPJGe"
my_oauth <- OAuthFactory$new(consumerKey=consumerKey,
                             consumerSecret=consumerSecret,
                             requestURL=reqURL,
                             accessURL=accessURL,
                             authURL=authURL)

my_oauth$handshake()

When my_oauth$handshake() executes and I copy the PIN, I get Error: Forbidden. Why?

1

There are 1 best solutions below

0
On BEST ANSWER

I changed the https to httpses and it worked.