Skip to main content

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

   
descriptionstringhuman-readable description of what this reserved address will be used for
metadatastringarbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.
regionstringreserve 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

{
"id": "ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"created_at": "2023-07-31T23:17:18Z",
"description": "SSH for device #001",
"addr": "1.tcp.ngrok.io:20000",
"region": "us",
"endpoint_configuration": null
}

Fields

   
idstringunique reserved address resource identifier
uristringURI of the reserved address API resource
created_atstringtimestamp when the reserved address was created, RFC 3339 format
descriptionstringhuman-readable description of what this reserved address will be used for
metadatastringarbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.
addrstringhostname:port of the reserved address that was assigned at creation time
regionstringreserve 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_2TMGAKbzLCHnh3QXN8iwP7I7cDE

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_2TMGAKbzLCHnh3QXN8iwP7I7cDE

Response

Returns a 200 response on success

Example Response

{
"id": "ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"created_at": "2023-07-31T23:17:18Z",
"description": "SSH for device #001",
"metadata": "{\"proto\": \"ssh\"}",
"addr": "1.tcp.ngrok.io:20000",
"region": "us",
"endpoint_configuration": {
"id": "ec_2TMGGEpgHMgrIttyaddquAacBpB",
"uri": "https://api.ngrok.com/endpoint_configurations/ec_2TMGGEpgHMgrIttyaddquAacBpB"
}
}

Fields

   
idstringunique reserved address resource identifier
uristringURI of the reserved address API resource
created_atstringtimestamp when the reserved address was created, RFC 3339 format
descriptionstringhuman-readable description of what this reserved address will be used for
metadatastringarbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.
addrstringhostname:port of the reserved address that was assigned at creation time
regionstringreserve 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

{
"reserved_addrs": [
{
"id": "ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"created_at": "2023-07-31T23:17:18Z",
"description": "SSH for device #001",
"addr": "1.tcp.ngrok.io:20000",
"region": "us",
"endpoint_configuration": null
}
],
"uri": "https://api.ngrok.com/reserved_addrs",
"next_page_uri": null
}

Fields

   
reserved_addrsReservedAddrthe list of all reserved addresses on this account
uristringURI of the reserved address list API resource
next_page_uristringURI of the next page, or null if there is no next page

ReservedAddr fields

   
idstringunique reserved address resource identifier
uristringURI of the reserved address API resource
created_atstringtimestamp when the reserved address was created, RFC 3339 format
descriptionstringhuman-readable description of what this reserved address will be used for
metadatastringarbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.
addrstringhostname:port of the reserved address that was assigned at creation time
regionstringreserve 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 '{"metadata":"{\"proto\": \"ssh\"}","endpoint_configuration_id":"ec_2TMGGEpgHMgrIttyaddquAacBpB"}' \
https://api.ngrok.com/reserved_addrs/ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE

Parameters

   
idstring
descriptionstringhuman-readable description of what this reserved address will be used for
metadatastringarbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.

Response

Returns a 200 response on success

Example Response

{
"id": "ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"uri": "https://api.ngrok.com/reserved_addrs/ra_2TMGAKbzLCHnh3QXN8iwP7I7cDE",
"created_at": "2023-07-31T23:17:18Z",
"description": "SSH for device #001",
"metadata": "{\"proto\": \"ssh\"}",
"addr": "1.tcp.ngrok.io:20000",
"region": "us",
"endpoint_configuration": {
"id": "ec_2TMGGEpgHMgrIttyaddquAacBpB",
"uri": "https://api.ngrok.com/endpoint_configurations/ec_2TMGGEpgHMgrIttyaddquAacBpB"
}
}

Fields

   
idstringunique reserved address resource identifier
uristringURI of the reserved address API resource
created_atstringtimestamp when the reserved address was created, RFC 3339 format
descriptionstringhuman-readable description of what this reserved address will be used for
metadatastringarbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.
addrstringhostname:port of the reserved address that was assigned at creation time
regionstringreserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa)