Class WelcomeController
java.lang.Object
com.okta.spring.example.controllers.WelcomeController
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetMessageOfTheDay
(Principal principal) Simple example REST endpoint that returns a static message.
-
Constructor Details
-
WelcomeController
public WelcomeController()
-
-
Method Details
-
getMessageOfTheDay
@GetMapping("/welcome") @PreAuthorize("hasAuthority(\'SCOPE_email\')") public WelcomeController.Welcome getMessageOfTheDay(Principal principal) Simple example REST endpoint that returns a static message. This controller also serves as an example for checking an OAuth scope and client roles (parsed from an access token).- Returns:
- a static welcome message
-