Edges HTTPS Routes
Create HTTPS Edge Route
Create an HTTPS Edge Route
Request
POST /edges/https/{edge_id}/routes
Example Request
Loading…
Parameters
Name | Type | Description |
---|---|---|
edge_id | string | unique identifier of this edge |
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" |
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 | EndpointBackendMutate | backend module configuration or null |
ip_restriction | EndpointIPPolicyMutate | 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 | EndpointSAMLMutate | 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 | |
traffic_policy | EndpointTrafficPolicy | the traffic policy associated with this edge or null |
EndpointBackendMutate parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
backend_id | string | backend to be used to back this endpoint |
EndpointIPPolicyMutate parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
ip_policy_ids | List<string> | list of all IP policies that will be used to check if a source IP is allowed access to the endpoint |
EndpointCircuitBreaker parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
tripped_duration | uint32 | Integer number of seconds after which the circuit is tripped to wait before re-evaluating upstream health |
rolling_window | uint32 | Integer number of seconds in the statistical rolling window that metrics are retained for. |
num_buckets | uint32 | Integer number of buckets into which metrics are retained. Max 128. |
volume_threshold | uint32 | Integer number of requests in a rolling window that will trip the circuit. Helpful if traffic volume is low. |
error_threshold_percentage | float64 | Error threshold percentage should be between 0 - 1.0, not 0-100.0 |
EndpointCompression parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
EndpointRequestHeaders parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
add | Map<string, string> | a map of header key to header value that will be injected into the HTTP Request before being sent to the upstream application server |
remove | List<string> | a list of header names that will be removed from the HTTP Request before being sent to the upstream application server |
EndpointResponseHeaders parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
add | Map<string, string> | a map of header key to header value that will be injected into the HTTP Response returned to the HTTP client |
remove | List<string> | a list of header names that will be removed from the HTTP Response returned to the HTTP client |
EndpointWebhookValidation parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
provider | string | a string indicating which webhook provider will be sending webhooks to this endpoint. Value must be one of the supported providers defined at https://ngrok.com/docs/cloud-edge/modules/webhook-verification |
secret | string | a string secret used to validate requests from the given provider. All providers except AWS SNS require a secret |
EndpointOAuth parameters
Name | Type | Description |
---|---|---|
enabled | boolean | true if the module will be applied to traffic, false to disable. default true if unspecified |
provider | EndpointOAuthProvider | an object which defines the identity provider to use for authentication and configuration for who may access the endpoint |
options_passthrough | boolean | Do not enforce authentication on HTTP OPTIONS requests. necessary if you are supporting CORS. |
cookie_prefix | string | the prefix of the session cookie that ngrok sets on the http client to cache authentication. default is 'ngrok.' |
inactivity_timeout | uint32 | Integer number of seconds of inactivity after which if the user has not accessed the endpoint, their session will time out and they will be forced to reauthenticate. |
maximum_duration | uint32 | Integer number of seconds of the maximum duration of an authenticated session. After this period is exceeded, a user must reauthenticate. |
auth_check_interval | uint32 | Integer number of seconds after which ngrok guarantees it will refresh user state from the identity provider and recheck whether the user is still authorized to access the endpoint. This is the preferred tunable to use to enforce a minimum amount of time after which a revoked user will no longer be able to access the resource. |
EndpointOAuthProvider parameters
Name | Type | Description |
---|---|---|
github | EndpointOAuthGitHub | configuration for using github as the identity provider |
facebook | EndpointOAuthFacebook | configuration for using facebook as the identity provider |
microsoft | EndpointOAuthMicrosoft | configuration for using microsoft as the identity provider |
google | EndpointOAuthGoogle | configuration for using google as the identity provider |
linkedin | EndpointOAuthLinkedIn | configuration for using linkedin as the identity provider |
gitlab | EndpointOAuthGitLab | configuration for using gitlab as the identity provider |
twitch | EndpointOAuthTwitch | configuration for using twitch as the identity provider |
amazon | EndpointOAuthAmazon | configuration for using amazon as the identity provider |
EndpointOAuthGitHub parameters
Name | Type | Description |
---|---|---|
client_id | string | the OAuth app client ID. retrieve it from the identity provider's dashboard where you created your own OAuth app. optional. if unspecified, ngrok will use its own managed oauth application which has additional restrictions. see the OAuth module docs for more details. if present, client_secret must be present as well. |
client_secret | string | the OAuth app client secret. retrieve if from the identity provider's dashboard where you created your own OAuth app. optional, see all of the caveats in the docs for client_id . |
scopes | List<string> | a list of provider-specific OAuth scopes with the permissions your OAuth app would like to ask for. these may not be set if you are using the ngrok-managed oauth app (i.e. you must pass both client_id and client_secret to set scopes) |
email_addresses | List<string> | a list of email addresses of users authenticated by identity provider who are allowed access to the endpoint |
email_domains | List<string> | a list of email domains of users authenticated by identity provider who are allowed access to the endpoint |
teams | List<string> | a list of github teams identifiers. users will be allowed access to the endpoint if they are a member of any of these teams. identifiers should be in the 'slug' format qualified with the org name, e.g. org-name/team-name |
organizations | List<string> | a list of github org identifiers. users who are members of any of the listed organizations will be allowed access. identifiers should be the organization's 'slug' |
EndpointOAuthFacebook parameters
Name | Type | Description |
---|---|---|
client_id | string | the OAuth app client ID. retrieve it from the identity provider's dashboard where you created your own OAuth app. optional. if unspecified, ngrok will use its own managed oauth application which has additional restrictions. see the OAuth module docs for more details. if present, client_secret must be present as well. |
client_secret | string | the OAuth app client secret. retrieve if from the identity provider's dashboard where you created your own OAuth app. optional, see all of the caveats in the docs for client_id . |
scopes | List<string> | a list of provider-specific OAuth scopes with the permissions your OAuth app would like to ask for. these may not be set if you are using the ngrok-managed oauth app (i.e. you must pass both client_id and client_secret to set scopes) |
email_addresses | List<string> | a list of email addresses of users authenticated by identity provider who are allowed access to the endpoint |
email_domains | List<string> | a list of email domains of users authenticated by identity provider who are allowed access to the endpoint |
EndpointOAuthMicrosoft parameters
Name | Type | Description |
---|---|---|
client_id | string | the OAuth app client ID. retrieve it from the identity provider's dashboard where you created your own OAuth app. optional. if unspecified, ngrok will use its own managed oauth application which has additional restrictions. see the OAuth module docs for more details. if present, client_secret must be present as well. |
client_secret | string | the OAuth app client secret. retrieve if from the identity provider's dashboard where you created your own OAuth app. optional, see all of the caveats in the docs for client_id . |
scopes | List<string> | a list of provider-specific OAuth scopes with the permissions your OAuth app would like to ask for. these may not be set if you are using the ngrok-managed oauth app (i.e. you must pass both client_id and client_secret to set scopes) |
email_addresses | List<string> | a list of email addresses of users authenticated by identity provider who are allowed access to the endpoint |
email_domains | List<string> | a list of email domains of users authenticated by identity provider who are allowed access to the endpoint |
EndpointOAuthGoogle parameters
Name | Type | Description |
---|---|---|
client_id | string | the OAuth app client ID. retrieve it from the identity provider's dashboard where you created your own OAuth app. optional. if unspecified, ngrok will use its own managed oauth application which has additional restrictions. see the OAuth module docs for more details. if present, client_secret must be present as well. |
client_secret | string | the OAuth app client secret. retrieve if from the identity provider's dashboard where you created your own OAuth app. optional, see all of the caveats in the docs for client_id . |
scopes | List<string> | a list of provider-specific OAuth scopes with the permissions your OAuth app would like to ask for. these may not be set if you are using the ngrok-managed oauth app (i.e. you must pass both client_id and client_secret to set scopes) |
email_addresses | List<string> | a list of email addresses of users authenticated by identity provider who are allowed access to the endpoint |
email_domains | List<string> | a list of email domains of users authenticated by identity provider who are allowed access to the endpoint |
EndpointOAuthLinkedIn parameters
Name | Type | Description |
---|---|---|
client_id | string | |
client_secret | string | |
scopes | List<string> | |
email_addresses | List<string> | |
email_domains | List<string> |
EndpointOAuthGitLab parameters
Name | Type | Description |
---|---|---|
client_id | string | |
client_secret | string | |
scopes | List<string> | |
email_addresses | List<string> | |
email_domains | List<string> |
EndpointOAuthTwitch parameters
Name | Type | Description |
---|---|---|
client_id | string | |
client_secret | string | |
scopes | List<string> | |
email_addresses | List<string> | |
email_domains | List<string> |