Turn a cluster's traffic paths on or off: public ports 80 and 443 (public), Cloudflare Tunnel (tunnel, with defaultDomain and accountId as for setClusterTraffic) and websites on the tailnet (tailnet: ts.net names and free domains on the servers' Tailscale addresses; the servers stay on the tailnet). Unset fields stay as they are. At least one path stays on. Each domain takes one path, and a domain whose path is off isn't served. When a path turned off still has domains, nothing changes: status is "confirm" and domains lists them, each with outcome "moves" or "stops". Send it again with confirm to go ahead. Turning public ports off with the tunnel on moves the domains in the tunnel's Cloudflare account to the tunnel first (moveToTunnel, on by default), and the ports close once every one of them is on it (status "moving"): its record has moved and Cloudflare has had time to serve it. Published TCP and UDP ports pause for a few seconds when public ports go on or off, as they move between Services. Turning the tunnel off with public ports on switches its domains back first, then removes the tunnel at Cloudflare. dashboardDrops: switching Tailnet drops open connections to Pyo's dashboard on the tailnet once (the cluster Pyo runs on, with ts.net names, until its connect command has run for this release). Team owners and admins.
API key access: full.
apiKeyAuthorizationBearer <pyo_…>An API key from the dashboard's API keys page: Authorization: Bearer pyo_…. Keys can expire, and an expired one gets a 401.
application/jsonTurn a cluster's traffic paths on or off: public ports 80 and 443 (public), Cloudflare Tunnel (tunnel, with defaultDomain and accountId as for setClusterTraffic) and websites on the tailnet (tailnet: ts.net names and free domains on the servers' Tailscale addresses; the servers stay on the tailnet). Unset fields stay as they are. At least one path stays on. Each domain takes one path, and a domain whose path is off isn't served. When a path turned off still has domains, nothing changes: status is "confirm" and domains lists them, each with outcome "moves" or "stops". Send it again with confirm to go ahead. Turning public ports off with the tunnel on moves the domains in the tunnel's Cloudflare account to the tunnel first (moveToTunnel, on by default), and the ports close once every one of them is on it (status "moving"): its record has moved and Cloudflare has had time to serve it. Published TCP and UDP ports pause for a few seconds when public ports go on or off, as they move between Services. Turning the tunnel off with public ports on switches its domains back first, then removes the tunnel at Cloudflare. dashboardDrops: switching Tailnet drops open connections to Pyo's dashboard on the tailnet once (the cluster Pyo runs on, with ts.net names, until its connect command has run for this release). Team owners and admins.
API key access: full.
op*"setClusterPaths""setClusterPaths"clusterId*stringpublic?boolean|nulltunnel?boolean|nulltailnet?boolean|nullpublicPorts?|TCP and UDP ports on the servers while public ports are off.
proxyProtocol?|Read the visitor's address from a PROXY protocol header on ports 80 and 443. Saving drops open web connections once.
defaultDomain?string|nullaccountId?string|nullmoveToTunnel?boolean|nullrestoreRecords?|With turning the tunnel off: put back the records its domains replaced. On by default.
confirm?booleanDone. Always ok: true, and some operations add more, such as a new API key or a join command. A warning comes with a change that went through but won't fully take effect yet, such as more replicas than the servers have room for.
application/jsoncurl -X POST 'https://your-pyo.example.com/api/v1/ops' \
-H 'Content-Type: application/json' \
-d '{
"clusterId": "cl_8kq2x7ad",
"op": "setClusterPaths"
}'{}