docs/en/docs/rules/tunnel.md
Forward tunnel proxy requests to the new server.
Only supports tunnel proxy
tunnel://domain:port, not WebSocket requests or regular HTTP/HTTPS conversion.
pattern tunnel://value [filters...]
| Parameters | Description | Detailed Documentation |
|---|---|---|
| pattern | Expression to match WebSocket request URLs | Match Pattern Documentation |
| value | Target URL format: domain[:port] | |
port defaults to 443 | ||
| ⚠️ Loading data from files/remote URLs is not supported | Operation Instruction Documentation | |
| filters | Optional filters, supports matching: | |
| • Request URL/Method/Headers/Content | ||
| • Response Status Code/Headers | Filter Documentation |
tunnel://www.example.com tunnel://www.test.com:5678
tunnel://www.example2.com:8080 tunnel://www.test.com
| Original Request | Transformation Result |
|---|---|
tunnel://www.example.com:443 | tunnel://www.test.com:5678 |
tunnel://www.example2.com:8080 | tunnel://www.test.com:443 |
TUNNEL requests do not have automatic path splicing and path splicing is disabled. Other requests matching the tunnel protocol result:
502 error