This commit is contained in:
Gowtham M 2025-10-25 15:49:40 +05:30
parent b0c7e1c8d3
commit d7750aa068

View File

@ -6,6 +6,7 @@ const swaggerUi = require("swagger-ui-express");
const swaggerJsdoc = require("swagger-jsdoc");
const routes = require("./app/routes/routes");
const db = require("./app/models");
const path = require("path");
require("dotenv").config();
const app = express();
@ -48,6 +49,9 @@ app.use("/api-docs", swaggerUi.serve, swaggerUi.setup(swaggerDocs));
// Routes
app.use("/api", routes);
apis: [path.join(__dirname, "app/routes/*.js")],
app.get("/api/test", (req, res) => {
res.json({ status: "success", message: "Test API working fine 🚀" });
});