Package com.ngrok.definitions
Class EndpointOAuth.Builder
java.lang.Object
com.ngrok.definitions.EndpointOAuth.Builder
- Enclosing class:
- EndpointOAuth
Builder class for
EndpointOAuth
.-
Method Summary
Modifier and TypeMethodDescriptionauthCheckInterval
(long authCheckInterval) 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.authCheckInterval
(Optional<Long> authCheckInterval) 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.build()
Constructs theEndpointOAuth
instance.cookiePrefix
(String cookiePrefix) the prefix of the session cookie that ngrok sets on the http client to cache authentication.cookiePrefix
(Optional<String> cookiePrefix) the prefix of the session cookie that ngrok sets on the http client to cache authentication.enabled
(boolean enabled) true
if the module will be applied to traffic,false
to disable.true
if the module will be applied to traffic,false
to disable.inactivityTimeout
(long inactivityTimeout) 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.inactivityTimeout
(Optional<Long> inactivityTimeout) 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.maximumDuration
(Duration maximumDuration) Integer number of seconds of the maximum duration of an authenticated session.maximumDuration
(Optional<Duration> maximumDuration) Integer number of seconds of the maximum duration of an authenticated session.optionsPassthrough
(boolean optionsPassthrough) Do not enforce authentication on HTTP OPTIONS requests.optionsPassthrough
(Optional<Boolean> optionsPassthrough) Do not enforce authentication on HTTP OPTIONS requests.provider
(EndpointOAuthProvider provider) an object which defines the identity provider to use for authentication and configuration for who may access the endpointprovider
(Optional<EndpointOAuthProvider> provider) an object which defines the identity provider to use for authentication and configuration for who may access the endpoint
-
Method Details
-
enabled
true
if the module will be applied to traffic,false
to disable. defaulttrue
if unspecified- Parameters:
enabled
- the value of theenabled
parameter as aboolean
- Returns:
- this builder instance
-
enabled
true
if the module will be applied to traffic,false
to disable. defaulttrue
if unspecified- Parameters:
enabled
- the value of theenabled
parameter as aboolean
, wrapped in anOptional
- Returns:
- this builder instance
-
provider
an object which defines the identity provider to use for authentication and configuration for who may access the endpoint- Parameters:
provider
- the value of theprovider
parameter as aEndpointOAuthProvider
- Returns:
- this builder instance
-
provider
an object which defines the identity provider to use for authentication and configuration for who may access the endpoint- Parameters:
provider
- the value of theprovider
parameter as aEndpointOAuthProvider
, wrapped in anOptional
- Returns:
- this builder instance
-
optionsPassthrough
Do not enforce authentication on HTTP OPTIONS requests. necessary if you are supporting CORS.- Parameters:
optionsPassthrough
- the value of theoptions_passthrough
parameter as aboolean
- Returns:
- this builder instance
-
optionsPassthrough
Do not enforce authentication on HTTP OPTIONS requests. necessary if you are supporting CORS.- Parameters:
optionsPassthrough
- the value of theoptions_passthrough
parameter as aboolean
, wrapped in anOptional
- Returns:
- this builder instance
-
cookiePrefix
the prefix of the session cookie that ngrok sets on the http client to cache authentication. default is 'ngrok.'- Parameters:
cookiePrefix
- the value of thecookie_prefix
parameter as aString
- Returns:
- this builder instance
-
cookiePrefix
the prefix of the session cookie that ngrok sets on the http client to cache authentication. default is 'ngrok.' -
inactivityTimeout
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.- Parameters:
inactivityTimeout
- the value of theinactivity_timeout
parameter as along
- Returns:
- this builder instance
-
inactivityTimeout
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.- Parameters:
inactivityTimeout
- the value of theinactivity_timeout
parameter as along
, wrapped in anOptional
- Returns:
- this builder instance
-
maximumDuration
Integer number of seconds of the maximum duration of an authenticated session. After this period is exceeded, a user must reauthenticate.- Parameters:
maximumDuration
- the value of themaximum_duration
parameter as aDuration
- Returns:
- this builder instance
-
maximumDuration
Integer number of seconds of the maximum duration of an authenticated session. After this period is exceeded, a user must reauthenticate. -
authCheckInterval
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.- Parameters:
authCheckInterval
- the value of theauth_check_interval
parameter as along
- Returns:
- this builder instance
-
authCheckInterval
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.- Parameters:
authCheckInterval
- the value of theauth_check_interval
parameter as along
, wrapped in anOptional
- Returns:
- this builder instance
-
build
Constructs theEndpointOAuth
instance.- Returns:
- a new
EndpointOAuth
-