PHP code example of tustin / laravel-whmcs

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

    

tustin / laravel-whmcs example snippets


DarthSoup\Whmcs\WhmcsServiceProvider::class

'Whmcs' => DarthSoup\Whmcs\Facades\Whmcs::class,

$app->configure('whmcs');
$app->register(DarthSoup\Whmcs\WhmcsServiceProvider::class);

\Whmcs::GetClientsProducts([
    'clientid' => '12345'
])

\Whmcs::GetInvoice([
    'invoiceid' => '1337'
])

$whmcs = app('whmcs');
$whmcs->execute('GetInvoice', [
    'invoiceid' => '1337'
]);
bash
php artisan vendor:publish --provider=DarthSoup\Whmcs\WhmcsServiceProvider
bash
cp vendor/darthsoup/laravel-whmcs/config/whmcs.php config/whmcs.php