\Aculab\WebServicesWrapperMessage

SMS/MMS Message for sending

Summary

Methods
Properties
Constants
__construct()
setRequestDeliveryReport()
setStatusPage()
setStatusMethod()
setStatusAuthenticationName()
setStatusAuthenticationPassword()
setStatusSslCheck()
setAlphanumericId()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

__construct()

__construct(string  $to, string  $from, string|null  $content = null, string  $type = "sms", array|null  $msg_media = null) 

Create a Message for sending.

Parameters

string $to

The number of the phone you'd like to receive the message. This must be the full international number without any leading +.

string $from

The number from which you'd like to send the message. This must be one of your purchased numbers, in full international format without any leading +.

string|null $content

The content of your message encoded using UTF-8.

string $type

The type of your message. The default is "sms".

array|null $msg_media

An array of media files to send in an MMS message, or null to send an SMS message. The default is null.

setRequestDeliveryReport()

setRequestDeliveryReport(boolean  $request_delivery_report) : self

Set whether to request a delivery report.

If true, note that the carrier must support delivery reports otherwise this web service will fail. Default is false.

Parameters

boolean $request_delivery_report

Returns

self

setStatusPage()

setStatusPage(string  $status_page) : self

Set the status page URL.

The URL of a page, if any, hosted on your web server to which message status updates will be sent. Default is "", meaning that no updates will be sent.

Parameters

string $status_page

Returns

self

setStatusMethod()

setStatusMethod(string  $status_method) : self

Set the status page request method.

The method by which the status page URL will be accessed, "POST" or "GET". Default is "POST".

Parameters

string $status_method

Returns

self

setStatusAuthenticationName()

setStatusAuthenticationName(string  $status_authentication_name) : self

Set the status page authenication name.

Perform basic authentication with this username when accessing the status page URL. Default is "", meaning don't perform basic authentication.

Parameters

string $status_authentication_name

Returns

self

setStatusAuthenticationPassword()

setStatusAuthenticationPassword(string  $status_authentication_password) : self

Set the status page authenication password.

Basic authentication password, ignored unless performing basic authentication. Default is "".

Parameters

string $status_authentication_password

Returns

self

setStatusSslCheck()

setStatusSslCheck(boolean  $status_ssl_check) : self

Set whether the Aculab Cloud should check the SSL certificate for the status page.

If using HTTPS, set true if you'd like Aculab Cloud to check your SSL certificate when accessing the status page URL. Default is false.

Parameters

boolean $status_ssl_check

Returns

self

setAlphanumericId()

setAlphanumericId(string  $alphanumeric_id) : self

Set an alphanumeric ID.

Sets a string that will be displayed (if supported) on the recipient's handset instead of the from number.

Parameters

string $alphanumeric_id

Returns

self