- API Reference
- Box API
- VPN
Change the base ports of the WireGuard and OpenVPN servers
Saves both base ports, kills every OpenVPN process and restarts the controller. Both fields are required and are not range-checked by the box.
/v2/set_vpn_portRequest body application/json · required
Authentication
Needs a trusted caller (loopback, LAN unless "force auth for local" is on, whitelisted IP, allowed Tailscale) or valid dashboard Basic credentials, which are checked only when dashboard authentication is enabled.
Responses
Saved; the controller restarts.
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.
Unhandled error, for example a non-integer position or a missing required parameter.
Error name, e.g. internal_server_error or bad_request.