title: HTTP request: 400 error
body: <p>For a project I'm working on in Rails, I'm using AlchemyData news API. I'm currently trying to run an HTTP request in pry, which looks like below (I replaced my own API key with the substitute <code>my_api_key</code>, and for clarity, a <code>&gt;</code> indicates what I've entered and <code>=&gt;</code> what was returned to me):</p>
  
  <pre><code>&gt; uri = URI.parse("https://gateway-a.watsonplatform.net/calls/data/GetNews?apikey=MY_API_KEY&amp;outputMode=json&amp;start=now-24h&amp;end=now&amp;q.enriched.url.title=A[Kim^Kardashian]&amp;q.enriched.url.docSentiment.type=positive")
  =&gt; #&lt;URI::HTTPS https://gateway-a.watsonplatform.net/calls/data/GetNews?apikey=MY_API_KEY&amp;outputMode=json&amp;start=now-24h&amp;end=now&amp;q.enriched.url.title=A[Kim^Kardashian]&amp;q.enriched.url.docSentiment.type=positive&gt;
  
  &gt; http = Net::HTTP.new(uri.host, uri.port)
  =&gt; #&lt;Net::HTTP gateway-a.watsonplatform.net:443 open=false&gt;
  
  &gt; response = http.request(Net::HTTP::Get.new(uri.request_uri))
  =&gt; #&lt;Net::HTTPBadRequest 400 Bad Request readbody=true&gt;
  </code></pre>
  
  <p>I'm not understanding why I keep getting a "400 Bad Request" error. From my understanding, that is (usually) returned when there is an error with the url, but when I run mine it works perfectly. Is there something wrong with my syntax or is there a different error? If so, what is it? How can I fix this?</p>