当我在 Laravel 6 中通过 SendGrid 发送邮件时,出现了以下错误:
Failed to authenticate on SMTP server with username "apikey" using 2 possible authenticators. Authenticator LOGIN returned Expected response code 250
my .env:
MAIL_DRIVER=smtp
MAIL_HOST=smtp.sendgrid.net
MAIL_PORT=587
MAIL_USERNAME=apikey
MAIL_PASSWORD=***** (my key copied from sendgrid)
MAIL_ENCRYPTION=tls