OAuth2ServerSettings

class OAuth2ServerSettings(name: String, authorizeUrl: String, accessTokenUrl: String, requestMethod: HttpMethod, clientId: String, clientSecret: String, defaultScopes: List<String>, accessTokenRequiresBasicAuth: Boolean, nonceManager: NonceManager, authorizeUrlInterceptor: URLBuilder.() -> Unit, passParamsInURL: Boolean, accessTokenInterceptor: HttpRequestBuilder.() -> Unit) : OAuthServerSettings

OAuth2 server settings

Constructors

Link copied to clipboard
fun OAuth2ServerSettings(name: String, authorizeUrl: String, accessTokenUrl: String, requestMethod: HttpMethod = HttpMethod.Get, clientId: String, clientSecret: String, defaultScopes: List<String> = emptyList(), accessTokenRequiresBasicAuth: Boolean = false, nonceManager: NonceManager = GenerateOnlyNonceManager, authorizeUrlInterceptor: URLBuilder.() -> Unit = {}, passParamsInURL: Boolean = false)
Link copied to clipboard
fun OAuth2ServerSettings(name: String, authorizeUrl: String, accessTokenUrl: String, requestMethod: HttpMethod = HttpMethod.Get, clientId: String, clientSecret: String, defaultScopes: List<String> = emptyList(), accessTokenRequiresBasicAuth: Boolean = false, nonceManager: NonceManager = GenerateOnlyNonceManager, authorizeUrlInterceptor: URLBuilder.() -> Unit = {}, passParamsInURL: Boolean = false, accessTokenInterceptor: HttpRequestBuilder.() -> Unit = {})

Properties

Link copied to clipboard
val accessTokenInterceptor: HttpRequestBuilder.() -> Unit

an interceptor function to customize access token request

Link copied to clipboard
val accessTokenRequiresBasicAuth: Boolean = false

to send BASIC auth header when an access token is requested

Link copied to clipboard
val accessTokenUrl: String

OAuth server access token request URL

Link copied to clipboard
val authorizeUrl: String

OAuth server authorization page URL

Link copied to clipboard
val authorizeUrlInterceptor: URLBuilder.() -> Unit

an interceptor function to customize authorization URL

Link copied to clipboard
val clientId: String

client id parameter (provided by OAuth server vendor)

Link copied to clipboard
val clientSecret: String

client secret parameter (provided by OAuth server vendor)

Link copied to clipboard
val defaultScopes: List<String>

OAuth scopes used by default

Link copied to clipboard
val name: String

configuration name

Link copied to clipboard
val nonceManager: NonceManager

to be used to produce and verify nonce values

Link copied to clipboard
val passParamsInURL: Boolean = false

whether to pass request parameters in POST requests in URL instead of body.

Link copied to clipboard
val requestMethod: HttpMethod

HTTP request method to be used to acquire access token (see vendors documentation)

Link copied to clipboard
val version: OAuthVersion

OAuth version (1a or 2)