PHP 클래스 Mailgun\Mailgun

See the official documentation (link below) for usage instructions.
파일 보기 프로젝트 열기: mailgun/mailgun-php 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$apiKey null | string
$restClient Mailgun\Connection\RestClient

공개 메소드들

메소드 설명
BatchMessage ( string $workingDomain, boolean $autoSend = true ) : BatchMessage
MessageBuilder ( ) : MessageBuilder
OptInHandler ( ) : OptInHandler
__construct ( string | null $apiKey = null, Http\Client\HttpClient $httpClient = null, string $apiEndpoint = 'api.mailgun.net', Mailgun\Deserializer\ResponseDeserializer $deserializer = null, HttpClientConfigurator $clientConfigurator = null, RequestBuilder $requestBuilder = null )
delete ( string $endpointUrl ) : stdClass
domains ( ) : Domain
get ( string $endpointUrl, array $queryString = [] ) : stdClass
post ( string $endpointUrl, array $postData = [], array $files = [] ) : stdClass
put ( string $endpointUrl, array $putData ) : stdClass
sendMessage ( string $workingDomain, array $postData, array $postFiles = [] ) : stdClass This function allows the sending of a fully formed message OR a custom MIME string. If sending MIME, the string must be passed in to the 3rd position of the function call.
setApiVersion ( string $apiVersion ) : Mailgun
setSslEnabled ( boolean $sslEnabled ) : Mailgun
stats ( ) : Api\Stats
verifyWebhookSignature ( array | null $postData = null ) : boolean This function checks the signature in a POST request to see if it is authentic.

메소드 상세

BatchMessage() 공개 메소드

public BatchMessage ( string $workingDomain, boolean $autoSend = true ) : BatchMessage
$workingDomain string
$autoSend boolean
리턴 Mailgun\Messages\BatchMessage

MessageBuilder() 공개 메소드

public MessageBuilder ( ) : MessageBuilder
리턴 Mailgun\Messages\MessageBuilder

OptInHandler() 공개 메소드

public OptInHandler ( ) : OptInHandler
리턴 Mailgun\Lists\OptInHandler

__construct() 공개 메소드

public __construct ( string | null $apiKey = null, Http\Client\HttpClient $httpClient = null, string $apiEndpoint = 'api.mailgun.net', Mailgun\Deserializer\ResponseDeserializer $deserializer = null, HttpClientConfigurator $clientConfigurator = null, RequestBuilder $requestBuilder = null )
$apiKey string | null
$httpClient Http\Client\HttpClient
$apiEndpoint string
$deserializer Mailgun\Deserializer\ResponseDeserializer
$clientConfigurator HttpClientConfigurator
$requestBuilder RequestBuilder

delete() 공개 메소드

public delete ( string $endpointUrl ) : stdClass
$endpointUrl string
리턴 stdClass

domains() 공개 메소드

public domains ( ) : Domain
리턴 Mailgun\Api\Domain

get() 공개 메소드

public get ( string $endpointUrl, array $queryString = [] ) : stdClass
$endpointUrl string
$queryString array
리턴 stdClass

post() 공개 메소드

public post ( string $endpointUrl, array $postData = [], array $files = [] ) : stdClass
$endpointUrl string
$postData array
$files array
리턴 stdClass

put() 공개 메소드

public put ( string $endpointUrl, array $putData ) : stdClass
$endpointUrl string
$putData array
리턴 stdClass

sendMessage() 공개 메소드

This function allows the sending of a fully formed message OR a custom MIME string. If sending MIME, the string must be passed in to the 3rd position of the function call.
public sendMessage ( string $workingDomain, array $postData, array $postFiles = [] ) : stdClass
$workingDomain string
$postData array
$postFiles array
리턴 stdClass

setApiVersion() 공개 메소드

public setApiVersion ( string $apiVersion ) : Mailgun
$apiVersion string
리턴 Mailgun

setSslEnabled() 공개 메소드

사용 중단: This will be removed in 3.0. Mailgun does not support non-secure connections to their API.
public setSslEnabled ( boolean $sslEnabled ) : Mailgun
$sslEnabled boolean
리턴 Mailgun

stats() 공개 메소드

public stats ( ) : Api\Stats
리턴 Api\Stats

verifyWebhookSignature() 공개 메소드

Pass an array of parameters. If you pass nothing, $_POST will be used instead. If this function returns FALSE, you must not process the request. You should reject the request with status code 403 Forbidden.
public verifyWebhookSignature ( array | null $postData = null ) : boolean
$postData array | null
리턴 boolean

프로퍼티 상세

$apiKey 보호되어 있는 프로퍼티

protected null|string $apiKey
리턴 null | string

$restClient 보호되어 있는 프로퍼티

protected RestClient,Mailgun\Connection $restClient
리턴 Mailgun\Connection\RestClient