Reserved Addrs
Create Reserved Address
Create a new reserved address.
Request
POST /reserved_addrs
Example Request
curl \
-X POST \
-H "Authorization: Bearer {API_KEY}" \
-H "Content-Type: application/json" \
-H "Ngrok-Version: 2" \
-d '{"description":"SSH for device #001","region":"us"}' \
https://api.ngrok.com/reserved_addrs
Parameters
Name | Type | Description |
---|---|---|
description | string | human-readable description of what this reserved address will be used for |
metadata | string | arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes. |
region | string | reserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa) |
Response
Returns a 201 response on success
Example Response
{
"addr": "1.tcp.ngrok.io:20000",
"created_at": "2024-08-02T07:15:17Z",
"description": "SSH for device #001",
"endpoint_configuration": null,
"id": "ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ",
"region": "us",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ"
}
Fields
Name | Type | Description |
---|---|---|
id | string | unique reserved address resource identifier |
uri | string | URI of the reserved address API resource |
created_at | string | timestamp when the reserved address was created, RFC 3339 format |
description | string | human-readable description of what this reserved address will be used for |
metadata | string | arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes. |
addr | string | hostname:port of the reserved address that was assigned at creation time |
region | string | reserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa) |
Delete Reserved Address
Delete a reserved address.
Request
DELETE /reserved_addrs/{id}
Example Request
curl \
-X DELETE \
-H "Authorization: Bearer {API_KEY}" \
-H "Ngrok-Version: 2" \
https://api.ngrok.com/reserved_addrs/ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ
Response
Returns a 204 response with no body on success
Get Reserved Address
Get the details of a reserved address.
Request
GET /reserved_addrs/{id}
Example Request
curl \
-X GET \
-H "Authorization: Bearer {API_KEY}" \
-H "Ngrok-Version: 2" \
https://api.ngrok.com/reserved_addrs/ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ
Response
Returns a 200 response on success
Example Response
{
"addr": "1.tcp.ngrok.io:20000",
"created_at": "2024-08-02T07:15:17Z",
"description": "SSH for device #001",
"endpoint_configuration": {
"id": "ec_2k5ohWgRIz0NJXWgRY8PmCgW3Qw",
"uri": "https://api.ngrok.com/endpoint_configurations/ec_2k5ohWgRIz0NJXWgRY8PmCgW3Qw"
},
"id": "ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ",
"metadata": "{\"proto\": \"ssh\"}",
"region": "us",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ"
}
Fields
Name | Type | Description |
---|---|---|
id | string | unique reserved address resource identifier |
uri | string | URI of the reserved address API resource |
created_at | string | timestamp when the reserved address was created, RFC 3339 format |
description | string | human-readable description of what this reserved address will be used for |
metadata | string | arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes. |
addr | string | hostname:port of the reserved address that was assigned at creation time |
region | string | reserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa) |
List Reserved Addresses
List all reserved addresses on this account.
Request
GET /reserved_addrs
Example Request
curl \
-X GET \
-H "Authorization: Bearer {API_KEY}" \
-H "Ngrok-Version: 2" \
https://api.ngrok.com/reserved_addrs
Response
Returns a 200 response on success
Example Response
{
"next_page_uri": null,
"reserved_addrs": [
{
"addr": "1.tcp.ngrok.io:20000",
"created_at": "2024-08-02T07:15:17Z",
"description": "SSH for device #001",
"endpoint_configuration": null,
"id": "ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ",
"region": "us",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ"
}
],
"uri": "https://api.ngrok.com/reserved_addrs"
}
Fields
Name | Type | Description |
---|---|---|
reserved_addrs | ReservedAddr | the list of all reserved addresses on this account |
uri | string | URI of the reserved address list API resource |
next_page_uri | string | URI of the next page, or null if there is no next page |
ReservedAddr fields
Name | Type | Description |
---|---|---|
id | string | unique reserved address resource identifier |
uri | string | URI of the reserved address API resource |
created_at | string | timestamp when the reserved address was created, RFC 3339 format |
description | string | human-readable description of what this reserved address will be used for |
metadata | string | arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes. |
addr | string | hostname:port of the reserved address that was assigned at creation time |
region | string | reserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa) |
Update Reserved Address
Update the attributes of a reserved address.
Request
PATCH /reserved_addrs/{id}
Example Request
curl \
-X PATCH \
-H "Authorization: Bearer {API_KEY}" \
-H "Content-Type: application/json" \
-H "Ngrok-Version: 2" \
-d '{"endpoint_configuration_id":"ec_2k5ohWgRIz0NJXWgRY8PmCgW3Qw","metadata":"{\"proto\": \"ssh\"}"}' \
https://api.ngrok.com/reserved_addrs/ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ
Parameters
Name | Type | Description |
---|---|---|
id | string | |
description | string | human-readable description of what this reserved address will be used for |
metadata | string | arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes. |
Response
Returns a 200 response on success
Example Response
{
"addr": "1.tcp.ngrok.io:20000",
"created_at": "2024-08-02T07:15:17Z",
"description": "SSH for device #001",
"endpoint_configuration": {
"id": "ec_2k5ohWgRIz0NJXWgRY8PmCgW3Qw",
"uri": "https://api.ngrok.com/endpoint_configurations/ec_2k5ohWgRIz0NJXWgRY8PmCgW3Qw"
},
"id": "ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ",
"metadata": "{\"proto\": \"ssh\"}",
"region": "us",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2k5ohSKOO5dZdoSTnFLGt0w98cJ"
}
Fields
Name | Type | Description |
---|---|---|
id | string | unique reserved address resource identifier |
uri | string | URI of the reserved address API resource |
created_at | string | timestamp when the reserved address was created, RFC 3339 format |
description | string | human-readable description of what this reserved address will be used for |
metadata | string | arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes. |
addr | string | hostname:port of the reserved address that was assigned at creation time |
region | string | reserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa) |