ROAuth Blank Screen


#1

Hi! I’m a graduate student attempting to mine twitter data for analysis. I’m pretty new to all this, so I’m using R studio to pull the data.

Unfortunately I’m getting stuck in authorization. I’ve created a twitter app as a developer and loaded the TwitteR and ROAuth packages in R. Then I typed the following code:

requestURL <- "https://api.twitter.com/oauth/request_token"
accessURL = "http://api.twitter.com/oauth/access_token"
authURL = "http://api.twitter.com/oauth/authorize"
consumerKey = "my key"
consumerSecret = "my secret"
Cred <- OAuthFactory$new(consumerKey=consumerKey,
consumerSecret=consumerSecret,
requestURL=requestURL,
accessURL=accessURL,
authURL=authURL)
Cred$handshake(cainfo = system.file(“CurlSSL”, “cacert.pem”, package = “RCurl”) )

This then returns:

> Cred$handshake(cainfo = system.file(“CurlSSL”, “cacert.pem”, package = “RCurl”) )
To enable the connection, please direct your web browser to:
http://api.twitter.com/oauth/authorize?oauth_token=k3It2YjbhE9BkdjLl8B1OFgUDLyZFN0s2bXqoeV01zo
When complete, record the PIN given to you and provide it here:

The problem is that when I visit that address I get a blank screen. It has happened multiple times, over days and browsers. I have no idea what I’m doing wrong :confused:


#2

All api.twitter.com URLs should be HTTPS only. In your code try changing http:// to https://