PHP code example of sentryworker / client

1. Go to this page and download the library: Download sentryworker/client library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

sentryworker / client example snippets




use SentryWorker\Client;
use SentryWorker\Exception\ClientException;

$client = new Client(array(
    'app_key' => 'APP_KEY',
    'app_secret' => 'APP_SECRET',
    'curl_opts' => array(
        'connection_timeout' => 1,
        'read_timeout' => 1,
    )
));

try {
    $trxId = $client->sendToReview('orderId');
    echo $trxId;
} catch (ClientException $e) {
    echo $e->getCode();
    echo $e->getMessage();
}