Using Guzzle behind an authenticated proxy in PHP: per-client and per-request configuration, ISP targeting, and cURL fallbacks.
use GuzzleHttp\Client; $user = getenv('QP_USER') . '-country-us'; $pass = getenv('QP_PASS'); $client = new Client([ 'proxy' => "http://$user:$pass@residentialboson.quantumproxies.io:9000", 'timeout' => 30, ]); $res = $client->get('https://ipinfo.io/json'); echo $res->getBody();
$client = new Client(['timeout' => 30]); $res = $client->get('https://ipinfo.io/json', [ 'proxy' => "http://$user:$pass@residentialboson.quantumproxies.io:9000", ]);
Static ISP proxies sit between datacenter (fast, easily flagged) and residential (stealthy, rotating): real carrier ASNs with server-grade uptime. The premium gateway takes an -isp- flag:
$isp = "http://{$user}-country-us-region-california-city-losangeles-isp-comcast:$pass" . "@residentialpremium.quantumproxies.io:8080";
$ch = curl_init('https://ipinfo.io/json'); curl_setopt_array($ch, [ CURLOPT_PROXY => 'residentialboson.quantumproxies.io:9000', CURLOPT_PROXYUSERPWD => "$user:$pass", CURLOPT_RETURNTRANSFER => true, CURLOPT_TIMEOUT => 30, ]); echo curl_exec($ch);
Full runnable script in example.php:
composer require guzzlehttp/guzzle
QP_USER=... QP_PASS=... php example.php
Proxies by QuantumProxies — ISP, residential, datacenter and mobile pools with per-GB pricing. Account + credentials: app.quantumproxies.io.