Class AuthConfigResource


  • @Path("/jans-auth-server/config")
    @Produces("application/json")
    @Consumes("application/json")
    public class AuthConfigResource
    extends ConfigBaseResource
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      jakarta.ws.rs.core.Response getAppConfiguration()
      Retrieves the current Jans authorization server configuration.
      jakarta.ws.rs.core.Response getFeatureFlagType()
      List available feature flag types configured for the Jans authorization server.
      jakarta.ws.rs.core.Response getPersistenceDetails()
      Retrieve the configured persistence settings for the Jans authorization server.
      jakarta.ws.rs.core.Response patchAppConfigurationProperty​(@NotNull String jsonPatchString)
      Applies a JSON Patch to the stored AppConfiguration, persists the change, and returns the updated configuration.
      • Methods inherited from class io.jans.configapi.core.rest.BaseResource

        checkNotEmpty, checkNotEmpty, checkNotNull, checkNotNull, checkNotNull, checkResourceNotNull, createSearchRequest, findRootError, getBadRequestException, getBadRequestException, getBadRequestException, getHttpHeaders, getHttpRequest, getInternalServerException, getInternalServerException, getMissingAttributeError, getNotAcceptableException, getNotFoundError, getNotFoundError, getUriInfo, throwBadRequestException, throwBadRequestException, throwBadRequestException, throwInternalServerException, throwInternalServerException, throwInternalServerException, throwInternalServerException, throwMissingAttributeError, throwNotFoundException, throwNotFoundException
    • Constructor Detail

      • AuthConfigResource

        public AuthConfigResource()
    • Method Detail

      • getAppConfiguration

        @GET
        public jakarta.ws.rs.core.Response getAppConfiguration()
        Retrieves the current Jans authorization server configuration.
        Returns:
        the current AppConfiguration representing the server's configuration
      • patchAppConfigurationProperty

        @PATCH
        @Consumes("application/json-patch+json")
        public jakarta.ws.rs.core.Response patchAppConfigurationProperty​(@NotNull
                                                                         @NotNull String jsonPatchString)
                                                                  throws com.github.fge.jsonpatch.JsonPatchException,
                                                                         IOException
        Applies a JSON Patch to the stored AppConfiguration, persists the change, and returns the updated configuration. The provided JSON Patch string is applied to the current configuration; if the patch touches the "agamaConfiguration" field, that sub-configuration is validated before persisting. The persisted and reloaded AppConfiguration is returned.
        Parameters:
        jsonPatchString - JSON Patch document as a string describing the partial updates
        Returns:
        the updated AppConfiguration after applying the patch and persisting the change
        Throws:
        com.github.fge.jsonpatch.JsonPatchException - if the JSON Patch cannot be applied to the current configuration
        IOException - if an I/O error occurs while processing the patch or configuration
      • getPersistenceDetails

        @GET
        @Path("/persistence")
        public jakarta.ws.rs.core.Response getPersistenceDetails()
        Retrieve the configured persistence settings for the Jans authorization server.
        Returns:
        the PersistenceConfiguration describing the server's configured persistence
      • getFeatureFlagType

        @GET
        @Path("/feature-flags")
        public jakarta.ws.rs.core.Response getFeatureFlagType()
        List available feature flag types configured for the Jans authorization server. The returned set excludes FeatureFlagType.UNKNOWN.
        Returns:
        an EnumSet of available FeatureFlagType values; excludes FeatureFlagType.UNKNOWN.