Mensa-API/server/server.go
2024-09-15 18:57:03 +02:00

17 lines
261 B
Go

package server
import (
"github.com/gin-gonic/gin"
)
func Run() {
r := gin.Default()
r.GET("/ping", func(c *gin.Context) {
c.JSON(200, gin.H{
"message": "pong",
})
})
r.GET("/state/:state", state)
r.Run() // listen and serve on
}