Edges HTTPS
Create HTTPS Edge
Create an HTTPS Edge
Request
POST /edges/https
Example Request
curl \
-X POST \
-H "Authorization: Bearer {API_KEY}" \
-H "Content-Type: application/json" \
-H "Ngrok-Version: 2" \
-d '{"description":"acme https edge","hostports":["example.com:443"],"metadata":"{\"environment\": \"staging\"}"}' \
https://api.ngrok.com/edges/https
Parameters
Name | Type | Description |
---|---|---|
description | string | human-readable description of what this edge will be used for; optional, max 255 bytes. |
metadata | string | arbitrary user-defined machine-readable data of this edge; optional, max 4096 bytes. |
hostports | List<string> | hostports served by this edge |
mutual_tls | EndpointMutualTLSMutate | edge modules |
tls_termination | EndpointTLSTerminationAtEdge |
EndpointMutualTLSMutate parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
certificate_authority_ids | List<string> | list of certificate authorities that will be used to validate the TLS client certificate presented by the initiator of the TLS connection |
EndpointTLSTerminationAtEdge parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
min_version | string | The minimum TLS version used for termination and advertised to the client during the TLS handshake. if unspecified, ngrok will choose an industry-safe default. This value must be null if terminate_at is set to upstream . |
Response
Returns a 201 response on success
Example Response
{
"created_at": "2024-02-16T19:35:32Z",
"description": "acme https edge",
"hostports": ["example.com:443"],
"id": "edghts_2cSjz2XRGVbxhRvpCPZ5SMCyxS0",
"metadata": "{\"environment\": \"staging\"}",
"mutual_tls": null,
"routes": [],
"tls_termination": null,
"uri": "https://api.ngrok.com/edges/https/edghts_2cSjz2XRGVbxhRvpCPZ5SMCyxS0"
}
Fields
Name | Type | Description |
---|---|---|
id | string | unique identifier of this edge |
description | string | human-readable description of what this edge will be used for; optional, max 255 bytes. |
metadata | string | arbitrary user-defined machine-readable data of this edge; optional, max 4096 bytes. |
created_at | string | timestamp when the edge configuration was created, RFC 3339 format |
uri | string | URI of the edge API resource |
hostports | List<string> | hostports served by this edge |
mutual_tls | EndpointMutualTLS | edge modules |
tls_termination | EndpointTLSTermination | |
routes | HTTPSEdgeRoute | routes |
EndpointMutualTLS fields
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
certificate_authorities | Ref | PEM-encoded CA certificates that will be used to validate. Multiple CAs may be provided by concatenating them together. |
Ref fields
Name | Type | Description |
---|---|---|
id | string | a resource identifier |
uri | string | a uri for locating a resource |
EndpointTLSTermination fields
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
terminate_at | string | edge if the ngrok edge should terminate TLS traffic, upstream if TLS traffic should be passed through to the upstream ngrok agent / application server for termination. if upstream is chosen, most other modules will be disallowed because they rely on the ngrok edge being able to access the underlying traffic. |
min_version | string | The minimum TLS version used for termination and advertised to the client during the TLS handshake. if unspecified, ngrok will choose an industry-safe default. This value must be null if terminate_at is set to upstream . |
HTTPSEdgeRoute fields
Name | Type | Description |
---|---|---|
edge_id | string | unique identifier of this edge |
id | string | unique identifier of this edge route |
created_at | string | timestamp when the edge configuration was created, RFC 3339 format |
match_type | string | Type of match to use for this route. Valid values are "exact_path" and "path_prefix". |
match | string | Route selector: "/blog" or "example.com" or "example.com/blog" |
uri | string | URI of the edge API resource |
description | string | human-readable description of what this edge will be used for; optional, max 255 bytes. |
metadata | string | arbitrary user-defined machine-readable data of this edge. Optional, max 4096 bytes. |
backend | EndpointBackend | backend module configuration or null |
ip_restriction | EndpointIPPolicy | ip restriction module configuration or null |
circuit_breaker | EndpointCircuitBreaker | circuit breaker module configuration or null |
compression | EndpointCompression | compression module configuration or null |
request_headers | EndpointRequestHeaders | request headers module configuration or null |
response_headers | EndpointResponseHeaders | response headers module configuration or null |
webhook_verification | EndpointWebhookValidation | webhook verification module configuration or null |
oauth | EndpointOAuth | oauth module configuration or null |
saml | EndpointSAML | saml module configuration or null |
oidc | EndpointOIDC | oidc module configuration or null |
websocket_tcp_converter | EndpointWebsocketTCPConverter | websocket to tcp adapter configuration or null |
user_agent_filter | EndpointUserAgentFilter | |
policy | EndpointPolicy | the traffic policy associated with this edge or null |
EndpointBackend fields
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
backend | Ref | backend to be used to back this endpoint |
EndpointIPPolicy fields
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
ip_policies | Ref | list of all IP policies that will be used to check if a source IP is allowed access to the endpoint |