log-manager/routers/router/router.go

22 lines
387 B
Go

package router
import (
"jannex/log-manager/routers/router/api/v1/log"
"github.com/gofiber/fiber/v2"
)
func SetupRoutes(app *fiber.App) {
v1 := app.Group("/v1")
l := v1.Group("/log")
l.Post("/", log.AddLog)
l.Get("/types", log.GetAvailableLogTypes)
l.Get("/sse/:logType/:date", log.SSE)
ls := v1.Group("/logs")
ls.Get("/:type", log.GetLog)
app.Static("/", "./public/")
}