title: Setting up rtweet for R in AWS Ubuntu server
body: <p>for my local computer, I have managed to go through the authentication process for a Twitter app as described on <a href="http://rtweet.info/" rel="nofollow noreferrer">http://rtweet.info/</a> (Section "API authorization".): </p>
  
  <ul>
  <li>The first time you make an API request—e.g., search_tweets(),
  stream_tweets(), get_followers()—a browser window will open. </li>
  <li>Log in to your Twitter account. </li>
  <li>Agree/authorize the rtweet application.</li>
  </ul>
  
  <p>I do struggle, however, with the process for my Ubuntu server on AWS. As I do not have a graphical interface (ssh access only), I can only try to go through the process as follows: </p>
  
  <ol>
  <li>Being on my computer, pointing the browser to the AWS server's address in order to run the "RStudio server software" that is installed on the AWS server. Doing that, the last step - the redirect - results in a browser message stating "Unable to connect Firefox can’t establish a connection to the server at localhost:1410."; the R console keeps hanging an waiting for input: </li>
  </ol>
  
  <p><a href="https://i.stack.imgur.com/6q9UC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6q9UC.png" alt="enter image description here"></a></p>
  
  <ol start="2">
  <li>Being on the Ubuntu server's shell I tried and failed to going through the process producing the following error message: "> rt &lt;- search_tweets( "Mark Fletcher", n = 5000, include_rts = FALSE)
  Error in httpuv::startServer(use$host, use$port, list(call = listen)) :
  Failed to create server"</li>
  </ol>
  
  <p>Would there be another way of doing that without having to rely on a browser running locally on the computer for which we want to do the authorization? </p>
  
  <p>Thanks,</p>
  
  <p>Oli</p>