refactor: restructure server routing and add documentation routes

This commit is contained in:
Andrew Phillips
2025-08-12 15:01:38 -03:00
committed by Andrew Phillips (aider)
parent 4c82c55f58
commit 6869b08a77
2 changed files with 8 additions and 1 deletions

View File

@@ -81,3 +81,10 @@ pub async fn handle_swagger_ui() -> Html<&'static str> {
Html(html)
}
pub fn add_routes(router: Router<AppState>) -> Router<AppState> {
router
// Documentation endpoints
.route("/openapi.json", get(docs::handle_openapi))
.route("/swagger/", get(docs::handle_swagger_ui))
}