title: how to authenticate http request in axios
body: <p>I am using Axios on a node mjs script.
  I am hitting a server that uses basic http authentication. on browser, if I hit</p>
  <pre><code>http://user:pass@192.168.254.4/api/endpoint1
  </code></pre>
  <p>it works and gives me the requested data
  but when I use the same URL on Axios.get method it fails.</p>
  <pre><code>Unauthorized
  
  This server could not verify that you are authorized to access the document requested. Either you supplied the wrong credentials (e.g., bad password), or your browser doesn't understand how to give the credentials required.
  </code></pre>
  <p>same thing on postman too (doesn't work on postman either).</p>
  <p>am I missing something here?</p>