BE: Integrate Swagger UI for API documentation #631#1607
Open
Rupa-421 wants to merge 4 commits intokafbat:mainfrom
Open
BE: Integrate Swagger UI for API documentation #631#1607Rupa-421 wants to merge 4 commits intokafbat:mainfrom
Rupa-421 wants to merge 4 commits intokafbat:mainfrom
Conversation
There was a problem hiding this comment.
Hi Rupa-421! 👋
Welcome, and thank you for opening your first PR in the repo!
Please wait for triaging by our maintainers.
Please take a look at our contributing guide.
Haarolean
requested changes
Jan 3, 2026
Author
|
I have updated the PR to disable Swagger UI by default. It can now be toggled via the AUTH_OPENAPI_ENABLED environment variable. I also added the documentation for this variable in the README.md |
Haarolean
reviewed
Jan 9, 2026
Member
|
@Rupa-421 have you tried running this with any kind of auth enabled? login_form should work fine, but I fear oauth might be tricky here |
Author
|
@Haarolean ,I have tried with auth enabled for both the login form and also Github Oauth. They are working fine. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


What changes did you make? (Give an overview)
This PR integrates Swagger UI into the application using springdoc-openapi and automates the API contract delivery.
Key changes include:
Version Catalog Migration: Moved springdoc and related dependencies to libs.versions.toml for centralized management.
Build Automation: Created a new Gradle task copyOpenApiSpecForSwagger that automatically pulls the latest OpenAPI YAML from the contract-typespec module and places it in the static web resources.
Security Configuration: Updated the Security Filter Chain to permit access to Swagger UI endpoints (/swagger-ui/, /v3/api-docs/, etc.).
Application Properties: Configured springdoc to point to the local static OpenAPI spec instead of the default generated one to ensure consistency with the TypeSpec definition.
Resource Management: Linked processResources to the spec-copying task to ensure the UI is always up-to-date during development and packaging.
Fixes #631
Is there anything you'd like reviewers to focus on?
How Has This Been Tested? (put an "x" (case-sensitive!) next to an item)
Checklist (put an "x" (case-sensitive!) next to all the items, otherwise the build will fail)
Check out Contributing and Code of Conduct
A picture of a cute animal (not mandatory but encouraged)