website/api/routes/index.go
ngn fa2f3acb35
cleanup for the docker setup
Signed-off-by: ngn <ngn@ngn.tf>
2025-01-18 03:31:37 +03:00

15 lines
305 B
Go

package routes
import (
"github.com/gofiber/fiber/v2"
"github.com/ngn13/website/api/config"
)
func GET_Index(c *fiber.Ctx) error {
conf := c.Locals("config").(*config.Type)
app := conf.GetURL("app_url")
// redirect to the API documentation
return c.Redirect(app.JoinPath("/doc/api").String())
}