Optional
addrPort, network address, url, or named pipe. Defaults to 80. Examples: "80", "localhost:8080", "https://192.168.1.100:8443", "unix:/tmp/my.sock", "pipe://./my-pipe"
Optional
allow_A set of regular expressions used to match User-Agents that will be allowed.
On request, the User Agent Filter module will check the incoming User-Agent header value
against the list of defined allow and deny regular expression rules.
See User Agent Filter
_ in the ngrok docs for additional details.
.. _User Agent Filter: https://ngrok.com/docs/cloud-edge/modules/user-agent-filter/
Optional
app_The L7 application protocol to use for this edge, e.g. "http2" or "http1".
Optional
authOptional
authtokenConfigures the session to authenticate with the provided authtoken. You can find your existing authtoken or create a new one in the ngrok dashboard.
See the authtoken parameter in the ngrok docs for additional details.
Optional
authtoken_Shortcut for calling [SessionBuilder::authtoken] with the value of the NGROK_AUTHTOKEN environment variable.
Optional
basic_Credentials for basic authentication, with username and password colon separated.
Optional
binUnused, will warn and be ignored
Optional
circuit_Reject requests when 5XX responses exceed this ratio. Disabled when 0. See Circuit Breaker in the ngrok docs for additional details.
Optional
compressionEnable gzip compression for HTTP responses. See Compression in the ngrok docs for additional details.
Optional
configUnused, will warn and be ignored
Optional
crtThe certificate to use for TLS termination at the ngrok edge in PEM format. Only used if "proto" is "tls". See TLS Termination in the ngrok docs for additional details.
Optional
deny_A set of regular expressions used to match User-Agents that will be denied.
On request, the User Agent Filter module will check the incoming User-Agent header value
against the list of defined allow and deny regular expression rules.
See User Agent Filter
_ in the ngrok docs for additional details.
.. _User Agent Filter: https://ngrok.com/docs/cloud-edge/modules/user-agent-filter/
Optional
domainThe domain to request for this edge, any valid domain or hostname that you have previously registered with ngrok. If using a custom domain, this requires registering in the ngrok dashboard and setting a DNS CNAME value.
Optional
force_Force a new session connection to be made.
Optional
forwards_Returns a human-readable string presented in the ngrok dashboard and the API.
Optional
hostThe hostname for the listener to forward to. Only used if addr is not defined.
Optional
host_Unused, will warn and be ignored
Optional
hostnameSynonym for domain
Optional
inspectUnused, will warn and be ignored
Optional
ip_Restriction placed on the origin of incoming connections to the edge to only allow these CIDR ranges.
Optional
ip_Restriction placed on the origin of incoming connections to the edge to deny these CIDR ranges.
Optional
keyThe certificate to use for TLS termination at the ngrok edge in PEM format. Only used if "proto" is "tls". See TLS Termination in the ngrok docs for additional details.
Optional
labelsAdd label, value pairs for this listener, colon separated.
Optional
metadataListener-specific opaque metadata. Viewable via the API.
Optional
mutual_Certificates to use for client authentication at the ngrok edge. Only used if "proto" is "tls" or "http". See Mutual TLS in the ngrok docs for additional details.
Optional
nameUnused, will warn and be ignored
Optional
oauth_OAuth configuration of domains to allow. See OAuth in the ngrok docs for additional details.
Optional
oauth_OAuth configuration of email addresses to allow. See OAuth in the ngrok docs for additional details.
Optional
oauth_OAuth configuration of client ID. Required for scopes. See OAuth in the ngrok docs for additional details.
Optional
oauth_OAuth configuration of client secret. Required for scopes. See OAuth in the ngrok docs for additional details.
Optional
oauth_OAuth configuration of the provider, e.g. "google". See OAuth in the ngrok docs for additional details.
Optional
oauth_OAuth configuration of scopes. See OAuth in the ngrok docs for additional details.
Optional
oidc_OIDC configuration of domains to allow. See OpenID Connect in the ngrok docs for additional details.
Optional
oidc_OIDC configuration of email addresses to allow. See OpenID Connect in the ngrok docs for additional details.
Optional
oidc_OIDC configuration of client ID. See OpenID Connect in the ngrok docs for additional details.
Optional
oidc_OIDC configuration of client secret. See OpenID Connect in the ngrok docs for additional details.
Optional
oidc_OIDC configuration of the issuer URL. See OpenID Connect in the ngrok docs for additional details.
Optional
oidc_OIDC configuration of scopes. See OpenID Connect in the ngrok docs for additional details.
Optional
onReturns log messages from the ngrok library.
Optional
on'closed' - connection is lost, 'connected' - reconnected
Optional
policyDEPRECATED: use TrafficPolicy instead.
Optional
portThe port for the listener to forward to. Only used if addr is not defined.
Optional
protoThe type of listener to use, one of http|tcp|tls|labeled, defaults to http.
Optional
proxy_The version of PROXY protocol to use with this listener "1", "2", or "" if not using.
Optional
regionUnused, will warn and be ignored
Optional
remote_The TCP address to request for this edge. These addresses can be reserved in the ngrok dashboard to use across sessions. For example: remote_addr("2.tcp.ngrok.io:21746") Only used if proto is "tcp".
Optional
request_Adds a header to all requests to this edge. See Request Headers in the ngrok docs for additional details.
Optional
request_Removes a header from requests to this edge. See Request Headers in the ngrok docs for additional details.
Optional
response_Adds a header to all responses coming from this edge. See Response Headers in the ngrok docs for additional details.
Optional
response_Removes a header from responses from this edge. See Response Headers in the ngrok docs for additional details.
Optional
root_Sets the file path to a default certificate in PEM format to validate ngrok Session TLS connections. Setting to "trusted" is the default, using the ngrok CA certificate. Setting to "host" will verify using the certificates on the host operating system. A client config set via tls_config after calling root_cas will override this value.
Corresponds to the root_cas parameter in the ngrok docs
Optional
schemesThe scheme that this edge should use. "HTTPS" or "HTTP", defaults to "HTTPS". If multiple are given only the last one is used.
Optional
server_Configures the network address to dial to connect to the ngrok service. Use this option only if you are connecting to a custom agent ingress.
See the server_addr parameter in the ngrok docs for additional details.
Optional
session_Configures the TLS certificate used to connect to the ngrok service while establishing the session. Use this option only if you are connecting through a man-in-the-middle or deep packet inspection proxy. Pass in the bytes of the certificate to be used to validate the connection, then override the address to connect to via the server_addr call.
Roughly corresponds to the root_cas parameter in the ngrok docs.
Optional
session_Configures the opaque, machine-readable metadata string for this session. Metadata is made available to you in the ngrok dashboard and the Agents API resource. It is a useful way to allow you to uniquely identify sessions. We suggest encoding the value in a structured format like JSON.
See the metdata parameter in the ngrok docs for additional details.
Optional
subdomainUnused, use domain instead, will warn and be ignored
Optional
terminate_Unused, will warn and be ignored
Optional
traffic_The Traffic Policy to use for this endpoint.
Optional
verify_Whether to disable certificate verification for this listener
Optional
verify_WebhookVerification configuration, the provider to use. See Webhook Verification in the ngrok docs for additional details.
Optional
verify_WebhookVerification configuration, the secret to use. See Webhook Verification in the ngrok docs for additional details.
Optional
web_Unused, will warn and be ignored
Optional
websocket_Convert incoming websocket connections to TCP-like streams.
Generated using TypeDoc
Configuration object to pass to ngrok.forward()