Overview
CAS takes advantages of Swagger to produce API documentation automatically. The generated documentation supports all CAS endpoints and REST APIs provided they are made available to the runtime application context and are present in the overlay.
Support is enabled by including the following dependency in the overlay:
1
2
3
4
5
<dependency>
<groupId>org.apereo.cas</groupId>
<artifactId>cas-server-support-swagger</artifactId>
<version>${cas.version}</version>
</dependency>
1
implementation "org.apereo.cas:cas-server-support-swagger:${project.'cas.version'}"
1
2
3
4
5
6
7
8
9
dependencyManagement {
imports {
mavenBom "org.apereo.cas:cas-server-support-bom:${project.'cas.version'}"
}
}
dependencies {
implementation "org.apereo.cas:cas-server-support-swagger"
}
1
2
3
4
5
6
7
8
9
10
dependencies {
/*
The following platform references should be included automatically and are listed here for reference only.
implementation enforcedPlatform("org.apereo.cas:cas-server-support-bom:${project.'cas.version'}")
implementation platform(org.springframework.boot.gradle.plugin.SpringBootPlugin.BOM_COORDINATES)
*/
implementation "org.apereo.cas:cas-server-support-swagger"
}
The following settings and properties are available from the CAS configuration catalog:
springdoc.api-docs.enabled=true
Whether to generate and serve an OpenAPI document.
|
springdoc.api-docs.groups.enabled=false
The Enabled.
|
springdoc.api-docs.path=
Path to the generated OpenAPI documentation. For a yaml file, append ".yaml" to the path.
|
springdoc.api-docs.resolve-schema-properties=false
The Resolve schema properties.
|
springdoc.api-docs.version=
The OpenAPI version.
|
springdoc.auto-tag-classes=true
The Auto tag classes.
|
springdoc.cache.disabled=false
The Disabled.
|
springdoc.consumes-to-match=
The Consumes to match.
|
springdoc.default-consumes-media-type=
The Default consumes media type.
|
springdoc.default-flat-param-object=false
The param default flatten
|
springdoc.default-produces-media-type=
The Default produces media type.
|
springdoc.default-support-form-data=true
convert query param to form data when consumes is multipart/form-data
|
springdoc.disable-i18n=false
|
springdoc.group-configs=
|
springdoc.headers-to-match=
The Headers to match.
|
springdoc.model-and-view-allowed=false
The Model and view allowed.
|
springdoc.model-converters.deprecating-converter.enabled=false
The Enabled.
|
springdoc.model-converters.pageable-converter.enabled=false
The Enabled.
|
springdoc.model-converters.polymorphic-converter.enabled=false
The Enabled.
|
springdoc.override-with-generic-response=
The Override with generic response.
|
springdoc.packages-to-exclude=
The Packages to exclude.
|
springdoc.packages-to-scan=
The Packages to scan.
|
springdoc.paths-to-exclude=
The Paths to exclude.
|
springdoc.paths-to-match=
The Paths to match.
|
springdoc.pre-loading-enabled=false
Allow for pre-loading OpenAPI
|
springdoc.produces-to-match=
The Produces to match.
|
springdoc.remove-broken-reference-definitions=true
The Remove broken reference definitions.
|
springdoc.show-actuator=false
|
springdoc.show-login-endpoint=false
The Show login endpoint.
|
springdoc.show-spring-cloud-functions=false
The Show spring cloud functions.
|
springdoc.sort-converter.enabled=false
The Enabled.
|
springdoc.swagger-ui.config-url=
URL to fetch external configuration document from.
|
springdoc.swagger-ui.csrf.cookie-name=
The Cookie name.
|
springdoc.swagger-ui.csrf.enabled=false
|
springdoc.swagger-ui.csrf.header-name=
The Header name.
|
springdoc.swagger-ui.csrf.local-storage-key=
The Local storage key.
|
springdoc.swagger-ui.csrf.session-storage-key=
The Session storage key.
|
springdoc.swagger-ui.csrf.use-local-storage=false
Use Local storage.
|
springdoc.swagger-ui.csrf.use-session-storage=false
Use Session storage.
|
springdoc.swagger-ui.deep-linking=
Enables or disables deep linking for tags and operations. @see deep-linking.md
|
springdoc.swagger-ui.default-model-expand-depth=
The default expansion depth for the model on the model-example section.
|
springdoc.swagger-ui.default-model-rendering=
Controls how the model is shown when the API is first rendered.
|
springdoc.swagger-ui.default-models-expand-depth=
The default expansion depth for models (set to -1 completely hide the models).
|
springdoc.swagger-ui.disable-swagger-default-url=false
The Disable swagger default url.
|
springdoc.swagger-ui.display-operation-id=
Controls the display of operationId in operations list.
|
springdoc.swagger-ui.display-request-duration=
Controls the display of the request duration (in milliseconds) for Try-It-Out requests.
|
springdoc.swagger-ui.doc-expansion=
Controls the default expansion setting for the operations and tags.
|
springdoc.swagger-ui.enabled=true
Whether to generate and serve an OpenAPI document.
|
springdoc.swagger-ui.filter=
If set, enables filtering. The top bar will show an edit box that could be used to filter the tagged operations that are shown.
|
springdoc.swagger-ui.groups-order=
|
springdoc.swagger-ui.layout=
The name of a component available via the plugin system to use as the top-level layout for Swagger UI.
|
springdoc.swagger-ui.max-displayed-tags=
If set, limits the number of tagged operations displayed to at most this many.
|
springdoc.swagger-ui.oauth.additional-query-string-params=
The Additional query string params.
|
springdoc.swagger-ui.oauth.app-name=
|
springdoc.swagger-ui.oauth.client-id=
|
springdoc.swagger-ui.oauth.client-secret=
|
springdoc.swagger-ui.oauth.config-parameters=
|
springdoc.swagger-ui.oauth.realm=
|