Pass proxyUrl when you need browser traffic to use your own SOCKS5 proxy.
Use a Proxy
const session = await client.browser.session.create({
type: "hosted",
proxyUrl: "socks5://user:[email protected]:1080",
});
resp = requests.post(
"https://api.driver.dev/v1/browser/session",
headers={
"Authorization": f"Bearer {os.getenv('DRIVER_API_KEY')}",
"Content-Type": "application/json",
},
json={
"type": "hosted",
"proxyUrl": "socks5://user:[email protected]:1080",
},
)
resp.raise_for_status()
session = resp.json()
curl -X POST https://api.driver.dev/v1/browser/session \
-H "Authorization: Bearer $DRIVER_API_KEY" \
-H "Content-Type: application/json" \
-d '{"type":"hosted","proxyUrl":"socks5://user:[email protected]:1080"}'
socks5://username:password@host:port
proxyUrl must point to a real SOCKS5 proxy reachable from Driver infrastructure. It cannot be used with nodeId.