Products / Residential Proxies
Advanced Filters
Combine targeting options in one username. The gateway reads the filters from the username, so you don't change anything else in your code.
Available filters
| Parameter | Type | Description | Example |
|---|---|---|---|
__cc_ | String, 2 letters | Exit country, lowercase ISO 3166-1 alpha-2. See Location Settings. | __cc_de |
__city_ | String | City, lowercase English name, underscores for spaces. Use with __cc_. | __city_munich |
__st_ | String | US state with us_ prefix. | __st_us_texas |
__sid_ | String, 1–32 letters or digits | Keeps the same exit IP across connections. See Session Control. | __sid_job01 |
Rules
- Use each filter once.
- Order:
__cc_,__city_,__st_, then__sid_last. - Use either
__city_or__st_, not both. - The password never changes.
- Unknown filters or the wrong order return
400.
Query with filters
A sticky German IP. Every request with session job01 leaves from the same German residential IP.
curl -x http://proxy.crawlhub.ai:8000 \
-U "crh_USERNAME__cc_de__sid_job01:PASSWORD" \
https://ipinfo.io/jsonimport requests
username = "crh_USERNAME__cc_de__sid_job01"
password = "PASSWORD"
proxy = f"http://{username}:{password}@proxy.crawlhub.ai:8000"
response = requests.get(
"https://ipinfo.io/json",
proxies={"http": proxy, "https": proxy},
timeout=30,
)
print(response.json())// npm install undici
import { fetch, ProxyAgent } from "undici";
const auth = Buffer.from("crh_USERNAME__cc_de__sid_job01:PASSWORD").toString("base64");
const agent = new ProxyAgent({
uri: "http://proxy.crawlhub.ai:8000",
token: `Basic ${auth}`,
});
const res = await fetch("https://ipinfo.io/json", { dispatcher: agent });
console.log(await res.json());<?php
$ch = curl_init("https://ipinfo.io/json");
curl_setopt($ch, CURLOPT_PROXY, "http://proxy.crawlhub.ai:8000");
curl_setopt($ch, CURLOPT_PROXYUSERPWD, "crh_USERNAME__cc_de__sid_job01:PASSWORD");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 30);
echo curl_exec($ch);
curl_close($ch);package main
import (
"fmt"
"io"
"net/http"
"net/url"
"time"
)
func main() {
proxyURL, _ := url.Parse("http://crh_USERNAME__cc_de__sid_job01:PASSWORD@proxy.crawlhub.ai:8000")
client := &http.Client{
Transport: &http.Transport{Proxy: http.ProxyURL(proxyURL)},
Timeout: 30 * time.Second,
}
resp, err := client.Get("https://ipinfo.io/json")
if err != nil { panic(err) }
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}import java.net.*;
import java.net.http.*;
public class Main {
public static void main(String[] args) throws Exception {
// Java blocks Basic auth on HTTPS tunnels by default; allow it.
System.setProperty("jdk.http.auth.tunneling.disabledSchemes", "");
HttpClient client = HttpClient.newBuilder()
.proxy(ProxySelector.of(new InetSocketAddress("proxy.crawlhub.ai", 8000)))
.authenticator(new Authenticator() {
protected PasswordAuthentication getPasswordAuthentication() {
return new PasswordAuthentication("crh_USERNAME__cc_de__sid_job01", "PASSWORD".toCharArray());
}
}).build();
HttpRequest req = HttpRequest.newBuilder(URI.create("https://ipinfo.io/json")).build();
System.out.println(client.send(req, HttpResponse.BodyHandlers.ofString()).body());
}
}using System.Net;
var proxy = new WebProxy("http://proxy.crawlhub.ai:8000")
{
Credentials = new NetworkCredential("crh_USERNAME__cc_de__sid_job01", "PASSWORD")
};
using var client = new HttpClient(new HttpClientHandler { Proxy = proxy, UseProxy = true })
{
Timeout = TimeSpan.FromSeconds(30)
};
Console.WriteLine(await client.GetStringAsync("https://ipinfo.io/json"));require "net/http"
uri = URI("https://ipinfo.io/json")
proxy = ["proxy.crawlhub.ai", 8000, "crh_USERNAME__cc_de__sid_job01", "PASSWORD"]
Net::HTTP.start(uri.host, uri.port, *proxy, use_ssl: true, read_timeout: 30) do |http|
puts http.get(uri.path).body
endExample response
Values are illustrative.
JSON
{
"ip": "84.142.67.19",
"city": "Hamburg",
"region": "Hamburg",
"country": "DE",
"org": "AS3320 Deutsche Telekom AG",
"timezone": "Europe/Berlin"
}More combinations
| Goal | Username |
|---|---|
| Random IP, any country | crh_USERNAME |
| Random IP in the US | crh_USERNAME__cc_us |
| Sticky IP, any country | crh_USERNAME__sid_abc123 |
| Sticky IP in the UK | crh_USERNAME__cc_gb__sid_abc123 |
| Random IP in London | crh_USERNAME__cc_gb__city_london |
| Sticky IP in Texas | crh_USERNAME__st_us_texas__sid_abc123 |