public function delete($params, $optParams = [])
    {
        if ($params instanceof SuperBackup) {
            $params = $params->id;
        }
        if(!isset($optParams['cloud'])){
            $optParams['cloud'] = [];
        }
        $optParams['cloud']['id'] = $params;
        return $this->sendRequest([], [
            'restAction' => 'delete',
            'uri' => '/c/<cloud.id>',
            'restId' => $params,
            'getParams' => $optParams,
        ], function ($response) {
            return $response->success;
        });
    }
public function delete($params, $optParams = [])
    {
        if ($params instanceof SuperBackup) {
            $params = $params->id;
        }
        if(!isset($optParams['cloud'])){
            $optParams['cloud'] = [];
        }
        $optParams['cloud']['id'] = $params;
        return $this->sendRequest([], [
            'restAction' => 'delete',
            'uri' => '/c/<cloud.id>',
            'restId' => $params,
            'getParams' => $optParams,
        ], function ($response) {
            return $response->success;
        });
    }
public function delete ( $ params , $ optParams = [ ] ) { if ( $ params instanceof SuperBackup ) { $ params = $ params -> id ; } if ( ! isset ( $ optParams [ 'cloud' ] ) ) { $ optParams [ 'cloud' ] = [ ] ; } $ optParams [ 'cloud' ] [ 'id' ] = $ params ; return $ this -> sendRequest ( [ ] , [ 'restAction' => 'delete' , 'uri' => '/c/<cloud.id>' , 'restId' => $ params , 'getParams' => $ optParams , ] , function ( $ response ) { return $ response -> success ; } ) ; }
Deletes a superbackup.

@param SuperBackup|string $params    SuperBackup object or SuperBackup ID
@param array              $optParams Optional API parameters

@return bool
Deletes a superbackup .