0

I get a 403 Forbidden response when attempting to send an email using Sparkpost from my Laravel 5.6 application. I added the Sparkpost api key to both the .env file and services.php file. Key is correct.

.env file:

enter code here
MAIL_DRIVER=sparkpost
SPARKPOST_SECRET=XXXXXXXXXXX

services.php file:

'sparkpost' => [
        'secret' => env('xxxxxxxxxx'),
    ],

What did I do wrong ?

Bioukh
  • 1,888
  • 1
  • 16
  • 27
  • Your question is not complete.It may be because of not set port of smtp,host of smtp,password of smtp or even do not disable less-secure or 2step setting of sender account or even using of Mail facade.offer complete code please – akbar Feb 08 '20 at 16:39
  • One likely cause for that 403 error is your API key does not include the permission for "Transmission". You can check that in SparkPost here https://app.sparkpost.com/account/api-keys – Yepher Feb 10 '20 at 14:10

0 Answers0