use of org.gluu.oxtrust.api.server.model.OxAuthJsonConfiguration in project oxTrust by GluuFederation.
the class OxAuthJsonSettingWebResource method getOxAuthJsonSettings.
@GET
@Operation(summary = "Get json oxauth settings", description = "Gets oxAuth configuration in JSON format", responses = { @ApiResponse(responseCode = "200", content = @Content(schema = @Schema(implementation = OxAuthJsonConfiguration.class)), description = Constants.RESULT_SUCCESS), @ApiResponse(responseCode = "500", description = "Server error") })
@ProtectedApi(scopes = { READ_ACCESS })
public Response getOxAuthJsonSettings() {
try {
log(logger, "Processing oxauth json settings retrieval request");
this.oxAuthDynamicConfigJson = jsonConfigurationService.getOxAuthDynamicConfigJson();
OxAuthJsonConfiguration configuration = new ObjectMapper().readValue(this.oxAuthDynamicConfigJson, OxAuthJsonConfiguration.class);
return Response.ok(configuration).build();
} catch (Exception e) {
log(logger, e);
return Response.status(Response.Status.INTERNAL_SERVER_ERROR).build();
}
}
Aggregations