feat: refac and add key deletion route

This commit is contained in:
2026-04-29 14:46:24 +02:00
parent 8f6b1efea0
commit 6669fda371
11 changed files with 177 additions and 84 deletions
+21
View File
@@ -0,0 +1,21 @@
package routes
import (
"log/slog"
"orbits-server/internal/server/api/assets"
"orbits-server/internal/server/bootstrap"
"github.com/gin-gonic/gin"
)
func RegisterApiRoutes(api *gin.RouterGroup, env bootstrap.Environment) {
api.GET("/version", func(c *gin.Context) {
slog.Debug("received request for the version endpoint")
assets.BasicResponse(c, env.Version)
})
api.GET("/codename", func(c *gin.Context) {
slog.Debug("received request for the codename endpoint")
assets.BasicResponse(c, env.Codename)
})
}