Files
old-backend/routes/protected_routes.go

24 lines
387 B
Go
Raw Normal View History

/**
* Created by VoidArtanis on 10/22/2017
*/
package routes
import (
2023-09-11 08:08:24 +02:00
"gitlab.com/pactual1/backend/middlewares"
2023-09-11 08:08:24 +02:00
2023-09-11 08:08:24 +02:00
"gitlab.com/pactual1/backend/controllers"
2023-09-11 08:08:24 +02:00
"github.com/gin-gonic/gin"
)
2023-09-18 12:27:40 +02:00
func RegisterProtectedRoutes(r *gin.Engine) {
authGroup := r.Group("/auth")
authGroup.Use(middlewares.AuthHandler("admin"))
{
2023-09-21 11:59:08 +02:00
authGroup.GET("/getmessage", controllers.GetSecretText)
}
}