代理整合指南與 REST API
將FastProxy代理連接到代碼、瀏覽器和工具所需的一切:主機、端口、用户名選項、可直接複製的示例以及REST API。
網關與端口
住宅、流動和無限計劃各使用一個閘道。靜態 ISP、數據中心和共享計劃以帶有各自連接埠的 IP 清單形式提供。
住宅代理
gw.fastproxy.fitHTTP和HTTPS 7700, SOCKS5 7701
移動代理
4g.fastproxy.fitHTTP和HTTPS 7800, SOCKS5 7801
無限住宅代理
unl.fastproxy.fitHTTP和HTTPS 7900, SOCKS5 7901
用戶名稱選項
在“My services”中為用户名添加選項。這些選項可按此順序組合。
-country-xx兩位字母國家代碼USER-country-us-city-name該國家/地區的城市,小寫,無空格USER-country-de-city-frankfurt-session-name將同一個IP保持最多60分鐘USER-country-gb-session-a1b2代碼示例
請將 USER 和 PASS 替換為您的登入資訊。每個分頁都是一個完整範例。
curl -x http://USER-country-us:PASS@gw.fastproxy.fit:7700 https://api.ipify.org
# SOCKS5, sticky for up to 60 minutes
curl -x socks5h://USER-country-de-session-a1:PASS@gw.fastproxy.fit:7701 https://api.ipify.orgimport requests
proxy = "http://USER-country-gb:PASS@gw.fastproxy.fit:7700"
r = requests.get("https://api.ipify.org?format=json",
proxies={"http": proxy, "https": proxy}, timeout=30)
print(r.json())import { ProxyAgent, fetch } from "undici";
const agent = new ProxyAgent("http://USER-country-jp:PASS@gw.fastproxy.fit:7700");
const res = await fetch("https://api.ipify.org?format=json", { dispatcher: agent });
console.log(await res.json());from playwright.sync_api import sync_playwright
with sync_playwright() as p:
browser = p.chromium.launch(proxy={
"server": "http://gw.fastproxy.fit:7700",
"username": "USER-country-fr-city-paris",
"password": "PASS",
})
page = browser.new_page()
page.goto("https://api.ipify.org")
print(page.content())# settings.py
DOWNLOADER_MIDDLEWARES = {
"scrapy.downloadermiddlewares.httpproxy.HttpProxyMiddleware": 110,
}
# in your spider
yield scrapy.Request(url, meta={
"proxy": "http://USER-country-us:PASS@gw.fastproxy.fit:7700"
})# list plans (no key needed)
curl https://fastproxy.fit/api/v1/plans
# buy a plan from credit
curl -X POST https://fastproxy.fit/api/v1/orders \
-H "Authorization: Bearer pvk_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"plan":"isp-25","country":"us"}'
# your services and logins
curl https://fastproxy.fit/api/v1/services -H "Authorization: Bearer pvk_YOUR_KEY"REST API
基礎URL為 https://fastproxy.fit/api/v1。請將密鑰作為 Authorization: Bearer pvk_ 發送。在賬户區域創建密鑰。每個密鑰每分鐘300次請求。
| 方法 | 路徑 | 密鑰 | 退款 |
|---|---|---|---|
| GET | /api/v1/plans | 否 | 每個套餐及其價格、數量和時長 |
| GET | /api/v1/locations | 否 | 國家/地區、城市以及各地銷售的產品 |
| GET | /api/v1/balance | 是 | 您以美元計的額度 |
| POST | /api/v1/orders | 是 | 用餘額購買套餐:{plan, country} |
| GET | /api/v1/services | 是 | 您的計劃及其登入資訊、IP 清單和到期日期 |
| GET | /api/v1/services/{id} | 是 | 一個計劃 |
錯誤
401
unauthorizedAPI 密鑰缺失或錯誤。不會產生任何費用。402
funds餘額低於套餐價格。不會產生任何扣費。400
bad_plan / bad_country未知計劃,或該產品未在此國家出售。不會產生任何費用。429
rate_limited單一密鑰每分鐘超過 300 次請求。503
network目前無法開通該計劃。不會產生任何費用。