title: Rest-client Authorization Header unauthorized but working with curl
body: <p>I have the following API secured through: </p>
  
  <pre><code>  def restrict_access
      authenticate_or_request_with_http_token do |token, options|
        ApiKey.exists?(access_token: token)
      end
    end
  </code></pre>
  
  <p>The following curl works: </p>
  
  <pre><code> curl --data "" http://localhost:3000/api/v1/leadapis -H 'Authorization: Token token="7bbb307792bac1588524003ac641fa55"'
  </code></pre>
  
  <p>Yet in irb></p>
  
  <pre><code>require 'rest-client'
  RestClient.post('http://localhost:3000/api/v1/leadapis', '{}', 'authorization' =&gt; 'Token token = 7bbb307792bac1588524003ac641fa55')
  </code></pre>
  
  <p>Both curl and rest-client yield the same request.authorization in debugger:</p>
  
  <pre><code>(rdb:18) request.authorization
   "Token token = \"7bbb307792bac1588524003ac641fa55\""
  </code></pre>
  
  <p>Any help would be appreciated</p>