Пример #1
0
 def __init__(self, AccessToken, apiServerAndVersion, timeout=10):
     '''
     :param AccessToken: the current access token
     :param apiServerAndVersion: the api server URL with api version
     :param timeout: (optional) the timeout in seconds for each request made, default 10 
     '''
     self.apiClient = APIClient(AccessToken,
                                apiServerAndVersion,
                                timeout=timeout)
Пример #2
0
 def __init__(self, AccessToken, apiServerAndVersion, userAgent, timeout=10, verbose=False):
     '''
     :param AccessToken: the current access token
     :param apiServerAndVersion: the api server URL with api version
     :param timeout: (optional) the timeout in seconds for each request made, default 10 
     :param verbose: (optional) prints verbose output, default False
     '''
     self.apiClient = APIClient(AccessToken, apiServerAndVersion, userAgent=userAgent, timeout=timeout)
     self.verbose   = verbose
Пример #3
0
    def __init__(self):

        self.qp = {}
        self.rest_method = 'GET'
        self.postData = None
        self.headerParams = None
        self.list_request = False

        # TODO change to unit_tests, but need to add projects/run to account?
        self.myAPI = BaseSpaceAPI(profile="ps_native_hoth")
        self.api = APIClient(self.myAPI.getAccessToken(), self.myAPI.apiServer)