Interface OauthController
-
- All Known Implementing Classes:
DefaultOauthController
@Secured("isAnonymous()") public interface OauthControllerResponsible for OAuth 2.0 authorization redirect, authorization callback, and end session redirects. Each controller is associated with a singleOauthClient.- Since:
- 1.2.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.reactivestreams.Publisher<io.micronaut.http.MutableHttpResponse<?>>callback(io.micronaut.http.HttpRequest<java.util.Map<java.lang.String,java.lang.Object>> request)Receives the authorization callback from the OAuth 2.0 provider and responds to the user.OauthClientgetClient()org.reactivestreams.Publisher<io.micronaut.http.MutableHttpResponse<?>>login(io.micronaut.http.HttpRequest<?> request)Performs an authorization redirect to an OAuth 2.0 provider.
-
-
-
Method Detail
-
getClient
OauthClient getClient()
- Returns:
- The client associated with this controller
-
login
@Executable @SingleResult org.reactivestreams.Publisher<io.micronaut.http.MutableHttpResponse<?>> login(io.micronaut.http.HttpRequest<?> request)
Performs an authorization redirect to an OAuth 2.0 provider.- Parameters:
request- The current request- Returns:
- A redirecting http response
-
callback
@Executable @SingleResult org.reactivestreams.Publisher<io.micronaut.http.MutableHttpResponse<?>> callback(io.micronaut.http.HttpRequest<java.util.Map<java.lang.String,java.lang.Object>> request)
Receives the authorization callback from the OAuth 2.0 provider and responds to the user.- Parameters:
request- The current request- Returns:
- A response
-
-