Api operations

This commit is contained in:
BuildTools
2020-11-04 16:58:26 +01:00
parent b308373062
commit 4818905422
7 changed files with 15 additions and 3 deletions

@ -14,6 +14,7 @@ import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
@RestController
@CrossOrigin
@ -26,6 +27,7 @@ public class TokenController {
private UserService userService;
@GetMapping("/token")
@ApiOperation(value = "Endpoint to access token required to call secured endpoints. In order to access token we need to provide access token comming from unviersity CAS system")
public ResponseEntity<String> getToken(@RequestParam("ticket") final String ticket) {
final CasValidator validator = new CasValidator(SERVICE_URL, ticket);