Tunnels
List Tunnels
List all online tunnels currently running on the account.
Request
GET /tunnels
Example Request
curl \
-X GET \
-H "Authorization: Bearer {API_KEY}" \
-H "Ngrok-Version: 2" \
https://api.ngrok.com/tunnels
Response
Returns a 200 response on success
Example Response
{
"next_page_uri": null,
"tunnels": [
{
"endpoint": {
"id": "ep_2na2JAD0UFlf8ok8xugXdiq85bj",
"uri": "https://api.ngrok.com/endpoints/ep_2na2JAD0UFlf8ok8xugXdiq85bj"
},
"forwards_to": "http://localhost:80",
"id": "tn_2na2JAD0UFlf8ok8xugXdiq85bj",
"proto": "https",
"public_url": "https://12e848c1f74e.ngrok.paid",
"region": "us",
"started_at": "2024-10-17T20:26:31Z",
"tunnel_session": {
"id": "ts_2na2JAw7W7P25FYH2EvvkLSyesJ",
"uri": "https://api.ngrok.com/tunnel_sessions/ts_2na2JAw7W7P25FYH2EvvkLSyesJ"
}
},
{
"forwards_to": "http://localhost:80",
"id": "tn_2na2IcFurydSHExOgvv7vKB3vOc",
"labels": {
"baz": "qux",
"foo": "bar"
},
"region": "us",
"started_at": "2024-10-17T20:26:27Z",
"tunnel_session": {
"id": "ts_2na2IeLxkx9rHVDmPSWWgFAy9wd",
"uri": "https://api.ngrok.com/tunnel_sessions/ts_2na2IeLxkx9rHVDmPSWWgFAy9wd"
}
}
],
"uri": "https://api.ngrok.com/tunnels"
}
Fields
Name | Type | Description |
---|---|---|
tunnels | Tunnel | the list of all online tunnels on this account |
uri | string | URI of the tunnels list API resource |
next_page_uri | string | URI of the next page, or null if there is no next page |