title: HTTP 401 Unable to create record Twillio PHP sdk 5.16
body: <p>I am using a Twilio account for sending SMS to users. I have installed the SDK by executing the following command.</p>
  <pre><code>composer require twilio/sdk
  </code></pre>
  <p>I'm using the following code snippet to send a message.</p>
  <pre><code>public function sendSms($data)
  {
      // Your Account SID and Auth Token from twilio.com/console
      $account_sid = 'sid';
      $auth_token = 'token';
      $twilio_number = &quot;number&quot;;
      $client = new Client($account_sid, $auth_token);
      return $client-&gt;messages-&gt;create(
          $data['phone'], array(
              'from' =&gt; $twilio_number,
              'body' =&gt; $data['message'],
          )
      );
  }
  </code></pre>
  <p>According to Twilio documentation, this code should send the message with my valid credentials, but I am getting the following error.</p>
  <blockquote>
  <p>[HTTP 401] Unable to create record:
  Authenticate85/var/www/art/api/vendor/twilio/sdk/Twilio/Version.php</p>
  </blockquote>
  <p>I have researched this issue, but I got no guidance; any clues? <strong>Note:</strong> I have a balance in my Twilio account.</p>