Skip to main content
Tutorial Free

Quickly test email sending with... artisan tinker!

October 20, 2016
1 min read
Artisan tinker is a wonderful command-line helper to run any simple code. I was often using it to test simple things like if there is any data in Eloquent model or something like that. But today I realised it's much more powerful. So when faced the task of testing if Mailgun is working for one of the clients - here's how it looked.
  • SSH into the server
  • Run php artisan tinker
  • Run Laravel code - Mail::send() with any simple view
This is how it looked in "real life". artisan tinker So the attempt failed - apparently I had unactivated account. After doing the activation, I ran the command again, and there we go. artisan tinker email And received an email to the inbox with a beautiful "Be right back" 503 template. artisan tinker email That's it, a quick tip - hopefully helpful!

Enjoyed This Tutorial?

Get access to all premium tutorials, video and text courses, and exclusive Laravel resources. Join our community of 10,000+ developers.

Recent Courses on Laravel Daily

Laravel 13 Starter Kit Teams and Customizations

10 lessons
33 min

Roles and Permissions in Laravel 13

14 lessons
57 min

Queues in Laravel 13

18 lessons
1 h 12 min read

No comments yet…