Do a GET request
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()
650185
def _request(self, url, params=None, timeout=10):
        """"""
        rsp = self._session.get(url, params=params, timeout=timeout)
        rsp.raise_for_status()
        return rsp.text.strip()
565559
def get(self, path, params=None):
        """"""
        r = requests.get(url=self.url + path, params=params, timeout=self.timeout)
        r.raise_for_status()
        return r.json()
851045
function get(url, opts){
	opts = opts || {};

	return requestp(_.extend(defaults, opts, {
		url: url
	}));
}
197220
def _get(self, url, query=None, **kwargs):
        

        return self._request('get', url, query, **kwargs)
408444
def _get(self, uri, options):
        
        url = "http://%s/%s" % (self.host, uri)
        r = requests.get(url, params=options)
        if r.status_code == 200:
            data = r.json()
            return data['results']
        else:
            # Throws anything not 200 error
            r.raise_for_status()
1211657
def do_GET(self):
        
        # Check that the path is legal
        if not self.is_rpc_path_valid():
            self.report_404()
            return

        response = self.server.generate_html_documentation().encode('utf-8')
        self.send_response(200)
        self.send_header("Content-type", "text/html")
        self.send_header("Content-length", str(len(response)))
        self.end_headers()
        self.wfile.write(response)
331095
def get(path, options = {}, headers = {}, raw = false)
      request(:get, path, options, headers, raw)
    end
1254561
def get(self, endpoint: str, **kwargs) -> dict:
        """"""

        return self._request('GET', endpoint, **kwargs)
595615
def do_GET(self):
        
        if self.path.endswith("http_manifest.json"):
            try:
                manifest = self.generate_http_manifest()
                self.send_response(200)
                self.end_headers()
                self.wfile.write(manifest)
            except dtoolcore.DtoolCoreTypeError:
                self.send_response(400)
                self.end_headers()

        else:
            super(DtoolHTTPRequestHandler, self).do_GET()
443893
def get(url, **kwargs):
    
    headers = kwargs.get('headers', {})
    headers['User-Agent'] = config.USER_AGENT # overwrite
    kwargs['headers'] = headers

    timeout = kwargs.get('timeout', config.TIMEOUT)
    kwargs['timeout'] = timeout

    kwargs['verify'] = False # no SSLError

    logger.debug("Getting: %s", url)
    return requests.get(url, **kwargs)
976092
def get(request_uri, params={})
      sp = signed_params("GET", request_uri, params)
      http_client.get(request_uri, sp)
    end
1372332
def get(path, params = {})
      headers = request_headers(:get, path, params)
      request(:get, path, params, headers)
    end
198699
function get($path, $query = null, $headers = null, $curlOpts = null) {
        $payload = $this -> encodePostBody($query);
        
        if ($payload !== "") {
            if (strpos($path, '?')) {
                $url = $path . "&" . $payload;
            } else {
                $url = $path . "?" . $payload;
            }
        }else{
            $url = $path;
        }
        
        return $this -> request($url, self::HTTP_GET, '', $headers, $curlOpts);
    }
533658
def request(method='GET'):
    

    def decorator(func):
        @functools.wraps(func)
        def action(self, *args, **kwargs):
            f = furl(self.server)
            path, body = func(self, *args, **kwargs)

            # deal with query string
            query = dict()
            if isinstance(path, tuple):
                path, query = path
            f.path.add(path)
            f.query.set(query)

            status_code, result = send_rest(f.url, method=method.upper(),
                                            body=body,
                                            session=self.session,
                                            headers=self.headers)
            if status_code != httplib.OK:
                self.logger.error("{impl} {url} headers: {headers}, code: {code}".format(
                    impl=method, url=f.url, headers=self.headers, code=status_code))
            return status_code, result

        return action

    return decorator
1319846
def _get_request(self, url, headers, params=None):
        
        return self._session.get(url, headers=headers, params=params)
300664
def do_get(path, params={})
      login if need_login?

      # Resource id is a special param as it needs to be added to the path
      path = add_id_and_params_to_path(path, params)

      req, res, resource_type, body = nil

      begin
        retry_request(true) do
          # Return content type so the resulting resource object knows what kind of resource it is.
          resource_type, body = @rest_client[path].get(headers) do |response, request, result, &block|
            req, res = request, response
            update_cookies(response)
            update_last_request(request, response)

            case response.code
            when 200
              # Get the resource_type from the content_type, the resource_type
              # will be used later to add relevant methods to relevant resources
              type = if result.content_type.index('rightscale')
                get_resource_type(result.content_type)
              elsif result.content_type.index('text/plain')
                'text'
              else
                ''
              end

              # work around getting ASCII-8BIT from some resources like audit entry detail
              charset = get_charset(response.headers)
              if charset && response.body.encoding != charset
                response.body.force_encoding(charset)
              end

              # raise an error if the API is misbehaving and returning an empty response when it shouldn't
              if type != 'text' && response.body.empty?
                raise EmptyBodyError.new(request, response)
              end

              [type, response.body]
            when 301, 302
              update_api_url(response)
              response.follow_redirection(request, result, &block)
            when 404
              raise UnknownRouteError.new(request, response)
            else
              raise ApiError.new(request, response)
            end
          end
        end
      rescue => e
        raise wrap(e, :get, path, params, req, res)
      end

      data = if resource_type == 'text'
        { 'text' => body }
      else
        JSON.parse(body, :allow_nan => true)
      end

      [resource_type, path, data]
    end