Download the PHP package dyanakiev/laravel-sparkpost-driver without Composer
On this page you can find all versions of the php package dyanakiev/laravel-sparkpost-driver. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download dyanakiev/laravel-sparkpost-driver
More information about dyanakiev/laravel-sparkpost-driver
Files in dyanakiev/laravel-sparkpost-driver
Package laravel-sparkpost-driver
Short Description SparkPost driver to use with Laravel 6.x|7.x|8.x
License MIT
Homepage https://github.com/vemcogroup/laravel-sparkpost-driver
Informations about the package laravel-sparkpost-driver
Laravel SparkPost Driver
Description
This package allows you to still use SparkPost as MailDriver in Laravel.
This package is inspired by: https://github.com/clarification/sparkpost-laravel-driver and updated with driver from Laravel 5.8.x
Version
Find the correct version to use in the table below:
Laravel version | Version |
---|---|
6.x | 2.x |
7.x | 3.x |
8.x | 4.x |
9.x | 5.x |
Installation
You can install the package via composer:
The package will automatically register its service provider.
Usage
Sparkpost API options
You can define specific [SparkPost options]
(https://developers.sparkpost.com/api/transmissions/#header-request-body) like open_tracking
, click_tracking
, transactional
EU GDPR
You are able to use the EU endpoint for Europe GDPR compliance by setting the endpoint
option or the default will be used.
SparkPost (default): https://api.sparkpost.com/api/v1
SparkPost EU: https://api.eu.sparkpost.com/api/v1
Guzzle options
You are able to specify Guzzle options in the SparkPost config section guzzle
.
Just add the sparkpost service to your config/services.php
.
API Key
You will also need to add the SparkPost API Key to your environment file
Finally you need to set your mail driver to SparkPost. You can do this by changing the driver in config/mail.php
Or by setting the environment variable MAIL_DRIVER
in your .env
file
Laravel 7
If you are using a clean Laravel 7.x installation its important you add the following sparkpost config in config/mail.php
mailer section.
And replace the MAIL_DRIVER
from .env with MAIL_MAILER
, make sure to keep the sparkpost config on config/services.php
.
Helper functions
Delete supressions
Validate single email address
All versions of laravel-sparkpost-driver with dependencies
guzzlehttp/guzzle Version ^7.2
laravel/framework Version ^8.0|^9.0|^10.0
symfony/mailer Version ^6.0
ext-json Version *