Overview
Create and manage secure tunnels (ngrok, Cloudflare Tunnel, custom) to expose OmniRoute to the internet or share access with remote agents and CI pipelines.
Authentication
All requests require a valid Bearer token or session cookie. Obtain a token via POST /api/auth/login or configure REQUIRE_API_KEY=false for local development.
Endpoints
GET /api/tunnels/cloudflared
GET tunnels › cloudflared
curl http://localhost:20128/api/tunnels/cloudflared \
-H "Authorization: Bearer $OMNIROUTE_TOKEN"
POST /api/tunnels/cloudflared
POST tunnels › cloudflared
curl -X POST http://localhost:20128/api/tunnels/cloudflared \
-H "Authorization: Bearer $OMNIROUTE_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
GET /api/tunnels/ngrok
GET tunnels › ngrok
curl http://localhost:20128/api/tunnels/ngrok \
-H "Authorization: Bearer $OMNIROUTE_TOKEN"
POST /api/tunnels/ngrok
POST tunnels › ngrok
curl -X POST http://localhost:20128/api/tunnels/ngrok \
-H "Authorization: Bearer $OMNIROUTE_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
GET /api/tunnels/tailscale
GET tunnels › tailscale
curl http://localhost:20128/api/tunnels/tailscale \
-H "Authorization: Bearer $OMNIROUTE_TOKEN"
GET /api/tunnels/tailscale/check
GET tunnels › tailscale › check
curl http://localhost:20128/api/tunnels/tailscale/check \
-H "Authorization: Bearer $OMNIROUTE_TOKEN"
POST /api/tunnels/tailscale/disable
POST tunnels › tailscale › disable
curl -X POST http://localhost:20128/api/tunnels/tailscale/disable \
-H "Authorization: Bearer $OMNIROUTE_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
POST /api/tunnels/tailscale/enable
POST tunnels › tailscale › enable
curl -X POST http://localhost:20128/api/tunnels/tailscale/enable \
-H "Authorization: Bearer $OMNIROUTE_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
POST /api/tunnels/tailscale/install
POST tunnels › tailscale › install
curl -X POST http://localhost:20128/api/tunnels/tailscale/install \
-H "Authorization: Bearer $OMNIROUTE_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
POST /api/tunnels/tailscale/login
POST tunnels › tailscale › login
curl -X POST http://localhost:20128/api/tunnels/tailscale/login \
-H "Authorization: Bearer $OMNIROUTE_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
POST /api/tunnels/tailscale/start-daemon
POST tunnels › tailscale › start daemon
curl -X POST http://localhost:20128/api/tunnels/tailscale/start-daemon \
-H "Authorization: Bearer $OMNIROUTE_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
Payloads
See the full OpenAPI specification at GET /api/openapi/spec or docs/openapi.yaml for detailed request/response schemas.
