Skip to content
Login Sign up

Integrations

Any client that speaks HTTP or SOCKS5 works with the Shifter gateway. Below are copy-paste configs for the tools most customers use.

Terminal window
curl -x customer-USERNAME-country-us-sid-9f3a2b7c-ttl-600:PASSWORD@p.shifter.io:443 \
https://ipinfo.io/json

Middleware that rotates the proxy URL per request and lets spiders override country via request.meta:

settings.py
DOWNLOADER_MIDDLEWARES = {
"scrapy.downloadermiddlewares.httpproxy.HttpProxyMiddleware": 110,
"your_project.middlewares.ShifterProxyMiddleware": 100,
}
# middlewares.py
import os
class ShifterProxyMiddleware:
def process_request(self, request, spider):
username = os.environ["SHIFTER_USERNAME"]
password = os.environ["SHIFTER_PASSWORD"]
country = request.meta.get("shifter_country", "us")
request.meta["proxy"] = (
f"http://{username}-country-{country}:{password}@p.shifter.io:443"
)

Override per request with request.meta["shifter_country"] = "de".

import puppeteer from 'puppeteer';
const browser = await puppeteer.launch({
args: ['--proxy-server=http://p.shifter.io:443'],
});
const page = await browser.newPage();
await page.authenticate({
username: 'customer-USERNAME-country-us-sid-s1-ttl-600-sid-9f3a2b7c-ttl-600',
password: 'PASSWORD',
});
await page.goto('https://ipinfo.io/json');
console.log(await page.content());
await browser.close();
import { chromium } from 'playwright';
const browser = await chromium.launch({
proxy: {
server: 'http://p.shifter.io:443',
username: 'customer-USERNAME-country-us-sid-s1-ttl-600-sid-9f3a2b7c-ttl-600',
password: 'PASSWORD',
},
});
const page = await browser.newPage();
await page.goto('https://ipinfo.io/json');
  1. Open Options → New Profile → Proxy Profile.
  2. Protocol: HTTP, Server: p.shifter.io, Port: 443.
  3. Username: customer-USERNAME-country-us. Password: PASSWORD.
  4. Apply changes and switch to the new profile.

In the browser profile settings:

  • Connection type: HTTP Proxy
  • Host: p.shifter.io
  • Port: 443
  • Username: customer-USERNAME-country-us-sid-<profile-id>-ttl-1800
  • Password: PASSWORD

Use the profile id as the session id so each managed browser holds a consistent IP throughout its session.

  • Sessions, how to build session ids that play well with browser profiles.
  • FAQ, what to do when a target site still blocks.