src/Request.php
public function setProxy($address, $port = 1080, $type = CURLPROXY_HTTP)
    {
        $this->curlOptions[ CURLOPT_PROXY ] = $address;
        $this->curlOptions[ CURLOPT_PROXYPORT ] = $port;
        $this->curlOptions[ CURLOPT_PROXYTYPE ] = $type;
        $this->curlOptions[ CURLOPT_HTTPPROXYTUNNEL ] = true;

        return $this;
    }
public function setProxy($address, $port = 1080, $type = CURLPROXY_HTTP)
    {
        $this->curlOptions[ CURLOPT_PROXY ] = $address;
        $this->curlOptions[ CURLOPT_PROXYPORT ] = $port;
        $this->curlOptions[ CURLOPT_PROXYTYPE ] = $type;
        $this->curlOptions[ CURLOPT_HTTPPROXYTUNNEL ] = true;

        return $this;
    }
Request::setProxy

Set the HTTP proxy to tunnel requests through.

@param string     $address  The HTTP proxy address.
@param int|string $port     The HTTP proxy port.
@param int|string $type     The HTTP proxy type, available options:
1. CURLPROXY_HTTP
2. CURLPROXY_HTTP_1_0
3. CURLPROXY_SOCKS4
4. CURLPROXY_SOCKS5
5. CURLPROXY_SOCKS4A
6. CURLPROXY_SOCKS5_HOSTNAME

@return static