PHP code example of uldisn / sharkscope

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

    

uldisn / sharkscope example snippets


        $domain = 'http://www.sharkscope.com';
        $userName = '???????????????';
        $password = '??????????';
        $appKey = '??????????????';
        $appName = '???????';

        $client = new SharcScopeClient($domain, $appName, $userName, $password, $appKey);
        $this->client->setLogging('shark-log',$username,'player statistic');
        
        if($client->requestGroupList()) {
            $groupList = $this->client->responseData;
        }else{
            $this->out('Invalid response from requestGroupList');
            print_r($this->client->respError);
            die();
        }
                    
        $playerStatistic = new ResponseHelper($groupList);
        $groupsPlayers = ($playerStatistic->findGroupPlayersAll('PREFIX_', '_SUFIX'));
        
        $from = new \DateTime($pgLimit->start_date);
        $to = new \DateTime($pgLimit->end_date);
        $filter = FilterHelper::createDateFromToValue($from, $to);        
                    
                    
        if(!$client->removePlayerFromGroup($groupName,$network,$player,$filter)){
            $this->out('Invalid response from removePlayerFromGroup');
            if($client->respError) {
                print_r($client->respError);
            }else {
                print_r($client->respHeader);
            }

        }