title: Ruby - Send GET request with headers
body: <p>I am trying to use ruby with a website's api. The instructions are to send a GET request with a header. These are the instructions from the website and the example php code they give. I am to calculate a HMAC hash and include it under an <code>apisign</code> header.</p>
  
  <pre><code>$apikey='xxx';
  $apisecret='xxx';
  $nonce=time();
  $uri='https://bittrex.com/api/v1.1/market/getopenorders?apikey='.$apikey.'&amp;nonce='.$nonce;
  $sign=hash_hmac('sha512',$uri,$apisecret);
  $ch = curl_init($uri);
  curl_setopt($ch, CURLOPT_HTTPHEADER, array('apisign:'.$sign));
  $execResult = curl_exec($ch);
  $obj = json_decode($execResult);
  </code></pre>
  
  <p>I am simply using an .rb file with ruby installed on windows from command prompt. I am using net/http in the ruby file. How can I send a GET request with a header and print the response?</p>