SparkPostTransport
class SparkPostTransport extends Transport
Properties
array | $plugins | The plug-ins registered with the transport. |
from Transport |
protected ClientInterface | $client | Guzzle client instance. |
|
protected string | $key | The SparkPost API key. |
|
protected array | $options | Transmission options. |
Methods
Register a plug-in with the transport.
Iterate through registered plugins and execute plugins' methods.
Iterate through registered plugins and execute plugins' methods.
Create a new SparkPost transport instance.
{@inheritdoc}
Get all the addresses this message should be sent to.
Get the transmission ID from the response.
Get the API key being used by the transport.
Set the API key being used by the transport.
Get the transmission options being used by the transport.
Set the transmission options being used by the transport.
Details
in
Transport at line 22
isStarted()
{@inheritdoc}
in
Transport at line 30
start()
{@inheritdoc}
in
Transport at line 38
stop()
{@inheritdoc}
in
Transport at line 49
void
registerPlugin(Swift_Events_EventListener $plugin)
Register a plug-in with the transport.
in
Transport at line 60
protected void
beforeSendPerformed(Swift_Mime_Message $message)
Iterate through registered plugins and execute plugins' methods.
in
Transport at line 77
protected void
sendPerformed(Swift_Mime_Message $message)
Iterate through registered plugins and execute plugins' methods.
in
Transport at line 94
protected int
numberOfRecipients(Swift_Mime_Message $message)
Get the number of recipients.
at line 39
void
__construct(ClientInterface $client, string $key, array $options = [])
Create a new SparkPost transport instance.
at line 49
send(Swift_Mime_Message $message, $failedRecipients = null)
{@inheritdoc}
at line 86
protected array
getRecipients(Swift_Mime_Message $message)
Get all the addresses this message should be sent to.
Note that SparkPost still respects CC, BCC headers in raw message itself.
at line 111
protected string
getTransmissionId(Response $response)
Get the transmission ID from the response.
at line 123
string
getKey()
Get the API key being used by the transport.
at line 134
string
setKey(string $key)
Set the API key being used by the transport.
at line 144
string
getOptions()
Get the transmission options being used by the transport.
at line 155
array
setOptions(array $options)
Set the transmission options being used by the transport.