title: use Curl to access API with username and password in PHP
body: <p>This is the sample code but using Curl on cmd :</p>
  <pre><code>curl https://www.zopim.com/api/v2/chats -u {username}:{password}
  </code></pre>
  <p>How do I query it in PHP?</p>