title: Twitter API 1.1 Could not authenticate you 2
body: <p>I'm trying to get result from this query.</p>
  
  <pre><code>https://api.twitter.com/1.1/search/tweets.json?q=?&amp;geocode=39.893280,32.779655,5km&amp;count=100
  </code></pre>
  
  <p>I'm getting <code>code:32 Could not authenticate you</code> error. I'm using parse cloud code.</p>
  
  <pre><code>Parse.Cloud.httpRequest({
      method: 'GET',
      url: urlLink,
      headers: {
          "Content-Type": "application/x-www-form-urlencoded",
          "Authorization" : 'OAuth oauth_consumer_key="hKHVs8mDhW1rvZaPSLV9NywDS", oauth_nonce="5930fc59da48a2b30a5ff90939184b82", oauth_signature=somethingcorrect, oauth_signature_method="HMAC-SHA1", oauth_timestamp="1427745599", oauth_token="2900478017-RUQFnvSL7Vh1WohOBLbkswx55vtcgbnaexNt6ed", oauth_version="1.0"'
      },
      body: {
      },
      success: function(httpResponse) {
          // console.log(httpResponse.text);
          response.success(httpResponse.text);
      },
      error: function(httpResponse) {
          response.error('Request failed with response ' + httpResponse.status + ' , ' + JSON.stringify(httpResponse));
      }
  });
  </code></pre>
  
  <p>I generated everything from <a href="https://dev.twitter.com/oauth/tools/signature-generator/8123321" rel="nofollow">here</a>. So the keys and the signature is correct. Probably the urlLink I'm giving is in wrong format but I checked it a few times. What is wrong here?</p>
  
  <p>Here is the curl code which works correct. Newlines are just for better readability.</p>
  
  <pre><code>curl --get 'https://api.twitter.com/1.1/search/tweets.json' 
  --data 'count=100&amp;geocode=39.893280%2C32.779655%2C5km&amp;q=%3F' 
  --header 'Authorization: OAuth oauth_consumer_key="hKHVs8mDhW1rvZaPSLV9NywDS", oauth_nonce="5930fc59da48a2b30a5ff90939184b82", oauth_signature=somethingcorrect, oauth_signature_method="HMAC-SHA1", oauth_timestamp="1427745599", oauth_token="2900478017-RUQFnvSL7Vh1WohOBLbkswx55vtcgbnaexNt6ed", oauth_version="1.0"' --verbose
  </code></pre>