Some kind of starting point

This commit is contained in:
2020-12-29 13:46:58 +01:00
commit 1811f200c0
14 changed files with 398 additions and 0 deletions

17
src/handlers/get.go Normal file
View File

@@ -0,0 +1,17 @@
package handlers
import (
"github.com/gofiber/fiber/v2"
log "github.com/sirupsen/logrus"
)
// Hello handler
func Hello(c *fiber.Ctx) error {
return c.SendString("Hello, World!")
}
// UserGet handler
func UserGet(c *fiber.Ctx) error {
log.WithFields(log.Fields{"userID": c.Params("userID")}).Debug("GETing user")
return c.SendString("USER ffs")
}