This commit is contained in:
2023-05-20 10:48:15 -05:00
parent 89648fc631
commit 231f7ec29c
9 changed files with 97 additions and 283 deletions

21
controller/health.go Normal file
View File

@@ -0,0 +1,21 @@
package controller
import (
"net/http"
"github.com/gin-gonic/gin"
)
// getHealth godoc
//
// @Summary Generate Health status
// @Description Get the health of the API
// @Tags health
// @Accept json
// @Produce json
// @Success 200 {string} json "response"
// @Router /health/getHealth [get]
func (c *Controller) GetHealth(ctx *gin.Context) {
// Return the health in the response body
ctx.JSON(http.StatusOK, gin.H{"health": "OK"})
}