The Main issue I am facing here is as soon as I hit the sendmail api ( This API send mail using google email api ) it gives me error of Undefined index: access_token
I want to send email using GMAIL Email API in my Laravel Project. For that I had followed this github doc:https://github.com/dacastro4/laravel-gmail. I am successfully able to do setup it with my project. But then struck in above error. Below is my code:
use Dacastro4\LaravelGmail\Services\Message\Mail;
$mail = new Mail;
$mail->to( 'TOMAIL', $name = "Tester" );
$mail->from( 'MYMAIL', $name = "Own Tester" );
$mail->subject( "Hello World" );
$mail->message( "Google It Brother." );
$mail->send();
Expected response is it should send the email to user using gmail api.
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire