Get the requested resource using the Seattle account
    :returns: http response with content in json
493628
def post_sea_resource(url, body):
    
    response = None
    response = TrumbaSea_DAO().postURL(
        url,
        {"Content-Type": "application/json"},
        body)
    _log_json_resp("Seattle", url, body, response)
    return response
1175926
def _get(url:str, headers:dict) -> dict:
    
    response = requests.get(url, headers=headers)

    data = response.json()
    if response.status_code != 200:
        raise GoogleApiError({"status_code": response.status_code,
                                  "error": data.get("error", "")})
    return data
547802
def get_json(uri):
    
    response = requests.get(API + uri, headers=HEADERS)

    limit = int(response.headers.get("x-ratelimit-remaining"))
    if limit == 0:
        sys.stdout.write("\n")
        message = "You have run out of GitHub request tokens. "

        if int(response.headers.get("x-ratelimit-limit")) == 60:
            message += "Set a GITHUB_TOKEN to increase your limit to 5000/hour. "

        wait_seconds = int(response.headers.get("x-ratelimit-reset")) - int(time.time())
        wait_minutes = math.ceil(wait_seconds / 60)
        message += "Try again in ~%d minutes. " % wait_minutes

        if "--wait-for-reset" in sys.argv:
            progress_message(message.replace("Try ", "Trying "))
            time.sleep(wait_seconds + 1)
            progress_message("Resuming")
            return get_json(uri)
        else:
            raise ValueError(message)

    progress()
    return response.json()
752605
def _request(self, method, resource_uri, **kwargs):
        
        data = kwargs.get('data')
        response = method(self.API_BASE_URL + resource_uri,
                          json=data, headers=self.headers)
        response.raise_for_status()
        return response.json()
1055420
def request(self, method, resource, params=None):
        

        url = self.get_url(resource, params)

        # headers

        headers = {
            'Content-Type': 'application/json'
        }

        auth = requests.auth.HTTPBasicAuth(self.username, self.password)

        # request

        log.info('Request to %s. Data: %s' % (url, params))

        response = requests.request(method, url, data=json.dumps(params), headers=headers, auth=auth)
        response.raise_for_status()

        # response

        log.info('Response from %s: %s' % (url, response.text))
        content = response.json()

        self.parse_status(content.get('status'))

        return content
310086
def get_page(url):
    
    response = requests.get(url)
    handle_error(response, 200)
    data = response.json()
    return data
951460
def _get(self, q, params=''):
        ''''''
        if (q[-1] == '/'): q = q[:-1]
        headers = {'Content-Type': 'application/json'}
        r = requests.get('{url}{q}?api_key={key}{params}'.format(url=self.url, q=q, key=self.api_key, params=params),
                        headers=headers)
        ret = DotDict(r.json())
        if (not r.ok or ('error' in ret and ret.error == True)):
            raise Exception(r.url, r.reason, r.status_code, r.json())
        return DotDict(r.json())
1258682
def get_resource(id_or_uri, opts = {})
      data, _status_code, _headers = get_resource_with_http_info(id_or_uri, opts)
      return data
    end
856105
def retrieve(payment_id):
        
        http_client = HttpClient()
        response, __ = http_client.get(routes.url(routes.PAYMENT_RESOURCE, resource_id=payment_id))
        return resources.Payment(**response)
838779
def client_get(self, url, **kwargs):
        """"""
        response = requests.get(self.make_url(url), headers=self.headers)
        if not response.ok:
            raise Exception(
                '{status}: {reason}.\nCircleCI Status NOT OK'.format(
                    status=response.status_code, reason=response.reason))
        return response.json()
1280073
def get(path)
      uri = URI.join(API_DOMAIN, path + "?access_token=#{token}")
      JSON.parse(Net::HTTP.get(uri))
    end
182935
def get_netid_subscriptions(netid, subscription_codes):
    
    url = _netid_subscription_url(netid, subscription_codes)
    response = get_resource(url)
    return _json_to_subscriptions(response)
340715
def get(self, url):
        
        r = requests.get(self._format_url(url), headers=self.headers, timeout=TIMEOUT)
        self._check_response(r, 200)

        return r.json()
711887
def get(self, dash_id):
        
        data = json.loads(r_db.hmget(config.DASH_CONTENT_KEY, dash_id)[0])
        return build_response(dict(data=data, code=200))
201785
def __get_resource(dao, url):
    
    headers = {"Accept": "application/vnd.collection+json"}
    response = dao.getURL(url, headers)
    status = response.status
    logger.debug("{} ==status==> {}".format(url, status))

    if status != 200:
        message = str(response.data)

        if status == 404:
            # the URL not exists on the specific domain
            return None

        if status == 400:
            if "Term is out of range" in message:
                raise TermEvalNotCreated(url, status, message)

        raise DataFailureException(url, status, message)

    return json.loads(response.data)
826071
def make_request(self, resource, params=None):
        
        if params is None:
            params = {}

        url = self.request_url(resource)
        params['format'] = 'json'

        r = self.session.get(url=url, params=params)

        r.raise_for_status()

        return r
377407
def get_resource(self, path, params=None):
        
        url = '%s%s' % (path, self._param_list(params))
        headers = {
            'Accept': 'application/json;odata=minimalmetadata'
        }

        response = O365_DAO().getURL(self._url(url), headers)

        if response.status != 200:
            raise DataFailureException(url, response.status, response.data)

        return json_loads(response.data)