I am trying to send an email confirmation account from a web application made in laravel 5.4, I have tested in my localhost and it is sent correctly, but when deployed in heroku throws me this error:
Swift_TransportException in AbstractSmtpTransport.php line 383:
Expected response code 250 but got code "530", with message "530-5.5.1
Authentication Required.
Learn more at
530 5.5.1 https://support.google.com/mail/answer/14257 w10sm15831823wjk.18 -
gsmtp"
I have already configured the application key from gmail, even the tests from the localhost are positive, but since heroku fails to send the email.
These are my settings in the .env file:
MAIL_DRIVER=smtp
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_USERNAME=micorreo#gmail.com
MAIL_PASSWORD=mvallokmzmszjtwk
MAIL_ENCRYPTION=tls
You have to configure add-on mail in heroku https://devcenter.heroku.com/articles/smtp
Related
I have a free tier account on MailGun and I'm trying to configure the application to send the user a token to reset his password but I keep getting the following error in my browser console.
"Expected response code "220" but got code "421", with message "421 Server busy, too many connections".
This is how my .env file is configured
MAIL_MAILER=smtp
MAIL_HOST=smtp.mailgun.org
MAIL_PORT=587
MAIL_USERNAME=postmaster#sandbox6xxxxxxxxxxxxxxx.mailgun.org
MAIL_PASSWORD=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
MAIL_ENCRYPTION=tls
Why are you using the smtp config? Laravel comes with a Mailgun driver built in. You should be setting your MAILER to mailgun and then configuring your mailgun domain, key, and email address.
See here: https://laravel.com/docs/9.x/mail#mailgun-driver
working with laravel 5.6 and I am going to send contact form details via the gmail. My .env file is look like this,
MAIL_DRIVER=smtp
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_USERNAME=myname#gmail.com
MAIL_PASSWORD=password
MAIL_ENCRYPTION=null
but when I send submit buttons following error is coming,
1/1) Swift_TransportException
Expected response code 250 but got code "530", with message "530 5.7.0 Must issue a STARTTLS command first. u21-v6sm32263983pfa.176 - gsmtp
"
in AbstractSmtpTransport.php line 383
how can fix this project?
I guess I have faced this issue when I had wrong password in .env for given email id
I'm trying to send email using Laravel 5.6 but I got this error
Swift_TransportException Expected response code 250 but got code , with message PLAIN250 Reset OK
This is my configuration:
MAIL_DRIVER=smtp
MAIL_HOST=4403.smtp.antispamcloud.com
MAIL_PORT=587
MAIL_USERNAME=username#domain.tld
MAIL_PASSWORD=password
MAIL_ENCRYPTION=tls
Any ideas? Thx
Check your gmail account: in settings, enable access for less secure apps and it will work.
I used the artisan command "php artisan make:auth" And Users authentication and registration is working fine but for some reason the App just can't send the reset passwords email.
I was able to properly configure the env file and even receive the message; "We have e-mailed your password reset link!", but the email never reaches the recipient.
This is my env file:
MAIL_DRIVER=log
MAIL_HOST=smtp.liberumratings.com
MAIL_PORT=587
MAIL_USERNAME=website#liberumratings.com
MAIL_PASSWORD=******
MAIL_ENCRYPTION=tls
I also tried the example below but a got this error:
(1/1) ErrorException
stream_socket_enable_crypto(): Peer certificate CN=*.locaweb.com.br'
did not match expected CN=smtp.liberumratings.com'
MAIL_DRIVER=smtp
MAIL_HOST=smtp.liberumratings.com
MAIL_PORT=587
MAIL_USERNAME=website#liberumratings.com
MAIL_PASSWORD=******
MAIL_ENCRYPTION=tls
All my parameters are correct and I am able to send emails using the PHPMailer on the same server on another application.
The encryption might be wrong. Are you using SSL?
Remove the tls and try agian. Also your answer can be found here
Laravel SMTP driver with TLS encryption
When I try to send an e-mail through my website running Laravel 5, I get this exception:
Expected response code 250 but got code "535", with message "535-5.7.8 Username and Password not accepted. Learn more at
535 5.7.8 https://support.google.com/mail/answer/14257 l140sm14142372oig.11 - gsmtp
Here is my env configuration
MAIL_DRIVER=smtp
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_USERNAME=example#gmail.com
MAIL_PASSWORD=example
MAIL_ENCRYPTION=tls
Code works on local and other website but not work on my new website on new hosting. I allow access from less-secure apps. What can be problem?
It's possible that G-Mail doesn't like the 3rd party application that's connecting to it.
If you are sure the credentials are correct, then visit this link to check if you need to approve the application