PHP code example of domatskiy / skyparkcdn

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

    

domatskiy / skyparkcdn example snippets


try{

    $CAuth = $this->cdn->signin($email, $password);
    
    #echo 'token = '.$CAuth->token."\n\n";

    $balance = $this->cdn
        ->client()
        ->getBalance();

    print_r($balance);

    $this->cdn
        ->cache()
        ->purgeAll($this->config['resource']['res_1']);

    
    $this->cdn->signout();
}
catch (\Exception $e)
{
    echo $e->getMessage();
}