class Images extends SlimCD implements Images

Class Images.

Properties

string $transactionUrl Transaction URL. from SlimCD
string $statsURL Stats URL. from SlimCD
bool $debug Whether or not debug mode is on. Default is off. from SlimCD
protected $send Data to send. from SlimCD
protected $receive Data that is received. from SlimCD
protected int $defaultTimeout Curl timeout. from SlimCD
protected bool $verifyPeer Curl Verify Peer. from SlimCD

Methods

object
buildError($url, $errorMessage)

Create an error using the URL and error message.

from SlimCD
mixed|object
httpPost($urlString, $timeout, $nameValueArray)

Use curl to POST the request to SlimCd.

from SlimCD
int
getTimeout($timeout)

Get current timeout value from property.

from SlimCD
string
getVersion()

Get the current version of the client.

from SlimCD
setVerifyPeer($verifyPeer)

You can disable verify peer, but it is not recommended.

from SlimCD
mixed
downloadSignature(DownloadSignatureRequest $request, bool $timeout = false)

Download a signature from the database.

mixed
downloadReceipt(DownloadReceiptRequest $request, bool $timeout = false)

Download a receipt from the database.

mixed
downloadCheck(DownloadCheckRequest $request, bool $timeout = false)

Download a check from the database.

mixed
uploadSignature(UploadSignatureRequest $request, bool $timeout = false)

Upload a signature image to the database.

mixed
uploadReceipt(UploadReceiptRequest $request, bool $timeout = false)

Upload a receipt image to the database.

mixed
uploadCheck(UploadCheckRequest $request, bool $timeout = false)

Upload a check image to the database.

mixed
getReceipt(GetReceiptRequest $request, bool $timeout = false)

Retrieves a plain-text receipt.

mixed
sendReceipt(SendReceiptRequest $request, bool $timeout = false)

Sends a receipt via email or SMS-text.

mixed
getSignatureImage(GetSignatureImageRequest $request, bool $timeout = false)

Retrieves a bitmap version of the vector signature.

Details

in SlimCD at line 73
protected object buildError($url, $errorMessage)

Create an error using the URL and error message.

Parameters

$url
$errorMessage

Return Value

object

in SlimCD at line 100
protected mixed|object httpPost($urlString, $timeout, $nameValueArray)

Use curl to POST the request to SlimCd.

Parameters

$urlString
$timeout
$nameValueArray

Return Value

mixed|object

Exceptions

Exception

in SlimCD at line 181
protected int getTimeout($timeout)

Get current timeout value from property.

Parameters

$timeout

Return Value

int

in SlimCD at line 197
string getVersion()

Get the current version of the client.

Return Value

string

in SlimCD at line 207
setVerifyPeer($verifyPeer)

You can disable verify peer, but it is not recommended.

Parameters

$verifyPeer

at line 25
mixed downloadSignature(DownloadSignatureRequest $request, bool $timeout = false)

Download a signature from the database.

Downloads the vector signature data that was stored for a specific gateid. The data is returned as vector-encoded hex bytes.

Parameters

DownloadSignatureRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 46
mixed downloadReceipt(DownloadReceiptRequest $request, bool $timeout = false)

Download a receipt from the database.

Downloads the receipt data that was stored for a specific gateid. The check data is returned in the same format as was used for upload. Data is base-64 encoded.

Parameters

DownloadReceiptRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 67
mixed downloadCheck(DownloadCheckRequest $request, bool $timeout = false)

Download a check from the database.

Downloads the check data that was stored for a specific gateid. The check data is returned in the same format as was used for upload. Data is base-64 encoded.

Parameters

DownloadCheckRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 88
mixed uploadSignature(UploadSignatureRequest $request, bool $timeout = false)

Upload a signature image to the database.

Stores a series of vectors on the SLIM CD server so they can be retrieved at a later date.Vectors are in hex. They can be in one of the four formats.

Parameters

UploadSignatureRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 108
mixed uploadReceipt(UploadReceiptRequest $request, bool $timeout = false)

Upload a receipt image to the database.

Stores a receipttext or image on the SLIM CD server so that it can be retrieved at a later date. Data is base-64 encoded.

Parameters

UploadReceiptRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 128
mixed uploadCheck(UploadCheckRequest $request, bool $timeout = false)

Upload a check image to the database.

Stores a check image on the SLIM CD server so that it can be sent to the processor for check conversion purposes. Data is base-64 encoded.

Parameters

UploadCheckRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 151
mixed getReceipt(GetReceiptRequest $request, bool $timeout = false)

Retrieves a plain-text receipt.

GetReceipt returns a content-type of text/plain that contains the data for the receipt. If an error occurs, GetReceipt sets the HTTP status code and status text to represent the error. If successful, the status code is set to 200 and the text for the receipt is returned as the body of the response.

Parameters

GetReceiptRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 174
mixed sendReceipt(SendReceiptRequest $request, bool $timeout = false)

Sends a receipt via email or SMS-text.

Email or SMS-Text delivery of receipts is performed with this function. The text for receipts is generated using information on file with SLIM CD , so the receipts match those produced by the SLIM CD website. Receipts for SMS-Text are abbreviated versions that show a simpler version of the data.

Parameters

SendReceiptRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception

at line 198
mixed getSignatureImage(GetSignatureImageRequest $request, bool $timeout = false)

Retrieves a bitmap version of the vector signature.

Upon success, GetSignatureImage returns a status code of 200, a content-type based on the type of image requested, and binary data that represents the image. Supported image types include PNG, JPG, BMP, ICON, TIFF. In the case of an error, the content type is set to text/plain, the body contains text representing the error, the HTTP status code us set to an error code (not 200) and status text to represent the error.

Parameters

GetSignatureImageRequest $request
bool $timeout

Return Value

mixed

Exceptions

Exception