Ports
Each proxy has a public host:port on our cloud router. Two layouts:
The ready-made strings in GET /proxies/{id} (users[].http, users[].socks5) always use the right port.
You can pick the port numbers yourself from the cloud router's free range (range, 30000–30999 today). A port another proxy
uses — yours or another customer's — cannot be taken.
Changing a port or the mode changes the proxy's address. Every client still using the old address stops working within about 10 seconds. Each change is written to the activity log.
In split mode each port refuses the other protocol once the box runs agent 1.3.0 or newer (a SOCKS5 client on the
HTTP port is refused; an HTTP client on the SOCKS5 port gets 400). With an older agent both ports accept both.
Get the ports
GET /proxies/{id}/portsAbility: read
Response 200
Change the ports
PUT /proxies/{id}/portsAbility: manage · Who: the account owner or a team admin. At most 20 changes per minute.
Response 200 — the ports object as in Get the ports.
422 validation_failed with fields.http_port / fields.socks5_port when a port is outside range, already used, or
both ports are the same; fields.socks5_port "No free port left on this cloud router" when the range is full.
Pick a free port
GET /proxies/{id}/ports/freeAbility: manage · Returns one random free port of this proxy's cloud router (null when the range is full). It is not
reserved — use it in PUT /proxies/{id}/ports right away.
Response 200