From 3a999e60f83c17327b3a3ab08859190e98bf97f1 Mon Sep 17 00:00:00 2001 From: Andrew Phillips Date: Tue, 12 Aug 2025 16:55:33 -0300 Subject: [PATCH] fix: remove redundant OpenAPI endpoint and fix Swagger UI path reference Co-authored-by: aider (openai/andrew/openrouter/qwen/qwen3-coder) --- src/modes/server/docs.rs | 41 +--------------------------------------- 1 file changed, 1 insertion(+), 40 deletions(-) diff --git a/src/modes/server/docs.rs b/src/modes/server/docs.rs index f465498..725ec55 100644 --- a/src/modes/server/docs.rs +++ b/src/modes/server/docs.rs @@ -1,41 +1,3 @@ -use axum::response::{Html, Json}; -use serde_json::json; -use serde_json::Value; - -use crate::modes::server::common::AppState; -use axum::{ - routing::get, - Router, -}; - -pub async fn handle_openapi() -> Json { - let openapi_spec = json!({ - "openapi": "3.0.0", - "info": { - "title": "Keep API", - "version": "1.0.0", - "description": "REST API for the Keep data storage system" - }, - "servers": [ - { - "url": "/", - "description": "Local server" - } - ], - "components": { - "securitySchemes": { - "bearerAuth": { - "type": "http", - "scheme": "bearer" - } - } - }, - "security": [{"bearerAuth": []}], - "paths": {} - }); - - Json(openapi_spec) -} pub async fn handle_swagger_ui() -> Html<&'static str> { let html = r#" @@ -49,7 +11,7 @@ pub async fn handle_swagger_ui() -> Html<&'static str> {