Perform an HTTP POST request for a given url.
        Returns the response object.
500303
def post(self, url, data, headers=None):
        
        return self._request('POST', url, data, headers=headers)
1291881
def make_request(self, session, url, **kwargs):
        
        log.debug('Making request: POST %s %s' % (url, kwargs))
        return session.post(url, **kwargs)
603046
def __getDataFromURL(url):
        
        code = 0

        while code != 200:
            req = Request(url)
            try:
                response = urlopen(req)
                code = response.code
                sleep(0.01)
            except HTTPError as error:
                code = error.code
                if code == 404:
                    break
            except URLError as error:
                sleep(3)

        if code == 404:
            raise Exception("User was not found")
        return response.read().decode('utf-8')
878741
def post(self, url, data):
        
        try:
            res = requests.post(
                url, headers=self.headers, data=json.dumps(data))
            return json.loads(res.text)
        except Exception as e:
            print(e)
            return "error"
308098
def _post(self, url, data={}):
        """"""
        r = requests.post(self._api_prefix + url,
            data=json.dumps(data),
            headers=self.headers,
            auth=self.auth,
            allow_redirects=False,
        )
        return self._action(r)
821216
def post_request(url,args)
      uri = URI.parse(url)
      req = Net::HTTP::Post.new(uri.path)
      req.set_form_data(args)
      request(uri,req)
    end
440675
def post(self, url, post_params=None):
        
        post_params['token'] = self.token
        params = urlencode(post_params)
        logger.debug('Making POST request to %s with body %s', url, params)
        return requests.post(url, data=params)
1101370
def rest_post(self, url, params=None, headers=None, auth=None, verify=True, cert=None):
        
        res = requests.post(url, params=params, headers=headers, auth=auth, verify=verify,
                            cert=cert)
        return res.text, res.status_code
467164
def post(url: str, *args, **kwargs) -> tuple:
    """"""
    return RequestsHelper.request(url, "post", *args, **kwargs)
1042
def get_request(request_url, request_headers=dict()):
    
    request = Request(request_url)
    for key, val in request_headers.items():
        request.add_header(key, val)

    try:
        response = urlopen(request, timeout=_REQUEST_TIMEOUT)
        response_content = response.read()
    except (HTTPError, URLError, socket.timeout):
        response_content = None

    return response_content
1308665
def post(url, data=None, json=None, **kwargs):
    """"""
    _set_content_type(kwargs)
    if _content_type_is_json(kwargs) and data is not None:
        data = dumps(data)
    _log_request('POST', url, kwargs, data)
    response = requests.post(url, data, json, **kwargs)
    _log_response(response)
    return response
612329
def _post(self, url, attributes=None, **kwargs):
        

        return self._request('post', url, attributes, **kwargs)
1355022
def __request(self, url, params):
        
        log.debug('request: %s %s' %(url, str(params)))
        try:
            response = urlopen(url, urlencode(params)).read()
            if params.get('action') != 'data':
                log.debug('response: %s' % response)
            if params.get('action', None) == 'data':
                return response
            else:
                return json.loads(response)
        except TypeError, e:
            log.exception('request error')
            raise ServerError(e)
        except IOError, e:
            log.error('request error: %s' % str(e))
            raise ServerError(e)
649227
def _do_request(self, url, params=None, data=None, headers=None):
        

        if not headers:
            headers = {'content-type': 'application/json'}

        try:
            response = requests.get(
                url, params=params, data=data, headers=headers)
        except:
            return None

        if response.status_code == 200:
            return response
1047847
def _post(self, uri, data):
        
        headers = self._get_headers()

        logging.debug("URI=" + str(uri))
        logging.debug("BODY=" + json.dumps(data))

        response = self.session.post(uri, headers=headers,
                data=json.dumps(data))
        if response.status_code in [200, 204]:
            try:
                return response.json()
            except ValueError:
                return "{}"
        else:
            logging.error(response.content)
            response.raise_for_status()
8687
public static Response post(String url)
        throws URISyntaxException, UnsupportedEncodingException, HttpException {
        return postParams(new HttpPost(url), new ArrayList<NameValuePair>(), null, null);
    }
3852
def post(self, url, postParameters=None, urlParameters=None):
        
        if self._action_token == None:
            self._action_token = self.get(ReaderUrl.ACTION_TOKEN_URL)

        if self._http == None:
            self._setupHttp()
        uri = url + "?" + self.getParameters(urlParameters)
        postParameters.update({'T':self._action_token})
        body = self.postParameters(postParameters)
        response, content = self._http.request(uri, "POST", body=body)
        return content