 <p>If you don't want to use <code>RestClient::Resource</code>, you can include basic auth in a request like this:</p> <p><code>RestClient::Request.execute method: :get, url: url, user: 'username', password: 'secret'</code></p> <p>The trick is not to use the <code>RestClient.get</code> (or <code>.post</code>, <code>.put</code> etc.) methods since all options you pass in there are used as headers.</p> <p>I just did a quick writeup on this over here: <a href="https://www.krautcomputing.com/blog/2015/06/21/how-to-use-basic-authentication-with-the-ruby-rest-client-gem/" rel="nofollow">https://www.krautcomputing.com/blog/2015/06/21/how-to-use-basic-authentication-with-the-ruby-rest-client-gem/</a></p>