title: error Message: Expected response code 220 but got an empty response" with exception "Swift_TransportException",
body: <p><a href="https://i.stack.imgur.com/DL2MU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/DL2MU.png" alt="enter image description here"></a>I am following a tutorial to build an API using passport authentication on <a href="https://medium.com/modulr/create-api-authentication-with-passport-of-laravel-5-6-1dc2d400a7f" rel="nofollow noreferrer">enter link description here</a>
  I have followed the part 1 and walking through the part 2 with <strong>account confirmation and notifications</strong> but eventually got a problem when I am testing on POSTMAN. The issue is, it does add to the database only that there is no mail sent with the error. I don't know of there is any configuration I need to do in .env or mail.php. As I tried to configure the email address, STMP and password. The same error is displayed again and most issues I have seen on here are quite different as most are pertaining to mail.php and .env which I have no idea as there is no such on the tutorial link and I even tried to alter the mail.php and .env, I ran <strong>php artisan cache:clear</strong>  but the same error is displayed. </p>
  
  <pre><code>&lt;?php
  
  namespace App\Notifications;
  
  use Illuminate\Bus\Queueable;
  use Illuminate\Notifications\Notification;
  use Illuminate\Contracts\Queue\ShouldQueue;
  use Illuminate\Notifications\Messages\MailMessage;
  
  class SignupActivate extends Notification
  {
      use Queueable;
  
      /**
       * Create a new notification instance.
       *
       * @return void
       */
      public function __construct()
      {
          //
      }
  
      /**
       * Get the notification's delivery channels.
       *
       * @param  mixed  $notifiable
       * @return array
       */
      public function via($notifiable)
      {
          return ['mail'];
      }
  
      /**
       * Get the mail representation of the notification.
       *
       * @param  mixed  $notifiable
       * @return \Illuminate\Notifications\Messages\MailMessage
       */
      public function toMail($notifiable)
  {
      $url = url('/api/auth/signup/activate/'.$notifiable-&gt;activation_token);
      return (new MailMessage)
          -&gt;subject('Confirm your account')
          -&gt;line('Thanks for signup! Please before you begin, you must confirm your account.')
          -&gt;action('Confirm Account', url($url))
          -&gt;line('Thank you for using our application!');
  }
      /**
       * Get the array representation of the notification.
       *
       * @param  mixed  $notifiable
       * @return array
       */
      public function toArray($notifiable)
      {
          return [
              //
          ];
      }
  }
  </code></pre>
  
  <p>I did also, two ways authentication 
  <strong>Mail.php</strong></p>
  
  <p>
  
  <p>return [</p>
  
  <pre><code>'driver' =&gt; env('MAIL_DRIVER', 'smtp'),
  
  'host' =&gt; env('MAIL_HOST', 'smtp.gmail.com'),
  
  'port' =&gt; env('MAIL_PORT', 587),
  
  'from' =&gt; [
      'address' =&gt; env('MAIL_FROM_ADDRESS', 'username@gmail.com'),
      'name' =&gt; env('MAIL_FROM_NAME', 'Payne Curtis'),
  ],
  
  'encryption' =&gt; env('MAIL_ENCRYPTION', 'tls'),
  
  'username' =&gt; env('MAIL_USERNAME'),
  
  'password' =&gt; env('MAIL_PASSWORD'),
  
  
  'sendmail' =&gt; '/usr/sbin/sendmail -bs',
  
  'markdown' =&gt; [
      'theme' =&gt; 'default',
  
      'paths' =&gt; [
          resource_path('views/vendor/mail'),
      ],
  ],
  
  'log_channel' =&gt; env('MAIL_LOG_CHANNEL'),
  </code></pre>
  
  <p>];</p>
  
  <p><strong>.env</strong></p>
  
  <pre><code>MAIL_DRIVER=smtp
  MAIL_HOST=smtp.gmail.com
  MAIL_PORT=587
  MAIL_USERNAME=username@gmail.com
  MAIL_PASSWORD=XXXXXXXXXXXXXXX
  MAIL_ENCRYPTION=null
  </code></pre>