无需 KYC — 无需身份证件、自拍照或文件。使用加密货币支付。
语言: 简体中文
选择 1 GB

API 参考

移动端口和 IP 轮换

专用 4G/5G 端口:立即或按定时计划更换 IP,使用轮换链接并查看每日流量。

6 分钟阅读

本页端点

  • GET /v1/mobile:列出移动代理端口
  • GET /v1/mobile/{portId}:获取移动代理端口
  • PATCH /v1/mobile/{portId}:重命名、切换自动续费,或设置自动轮换
  • POST /v1/mobile/{portId}/rotate:立即更换 IP
  • GET /v1/mobile/{portId}/rotate:轮换链接(在查询字符串中通过 GET 传入 API 密钥)
  • POST /v1/mobile/{portId}/reset-password:为端口生成新的代理密码
  • GET /v1/mobile/{portId}/usage:端口每日流量(仅供参考:流量不限,但须遵守公平使用政策)
  • GET /v1/catalog/countries/{countryCode}/carriers:一个国家/地区中提供 4G/5G 端口的移动运营商

基础 URL https://localserpproxy.com/api/v1。身份验证、错误和限制:请参阅 API 概览。

查看移动代理端口

GET/v1/mobile

身份验证:在 Authorization: Bearer API_KEY 请求头中提供 API 密钥。

响应 200 OK

{
  "data": [
    {
      "id": "mob_2v8k1q",
      "label": "US Verizon #1",
      "status": "active",
      "country": "US",
      "city": null,
      "carrier": "verizon",
      "carrierName": "Verizon",
      "networkType": "4G",
      "currentIp": "203.0.113.201",
      "ipChangedAt": "2026-10-05T14:03:11Z",
      "endpoint": {
        "host": "gw.localserpproxy.com",
        "httpPort": 7777,
        "socksPort": 7778
      },
      "username": "USERNAME",
      "password": "PASSWORD",
      "rotation": {
        "mode": "interval",
        "intervalMinutes": 10
      },
      "minRotationIntervalSeconds": 30,
      "rotationLink": "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q/rotate?key=API_KEY",
      "planId": "mob-us-30d",
      "autoRenew": false,
      "createdAt": "2026-10-05T14:03:11Z",
      "expiresAt": "2026-11-04T14:03:11Z"
    }
  ]
}

代码示例

curl
curl -s "https://localserpproxy.com/api/v1/mobile" \
  -H "Authorization: Bearer $API_KEY"
Python
import os
import requests

API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}

r = requests.get(f"{API}/mobile", headers=HEADERS, timeout=30)
r.raise_for_status()
print(r.json())
Node.js
// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';

const res = await fetch(`${API}/mobile`, {
  headers: { Authorization: `Bearer ${process.env.API_KEY}` },
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());

获取移动代理端口

GET/v1/mobile/{portId}

身份验证:在 Authorization: Bearer API_KEY 请求头中提供 API 密钥。

参数

名称位置类型必填说明
portIdpathstring是—

响应 200 OK

{
  "id": "mob_2v8k1q",
  "label": "US Verizon #1",
  "status": "active",
  "country": "US",
  "city": null,
  "carrier": "verizon",
  "carrierName": "Verizon",
  "networkType": "4G",
  "currentIp": "203.0.113.201",
  "ipChangedAt": "2026-10-05T14:03:11Z",
  "endpoint": {
    "host": "gw.localserpproxy.com",
    "httpPort": 7777,
    "socksPort": 7778
  },
  "username": "USERNAME",
  "password": "PASSWORD",
  "rotation": {
    "mode": "interval",
    "intervalMinutes": 10
  },
  "minRotationIntervalSeconds": 30,
  "rotationLink": "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q/rotate?key=API_KEY",
  "planId": "mob-us-30d",
  "autoRenew": false,
  "createdAt": "2026-10-05T14:03:11Z",
  "expiresAt": "2026-11-04T14:03:11Z"
}

代码示例

curl
curl -s "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q" \
  -H "Authorization: Bearer $API_KEY"
Python
import os
import requests

API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}

r = requests.get(f"{API}/mobile/mob_2v8k1q", headers=HEADERS, timeout=30)
r.raise_for_status()
print(r.json())
Node.js
// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';

const res = await fetch(`${API}/mobile/mob_2v8k1q`, {
  headers: { Authorization: `Bearer ${process.env.API_KEY}` },
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());

重命名、开启或关闭自动续费,或设置自动轮换

PATCH/v1/mobile/{portId}

重命名端口、开启或关闭自动续费,或设置自动轮换间隔(每 2 分钟至每 24 小时一次):"rotation": { "mode": "interval", "intervalMinutes": 10 }(2–1440 分钟);"mode": "manual" 可关闭自动轮换。否则,端口会一直使用当前 IP,直到你手动轮换;不过运营商有时也可能自行更换 IP。

身份验证:在 Authorization: Bearer API_KEY 请求头中提供 API 密钥。

参数

名称位置类型必填说明
portIdpathstring是—

请求正文

字段类型必填说明
labelstring否最多 60 个字符
autoRenewboolean否—
rotationobject否自动轮换间隔:{ "mode": "interval", "intervalMinutes": 2–1440 }(每 2 分钟至每 24 小时一次);或使用 { "mode": "manual", "intervalMinutes": null },仅按需轮换。
示例: 自动轮换
{
  "rotation": {
    "mode": "interval",
    "intervalMinutes": 10
  }
}
示例: 手动
{
  "rotation": {
    "mode": "manual",
    "intervalMinutes": null
  }
}

响应 200 OK

{
  "id": "mob_2v8k1q",
  "label": "US Verizon #1",
  "status": "active",
  "country": "US",
  "city": null,
  "carrier": "verizon",
  "carrierName": "Verizon",
  "networkType": "4G",
  "currentIp": "203.0.113.201",
  "ipChangedAt": "2026-10-05T14:03:11Z",
  "endpoint": {
    "host": "gw.localserpproxy.com",
    "httpPort": 7777,
    "socksPort": 7778
  },
  "username": "USERNAME",
  "password": "PASSWORD",
  "rotation": {
    "mode": "interval",
    "intervalMinutes": 10
  },
  "minRotationIntervalSeconds": 30,
  "rotationLink": "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q/rotate?key=API_KEY",
  "planId": "mob-us-30d",
  "autoRenew": false,
  "createdAt": "2026-10-05T14:03:11Z",
  "expiresAt": "2026-11-04T14:03:11Z"
}

代码示例

curl
curl -s -X PATCH "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"rotation":{"mode":"interval","intervalMinutes":10}}'
Python
import os
import requests

API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}

r = requests.patch(f"{API}/mobile/mob_2v8k1q", headers=HEADERS, json={"rotation": {"mode": "interval", "intervalMinutes": 10}}, timeout=30)
r.raise_for_status()
print(r.json())
Node.js
// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';

const res = await fetch(`${API}/mobile/mob_2v8k1q`, {
  method: 'PATCH',
  headers: { Authorization: `Bearer ${process.env.API_KEY}`, 'Content-Type': 'application/json' },
  body: JSON.stringify({ rotation: { mode: 'interval', intervalMinutes: 10 } }),
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());

立即更换 IP

POST/v1/mobile/{portId}/rotate

每次轮换都会重新连接运营商以获取新 IP,通常需要 5–15 秒;运营商偶尔可能分配相同的 IP,只需再次轮换即可。每个端口每 30 秒最多轮换一次(minRotationIntervalSeconds):过早发起的轮换请求会返回 429 rotation_too_soon,并附带 Retry-After(需等待的秒数)。

身份验证:在 Authorization: Bearer API_KEY 请求头中提供 API 密钥。

参数

名称位置类型必填说明
portIdpathstring是—

响应 200 OK

{
  "ip": "203.0.113.201",
  "previousIp": "203.0.113.77",
  "rotatedAt": "2026-10-05T14:03:11Z",
  "nextRotationAvailableAt": "2026-10-05T14:03:41Z"
}

代码示例

curl
curl -s -X POST "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q/rotate" \
  -H "Authorization: Bearer $API_KEY"
Python
import os
import requests

API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}

r = requests.post(f"{API}/mobile/mob_2v8k1q/rotate", headers=HEADERS, timeout=30)
r.raise_for_status()
print(r.json())
Node.js
// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';

const res = await fetch(`${API}/mobile/mob_2v8k1q/rotate`, {
  method: 'POST',
  headers: { Authorization: `Bearer ${process.env.API_KEY}` },
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());

GET/v1/mobile/{portId}/rotate

与 POST 相同,适用于脚本和书签:GET https://localserpproxy.com/api/v1/mobile/{portId}/rotate?key=API_KEY。密钥需要具备 proxies 权限范围。format=text 会以 text/plain 格式返回新 IP。

身份验证:在 key 查询参数中提供 API 密钥(权限范围 proxies),因此链接可通过书签打开。

参数

名称位置类型必填说明
keyquerystring是你的 API 密钥(权限范围 proxies)。
portIdpathstring是—
formatqueryjson · text否默认 json

响应 200 OK

{
  "ip": "203.0.113.201",
  "previousIp": "203.0.113.77",
  "rotatedAt": "2026-10-05T14:03:11Z",
  "nextRotationAvailableAt": "2026-10-05T14:03:41Z"
}

代码示例

为端口生成新代理密码

POST/v1/mobile/{portId}/reset-password

身份验证:在 Authorization: Bearer API_KEY 请求头中提供 API 密钥。

参数

名称位置类型必填说明
portIdpathstring是—

响应 200 OK

{
  "id": "mob_2v8k1q",
  "label": "US Verizon #1",
  "status": "active",
  "country": "US",
  "city": null,
  "carrier": "verizon",
  "carrierName": "Verizon",
  "networkType": "4G",
  "currentIp": "203.0.113.201",
  "ipChangedAt": "2026-10-05T14:03:11Z",
  "endpoint": {
    "host": "gw.localserpproxy.com",
    "httpPort": 7777,
    "socksPort": 7778
  },
  "username": "USERNAME",
  "password": "PASSWORD",
  "rotation": {
    "mode": "interval",
    "intervalMinutes": 10
  },
  "minRotationIntervalSeconds": 30,
  "rotationLink": "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q/rotate?key=API_KEY",
  "planId": "mob-us-30d",
  "autoRenew": false,
  "createdAt": "2026-10-05T14:03:11Z",
  "expiresAt": "2026-11-04T14:03:11Z"
}

代码示例

curl
curl -s -X POST "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q/reset-password" \
  -H "Authorization: Bearer $API_KEY"
Python
import os
import requests

API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}

r = requests.post(f"{API}/mobile/mob_2v8k1q/reset-password", headers=HEADERS, timeout=30)
r.raise_for_status()
print(r.json())
Node.js
// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';

const res = await fetch(`${API}/mobile/mob_2v8k1q/reset-password`, {
  method: 'POST',
  headers: { Authorization: `Bearer ${process.env.API_KEY}` },
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());

端口每日流量(仅供参考:流量不限,但须遵守公平使用政策)

GET/v1/mobile/{portId}/usage

仅供参考。您的专用端口流量不限,但须遵守公平使用政策:运营商可能会降低网速或暂停服务,以应对极高流量。

身份验证:在 Authorization: Bearer API_KEY 请求头中提供 API 密钥。

参数

名称位置类型必填说明
portIdpathstring是—
fromquerystring (date)否首日(UTC),包含当天。默认值 = to 前 29 天。
toquerystring (date)否末日(UTC),包含当天。默认值 = 今天。最长范围为 366 天。

响应 200 OK

{
  "from": "2026-10-04",
  "to": "2026-10-05",
  "totalBytes": 2350000000,
  "totalRequests": 48210,
  "points": [
    {
      "date": "2026-10-04",
      "bytes": 1200000000,
      "requests": 24800
    },
    {
      "date": "2026-10-05",
      "bytes": 1150000000,
      "requests": 23410
    }
  ],
  "byCountry": [
    {
      "country": "US",
      "bytes": 2350000000
    }
  ]
}

代码示例

curl
curl -s "https://localserpproxy.com/api/v1/mobile/mob_2v8k1q/usage" \
  -H "Authorization: Bearer $API_KEY"
Python
import os
import requests

API = "https://localserpproxy.com/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['API_KEY']}"}

r = requests.get(f"{API}/mobile/mob_2v8k1q/usage", headers=HEADERS, timeout=30)
r.raise_for_status()
print(r.json())
Node.js
// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';

const res = await fetch(`${API}/mobile/mob_2v8k1q/usage`, {
  headers: { Authorization: `Bearer ${process.env.API_KEY}` },
});
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());

国家/地区中提供 4G/5G 端口的移动运营商

GET/v1/catalog/countries/{countryCode}/carriers

公开接口:无需 API 密钥。

参数

名称位置类型必填说明
countryCodepathstring是ISO 3166-1 alpha-2,使用大写字母。

响应 200 OK

{
  "data": [
    {
      "id": "verizon",
      "name": "Verizon",
      "networkTypes": [
        "4G",
        "5G"
      ],
      "available": true,
      "cities": []
    }
  ]
}

代码示例

curl
curl -s "https://localserpproxy.com/api/v1/catalog/countries/US/carriers"
Python
import os
import requests

API = "https://localserpproxy.com/api/v1"

r = requests.get(f"{API}/catalog/countries/US/carriers", timeout=30)
r.raise_for_status()
print(r.json())
Node.js
// Node.js 18+ (built-in fetch), ES module
const API = 'https://localserpproxy.com/api/v1';

const res = await fetch(`${API}/catalog/countries/US/carriers`);
if (!res.ok) throw new Error((await res.json()).error?.message ?? `HTTP ${res.status}`);
console.log(await res.json());

1 GB US$1.50 · 无需 KYC

查看价格