From cf37904083059e245f0f17d1e787f1929b032ce6 Mon Sep 17 00:00:00 2001 From: ramvignesh-b Date: Tue, 12 May 2026 04:57:19 +0530 Subject: [PATCH] feat: version API and auth endpoints under /v1 prefix and update documentation labels --- src/index.ts | 10 +++++----- src/routes/dashboard.tsx | 9 ++++++--- src/views/dashboard.js | 12 ++++++------ 3 files changed, 17 insertions(+), 14 deletions(-) diff --git a/src/index.ts b/src/index.ts index c2454de..4d88a1c 100644 --- a/src/index.ts +++ b/src/index.ts @@ -17,8 +17,8 @@ app.doc("/doc", { openapi: "3.0.0", info: { version: "1.0.0", - title: "toknd — Auth Broker API", - description: "Centralized token management and OAuth2 broker service.", + title: "toknd — Auth Broker API v1", + description: "Centralized token management and OAuth2 broker service (v1).", }, tags: [ { name: "Tokens", description: "Standard API for retrieving and refreshing provider tokens." }, @@ -52,9 +52,9 @@ app.use("*", prettyJSON()); app.get("/", (c) => c.redirect("/app")); app.get("/app/dashboard.js", serveStatic({ path: "./src/views/dashboard.js" })); -app.route("/auth", authRoutes); -app.route("/api/config", configRoutes); -app.route("/api", apiRoutes); +app.route("/v1/auth", authRoutes); +app.route("/api/v1/config", configRoutes); +app.route("/api/v1", apiRoutes); app.route("/app", dashboardRoutes); app.notFound((c) => { diff --git a/src/routes/dashboard.tsx b/src/routes/dashboard.tsx index 8b2ce4f..0976c95 100644 --- a/src/routes/dashboard.tsx +++ b/src/routes/dashboard.tsx @@ -66,10 +66,13 @@ export const Dashboard = (props: { isUnlocked: boolean }) => ( - API Reference + + API Reference v1.0.0 + @@ -439,7 +442,7 @@ export const Dashboard = (props: { isUnlocked: boolean }) => (