Boost Azure Demo

This commit is contained in:
MangoPig
2026-05-25 17:05:06 +01:00
parent 675285e99d
commit 4f79137d89
230 changed files with 43275 additions and 2644 deletions

View File

@@ -0,0 +1,24 @@
// Path: Backend/internal/router/router.go
package router
import (
"boostai-backend/internal/config"
"boostai-backend/internal/database"
"github.com/gofiber/fiber/v2"
)
func Setup(app *fiber.App, cfg *config.Config, db *database.DB) {
authMiddleware := buildAuthMiddleware(cfg)
registerWebRoutes(app, cfg, db, authMiddleware)
registerAPIRoutes(app, cfg, db, authMiddleware)
app.Use(func(c *fiber.Ctx) error {
return c.Status(fiber.StatusNotFound).JSON(fiber.Map{
"error": "not_found",
"message": "The requested endpoint does not exist",
})
})
}