BytesFlows Docs

Integration and Troubleshooting

Connect to BytesFlows residential proxies over HTTP or SOCKS5 using cURL or Python, and troubleshoot authentication, timeouts, and exit-country issues.

Copy the full username and proxy sub-user password from the Endpoint Generator↗. Inject them into your test environment as BYTESFLOWS_PROXY_USERNAME and BYTESFLOWS_PROXY_PASSWORD. Keep proxy URLs that contain credentials in controlled configuration.

cURL

Use the HTTP proxy to reach an HTTPS destination.

bash
curl --silent --show-error --fail --max-time 20 --noproxy "" \
  --proxy "http://p1.bytesflows.com:8001" \
  --proxy-user "${BYTESFLOWS_PROXY_USERNAME}:${BYTESFLOWS_PROXY_PASSWORD}" \
  "https://ipinfo.io"

Use the SOCKS5 proxy to reach the same destination. The socks5h:// scheme tells cURL to let the proxy resolve the destination hostname.

bash
curl --silent --show-error --fail --max-time 20 --noproxy "" \
  --proxy "socks5h://p1.bytesflows.com:8001" \
  --proxy-user "${BYTESFLOWS_PROXY_USERNAME}:${BYTESFLOWS_PROXY_PASSWORD}" \
  "https://ipinfo.io"

Python Requests

Use requests in your application's Python environment. For SOCKS5, use the requests[socks] extra and change scheme to socks5h below. URL-encode the username and password separately so that special characters in a credential do not change the URL structure.

python
import os
from urllib.parse import quote

import requests

username = quote(os.environ["BYTESFLOWS_PROXY_USERNAME"], safe="")
password = quote(os.environ["BYTESFLOWS_PROXY_PASSWORD"], safe="")
scheme = "http"
proxy_url = f"{scheme}://{username}:{password}@p1.bytesflows.com:8001"

response = requests.get(
    "https://ipinfo.io",
    proxies={"http": proxy_url, "https": proxy_url},
    timeout=(5, 20),
)
response.raise_for_status()
print(response.text)

Browser and graphical clients

Select HTTP or SOCKS5. Enter p1.bytesflows.com as the host, 8001 as the port, and the full proxy username and sub-user password in the authentication fields. If the client takes a single URL, use the generator's Proxy Format output and check the URL format that your client accepts.

Troubleshoot by symptom

SymptomFirst check
HTTP reports 407 Proxy Authentication Required, or SOCKS5 authentication failsConfirm that the proxy user is enabled and that the password belongs to that sub-user. Include the u- prefix and all generated username parameters.
The connection times out, is refused, or fails during the handshakeCheck the host, port, and proxy protocol. Turn off automatic proxy selection in the client for the test and run cURL from the same network.
The exit country differs from your selectionSelect the country again in the generator, confirm the corresponding -loc- segment, and compare the IP lookup result.
The exit IP changes during a sticky sessionCheck the session ID, country, and duration. Confirm that the client still uses the same credentials, then test with a few separate requests.
A previously working connection stops workingCheck available traffic, the sub-user's usage cap, and account status. Test the IP lookup and your target separately to determine where the failure occurs.

When contacting support, include the error as it appeared, time of failure, protocol, target hostname, and selected country. Remove the proxy password and full connection string before sharing.

Quickstart · Country Targeting and Sessions · Traffic Query API

On this page