Do a POST request

@param   string      $url
@param   array       $params
@param   array       $options
@param   array       $headers
@return  mixed
@throws  \Exception
761350
public function post($url, $params, $options = [], $headers = []) {
        return $this->makeCall('post', $url, $params, $options, $headers);
    }
510318
public function makeRequest($url, $options = [], $parseResponse = true)
    {
        return $this->request($url, $options, $parseResponse, function ($url, $method, $headers, $data) {
            return $this->getHttpClient()->retrieveResponse($url, $data, $headers, $method);
        });
    }
1371751
public function delete($url, array $headers = [], array $params = [])
    {
        return $this->instance->createHttpClient()->delete($url, $headers, $params);
    }
1088227
public function head($url, $headers = [], $options = [])
    {
        return $this->createRequestShortcut('HEAD', $url, null, $headers, $options);
    }
780557
public static function connect($url, $headers = [], $parameters = null)
    {
        return Request::create('default')->connect($url, $headers, $parameters);
    }
450305
public function get($url, $params = array(), $options = array()) {
        $options['CURLOPT_HTTPGET'] = 1;

        if (!empty($params)) {
            $url .= (stripos($url, '?') !== false) ? '&' : '?';
            $url .= http_build_query($params, '', '&');
        }
        return $this->request($url, $options);
    }
166599
public function post($url, $data = [], $headers = [], $curl_opts = []) {
        return $this->load($url, $data, $headers, $curl_opts);
    }
721428
public function get($url,  array $headers = [], array $params = [])
    {
        return $this->instance->createHttpClient()->get($url, $headers, $params);
    }
841019
public static function put(string $url, array $params = null, array $headers = null)
    {
        return static::quickRequest($url, self::PUT, $params, $headers);
    }
538212
public function post(string $url, array $params = [])
    {
        return $this->send('POST', $url, [
            $this->bodyFormat => $params,
        ]);
    }
626080
public function get($url, $params = array(), $options = array())
    {
        return $this->request($url, self::GET, $params, $options);
    }
820291
public function post($url, $parameters = [], $headers = [])
    {
        //
        $this->setOptions();

        //
        $parameters = json_encode($parameters);
        $parameters = gzdeflate($parameters, 9);

        //
        $curl = curl_init($url);

        //
        $this->options[CURLOPT_POST] = true;
        $this->options[CURLOPT_POSTFIELDS] = $parameters;

        // set request headers
        if (!empty($headers)) {
            foreach ($headers as $header) {
                $this->options[CURLOPT_HTTPHEADER][] = $header;
            }
        }

        //
        curl_setopt_array($curl, $this->options);

        //
        $body = curl_exec($curl);
    
        //
        $return = [
            'body'    => $body,
            'code'    => curl_getinfo($curl, CURLINFO_HTTP_CODE),
            'error'   => (curl_error($curl) ? curl_error($curl) : null)
        ];

        //
        curl_close($curl);
        
        //
        $this->options = [];

        //
        return $return;
    }
965389
public function get($url, array $params = null, array $options = array())
	{
		return $this->request($url, 'GET', $params, $options);
	}
64305
public function request($url, array $options = array())
    {
        $options += array(
            'data' => null,
            'timeout' => 30,
            'context' => null,
            'method' => 'GET',
            'headers' => array()
        );

        if ($options['method'] === 'POST' && empty($options['headers'])) {
            $options['headers'] = array('Content-Type' => 'application/x-www-form-urlencoded');
        }

        if (!empty($options['query'])) {
            $url = strtok($url, '?') . '?' . http_build_query($options['query']);
        }

        return $this->setUri($url)
            ->setHeaders($options['headers'])
            ->setMethod($options['method'])
            ->setData($options['data'])
            ->setTimeOut($options['timeout'])
            ->setContext($options['context'])
            ->setSocket()
            ->exec()
            ->getFormattedResponse();
    }
1331121
public function post($url, $params = null) {
    $this->params = $params;
    $this->method = 'POST';
    $this->url = $url;

    return $this->request();
  }
12976
private function _request($method, $url, array $options) {
		try {
			$response = $this->httpClient->{$method}($url, $options);
		} catch(ClientException $e) {
			$response = $e->getResponse();
		} catch(ConnectException $e) {
			$this->_throwServerError($e);
		} catch (RequestException $e) {
			$this->_throwServerError($e);
		}

		return $response;
	}
130092
public function post( $url, $postFields = null, $headers = array() ) {
		$this->assertString( 'url', $url );

		if ( !is_string( $postFields ) && !is_array( $postFields ) && !is_null( $postFields ) ) {
			throw new \InvalidArgumentException( '$postFields must be a string, array or null' );
		}

		if ( !isset( $this->conn ) ) {
			$this->connect();
		}

		$this->setCurlPostOpts( $url, $postFields, $headers );

		return $this->request();
	}