- API Reference
- Box API
- Rotation
Get a new public IP for one proxy (legacy query-string form)
Use this only for existing integrations; new code should use /api/v1/rotate_ip/proxy/{proxy}. When a rotation delay is configured the box answers command_sent at once and rotates after the delay. A host that is a registered external XProxy server is forwarded unless internal is present.
/resetQuery parameters
Proxy address as HOST:PORT, for example 192.0.2.10:4001. Only the port selects the slot.
192.0.2.10:4001Any value. Answer from this box even if the host is a registered external server.
Authentication
Open by default: with "Basic auth for all API" (api_auth_check) off, anyone who can reach the box can call it. When it is on, the caller must be trusted (loopback, LAN unless "force auth for local" is on, whitelisted IP, allowed Tailscale) or send dashboard Basic credentials, which are checked only when dashboard authentication (dashboard_disable_auth off) is enabled.
Responses
Rotation accepted or refused.
True when the box accepted the request.
Outcome code or message (see the operation's error table).
The caller is not trusted (not loopback, LAN, whitelisted or allowed Tailscale) and sent no valid Basic credentials. The body depends on whether "Basic auth for all API" is on. Routes that also use the panel login can answer a plain-text 401 "Unauthorized Access" instead.
Errors returned in msg
| msg | Meaning | What to do |
|---|---|---|
missing_proxy_parameter | proxy is missing. | Send proxy=HOST:PORT. |
invalid_format_proxy | proxy is not HOST:PORT. | Send proxy=HOST:PORT. |
command_sent | With status true, the rotation started. With status false, the modem did not accept the command. | On status false check the slot status before retrying. |
modem_resetting | A rotation is already running. | Wait for MODEM_READY. |
reset_too_much | Less than the minimum interval (5 seconds by default) since the last rotation. | Wait and retry. |
modem_disconnected | The modem type cannot rotate. | Check the modem in the panel. |
need_upgrade | The license does not include IP rotation. | Upgrade the license. |
slot_not_found | No slot uses this port. | Use a port from /api/v1/info_list. |
external_server_error | The external server did not answer. | Check that server or add internal=1. |