PHP code example of velostazione / besms

1. Go to this page and download the library: Download velostazione/besms 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/ */

    

velostazione / besms example snippets




use Velostazione\BeSMS\Client;
use Velostazione\BeSMS\Api;

$client = new Client();
$besms = new BeSMS($client, '<USERNAME>', '<PASSWORD>', <API_ID>, <REPORT_TYPE>, <SENDER>);

$response = $besms->send('61491570156', 'hello world'); 
    
print_r($response);

$response = $besms->send('61491570156', 'hello world', <SENDER>); 
    
print_r($response);

$response = $besms->getCredit();

print_r($response);

./vendor/bin/phpunit tests